@@ -29,11 +29,9 @@ import { replaceExtApiPagePaths } from '../js/extApiPages'
2929import { uniAppCssPlugin , uniAppCssPrePlugin } from '../dom2/css'
3030
3131export function init ( ) {
32- const isDom2Harmony =
33- process . env . UNI_APP_X_DOM2 === 'true' &&
34- process . env . UNI_UTS_PLATFORM === 'app-harmony'
32+ const isDom2 = process . env . UNI_APP_X_DOM2 === 'true'
3533 return [
36- ...( isDom2Harmony ? [ uniAppCssPrePlugin ( ) ] : [ ] ) ,
34+ ...( isDom2 ? [ uniAppCssPrePlugin ( ) ] : [ ] ) ,
3735 ...( isNormalCompileTarget ( )
3836 ? [ uniWorkersPlugin ( ) , uniDecryptUniModulesPlugin ( ) ]
3937 : [ ] ) ,
@@ -60,13 +58,13 @@ export function init() {
6058 ] ) ,
6159 uniUTSUVueJavaScriptPlugin ( ) ,
6260 resolveUTSCompiler ( ) . uts2js ( {
63- dom2 : isDom2Harmony ,
61+ dom2 : isDom2 ,
6462 platform : 'app-harmony' ,
6563 inputDir : process . env . UNI_INPUT_DIR ,
6664 version : process . env . UNI_COMPILER_VERSION ,
6765 cacheRoot : path . resolve ( process . env . UNI_APP_X_CACHE_DIR , '.uts2js/cache' ) ,
6866 sourceMap : enableSourceMap ( ) ,
69- sharedDataLibName : isDom2Harmony ? 'libentry.so' : undefined ,
67+ sharedDataLibName : isDom2 ? 'libentry.so' : undefined ,
7068 modules : {
7169 vueCompilerDom,
7270 uniCliShared,
@@ -78,11 +76,11 @@ export function init() {
7876 } ,
7977 } ,
8078 } ) ,
81- ...( isDom2Harmony ? [ uniSharedDataPlugin ( ) ] : [ ] ) ,
79+ ...( isDom2 ? [ uniSharedDataPlugin ( ) ] : [ ] ) ,
8280 ...( process . env . UNI_COMPILE_EXT_API_TYPE === 'pages'
8381 ? [ replaceExtApiPagePaths ( ) ]
8482 : [ ] ) ,
85- ...( isDom2Harmony ? [ uniAppCssPlugin ( ) ] : [ ] ) ,
83+ ...( isDom2 ? [ uniAppCssPlugin ( ) ] : [ ] ) ,
8684 ...( isNormalCompileTarget ( ) ? [ uniStatsPlugin ( ) ] : [ ] ) ,
8785 ]
8886}
0 commit comments