提交 c057f9e2 编写于 作者: fxy060608's avatar fxy060608

chore: remove app | web

上级 9756ca59
......@@ -28,6 +28,8 @@ const removePlatformStyle = function (style) {
delete style[name]
}
})
delete style.app
delete style.web
}
const getPageComponents = function (inputDir, pagesJson) {
......
......@@ -66,6 +66,11 @@ function parseStyle (style = {}, root = '') {
let platformStyle = {}
Object.keys(style).forEach(name => {
if (name === 'app') {
name = 'app-plus'
} else if (name === 'web') {
name = 'h5'
}
if (PLATFORMS.includes(name)) {
if (name === process.env.UNI_PLATFORM) {
if (name === 'app-plus') {
......@@ -80,6 +85,9 @@ function parseStyle (style = {}, root = '') {
}
})
delete style.app
delete style.web
if (process.env.UNI_PLATFORM === 'app-plus') {
if (root && Array.isArray(platformStyle.subNVues) && platformStyle.subNVues.length) { // 处理分包逻辑
platformStyle.subNVues.forEach(subNVue => {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册