未验证 提交 84b1201e 编写于 作者: B beatles-chameleon 提交者: GitHub

Merge pull request #166 from didi/0.4.x-dev-yyl

0.4.x dev yyl
......@@ -13,8 +13,11 @@ module.exports = function(loaderContext, jsonObject, cmlType, componentDeps) {
componentDeps.push(filePath);
components[key] = refUrl;
} else {
delete components[key];
cmlUtils.log.error(`can't find component:${refUrl} in ${loaderContext.resourcePath}`);
// plugin开头的小程序插件不做处理
if (components[key].indexOf('plugin://') !== 0) {
delete components[key];
cmlUtils.log.error(`can't find component:${refUrl} in ${loaderContext.resourcePath}`);
}
}
})
}
......
<template>
<app></app>
<app router-config="{{routerConfig}}"></app>
</template>
<script>
import routerConfig from '../router.config.json';
class App {
data = {}
data = {
routerConfig
}
created(res) {
}
}
......
<template>
<app></app>
<app router-config="{{routerConfig}}"></app>
</template>
<script>
import routerConfig from '../router.config.json';
class App {
data = {}
data = {
routerConfig
}
created(res) {
}
}
......
......@@ -108,8 +108,10 @@ module.exports = function(source) {
import ${helper.toUpperCase(key)} from "${cmlUtils.handleRelativePath(self.resourcePath, filePath)}"\n`;
} else {
delete coms[key];
cmlUtils.log.error(`can't find component:${coms[key]} in ${self.resourcePath}`);
if (coms[key].indexOf('plugin://') !== 0) {
delete coms[key];
cmlUtils.log.error(`can't find component:${coms[key]} in ${self.resourcePath}`);
}
}
})
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册