@tarojs/taro 4.0.0-canary.6 → 4.0.0-canary.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tarojs/taro",
3
- "version": "4.0.0-canary.6",
3
+ "version": "4.0.0-canary.8",
4
4
  "description": "Taro framework",
5
5
  "homepage": "https://github.com/nervjs/taro/tree/master/packages/taro#readme",
6
6
  "main": "index.js",
@@ -21,12 +21,12 @@
21
21
  "author": "O2Team",
22
22
  "license": "MIT",
23
23
  "dependencies": {
24
- "@tarojs/api": "4.0.0-canary.6",
25
- "@tarojs/runtime": "4.0.0-canary.6"
24
+ "@tarojs/api": "4.0.0-canary.8",
25
+ "@tarojs/runtime": "4.0.0-canary.8"
26
26
  },
27
27
  "devDependencies": {
28
- "@tarojs/helper": "4.0.0-canary.6",
29
- "@tarojs/shared": "4.0.0-canary.6"
28
+ "@tarojs/helper": "4.0.0-canary.8",
29
+ "@tarojs/shared": "4.0.0-canary.8"
30
30
  },
31
31
  "peerDependenciesMeta": {
32
32
  "@types/react": {
@@ -38,13 +38,15 @@ declare module '../index' {
38
38
  /** @ignore */
39
39
  interface TARO_ENV_TYPE {
40
40
  [TaroGeneral.ENV_TYPE.WEAPP]: TaroGeneral.ENV_TYPE.WEAPP
41
- [TaroGeneral.ENV_TYPE.WEB]: TaroGeneral.ENV_TYPE.WEB
42
- [TaroGeneral.ENV_TYPE.RN]: TaroGeneral.ENV_TYPE.RN
43
41
  [TaroGeneral.ENV_TYPE.SWAN]: TaroGeneral.ENV_TYPE.SWAN
44
42
  [TaroGeneral.ENV_TYPE.ALIPAY]: TaroGeneral.ENV_TYPE.ALIPAY
45
43
  [TaroGeneral.ENV_TYPE.TT]: TaroGeneral.ENV_TYPE.TT
46
44
  [TaroGeneral.ENV_TYPE.QQ]: TaroGeneral.ENV_TYPE.QQ
47
45
  [TaroGeneral.ENV_TYPE.JD]: TaroGeneral.ENV_TYPE.JD
46
+ [TaroGeneral.ENV_TYPE.WEB]: TaroGeneral.ENV_TYPE.WEB
47
+ [TaroGeneral.ENV_TYPE.RN]: TaroGeneral.ENV_TYPE.RN
48
+ [TaroGeneral.ENV_TYPE.HARMONY]: TaroGeneral.ENV_TYPE.HARMONY
49
+ [TaroGeneral.ENV_TYPE.QUICKAPP]: TaroGeneral.ENV_TYPE.QUICKAPP
48
50
  }
49
51
 
50
52
  namespace interceptorify {
@@ -119,7 +119,7 @@ export interface IMiniAppConfig<T extends CompilerTypes = CompilerWebpackTypes>
119
119
  /** 体验式功能 */
120
120
  experimental?: {
121
121
  /** 是否开启编译模式 */
122
- compileMode?: boolean
122
+ compileMode?: boolean | string
123
123
  }
124
124
  }
125
125
 
@@ -51,6 +51,7 @@ export interface ViteHarmonyBuildConfig extends CommonBuildConfig, IHarmonyConfi
51
51
  fileType: IFileType
52
52
  useETS?: boolean
53
53
  useJSON5?: boolean
54
+ blended?: boolean
54
55
  runtimePath?: string | string[]
55
56
  taroComponentsPath: string
56
57
  }
@@ -110,8 +111,10 @@ export interface ViteCompilerContext<T> {
110
111
  getPages: () => VitePageMeta[]
111
112
  isApp: (id: string) => boolean
112
113
  isPage: (id: string) => boolean
114
+ isComponent: (id: string) => boolean
113
115
  isNativePageORComponent: (templatePath: string) => boolean
114
116
  getPageById: (id: string) => VitePageMeta| undefined
117
+ getComponentById: (id: string) => VitePageMeta| undefined
115
118
  getConfigFilePath: (filePath: string) => string
116
119
  getTargetFilePath: (filePath: string, targetExtName: string) => string
117
120
  }
@@ -126,11 +129,14 @@ export interface ViteH5CompilerContext extends ViteCompilerContext<ViteH5BuildCo
126
129
  }
127
130
 
128
131
  export interface ViteHarmonyCompilerContext extends ViteCompilerContext<ViteHarmonyBuildConfig> {
132
+ nativeExt: string[]
129
133
  fileType: ViteFileType
130
134
  commonChunks: string[]
135
+ nativeComponents : Map<string, ViteNativeCompMeta>
131
136
  getCommonChunks: () => string[]
132
137
  modifyHarmonyConfig: (config: Partial<AppConfig>) => void
133
138
  modifyHostPackageDep: (outDir: string, deps?: Record<string, string>, devDeps?: Record<string, string>) => void
139
+ collectNativeComponents: (meta: ViteAppMeta | VitePageMeta | ViteNativeCompMeta) => void
134
140
  getScriptPath: (filePath: string) => string
135
141
  getStylePath: (filePath: string) => string
136
142
  getConfigPath: (filePath: string) => string