feat: doc use hash router

This commit is contained in:
pangxie1991 2017-09-30 11:33:33 +08:00
parent 841b50cd95
commit b43b16d04c

View File

@ -24,11 +24,11 @@ export default {
methods: { methods: {
getSimulatorPath() { getSimulatorPath() {
const dir = location.pathname.split('/').pop(); const dir = location.hash.split('/').pop();
if (dir === 'quickstart' || dir === 'changelog') { if (dir === 'quickstart' || dir === 'changelog') {
return '/zanui/vue/examples'; return '/zanui/vue/examples';
} else { } else {
return `/zanui/vue/examples/component/${dir}`; return `/zanui/vue/examples#/component/${dir}`;
} }
} }
} }