fix(vant-markdown-loader): 组件名转驼峰时需要是大驼峰

This commit is contained in:
HaoChuan9421 2021-03-16 21:38:10 +08:00 committed by neverland
parent 5112e4cf65
commit fe9a8657f3

View File

@ -8,7 +8,7 @@ const extractDemo = require('./extract-demo');
const sideEffectTags = require('./side-effect-tags'); const sideEffectTags = require('./side-effect-tags');
function camelize(str) { function camelize(str) {
return str.replace(/-(\w)/g, (_, c) => (c ? c.toUpperCase() : '')); return `-${str}`.replace(/-(\w)/g, (_, c) => (c ? c.toUpperCase() : ''));
} }
const sharedVueOptions = `mounted() { const sharedVueOptions = `mounted() {