diff --git a/build/webpack.config.dev.js b/build/webpack.config.dev.js index ac7fef176..b5d3fbdeb 100644 --- a/build/webpack.config.dev.js +++ b/build/webpack.config.dev.js @@ -14,9 +14,8 @@ const cache = { module.exports = { entry: { - vendor: ['packages'], 'vant-docs': './docs/src/index.js', - 'vant-examples': './docs/src/examples.js' + 'vant-mobile': './docs/src/mobile.js' }, output: { path: path.join(__dirname, '../docs/dist'), @@ -28,7 +27,7 @@ module.exports = { host: '0.0.0.0', historyApiFallback: { rewrites: [ - { from: /^\/zanui\/vant\/examples/, to: '/examples.html' }, + { from: /^\/zanui\/vant\/mobile/, to: '/mobile.html' }, { from: /^\/zanui\/vant/, to: '/index.html' } ] }, @@ -99,9 +98,9 @@ module.exports = { inject: true }), new HtmlWebpackPlugin({ - chunks: ['vendor', 'vant-examples'], + chunks: ['vendor', 'vant-mobile'], template: 'docs/src/index.tpl', - filename: 'examples.html', + filename: 'mobile.html', inject: true }), new webpack.optimize.CommonsChunkPlugin({ diff --git a/docs/src/DocsApp.vue b/docs/src/DocsApp.vue index 9c658666d..f1125b6e2 100644 --- a/docs/src/DocsApp.vue +++ b/docs/src/DocsApp.vue @@ -12,14 +12,14 @@ import docConfig from './doc.config'; export default { data() { return { - simulators: [`/zanui/vant/examples${location.hash}`], + simulators: [`/zanui/vant/mobile${location.hash}`], demoURL: '' }; }, computed: { base() { - return `/${this.$vantLang}/component`; + return `/${this.$vantLang}`; }, config() { diff --git a/docs/src/components/DemoList.vue b/docs/src/components/DemoList.vue index 901593479..346f76ede 100644 --- a/docs/src/components/DemoList.vue +++ b/docs/src/components/DemoList.vue @@ -11,7 +11,7 @@