@tarojs/plugin-platform-h5 4.0.1-alpha.0 → 4.0.1
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/LICENSE +8 -8
- package/build/utils/ast.ts +2 -12
- package/dist/dist/definition.json.d.ts +3684 -0
- package/dist/dist/definition.json.js +4 -0
- package/dist/dist/definition.json.js.map +1 -0
- package/dist/index.d.ts +23 -5
- package/dist/index.js +420 -143
- package/dist/index.js.map +1 -1
- package/dist/runtime/apis/index.d.ts +5 -5
- package/dist/runtime/apis/index.js +1 -1
- package/dist/runtime/apis/taro.d.ts +1 -1
- package/dist/runtime/components/index.d.ts +0 -1
- package/dist/runtime/index.d.ts +1 -1
- package/package.json +25 -16
- package/dist/program.d.ts +0 -25
- package/dist/utils.d.ts +0 -1
package/LICENSE
CHANGED
|
@@ -154,8 +154,15 @@ See `/LICENSE` for details of the license.
|
|
|
154
154
|
|
|
155
155
|
==================
|
|
156
156
|
|
|
157
|
+
MIT (stencil-vue2-output-target):
|
|
158
|
+
The following files embed [stencil-vue2-output-target](https://github.com/diondree/stencil-vue2-output-target) MIT:
|
|
159
|
+
`/packages/taro-components-library-vue2/src/vue-component-lib/utils.ts`
|
|
160
|
+
See `/LICENSE` for details of the license.
|
|
161
|
+
|
|
162
|
+
==================
|
|
163
|
+
|
|
157
164
|
MIT (weui):
|
|
158
|
-
The following files embed [
|
|
165
|
+
The following files embed [stencil-vue2-output-target](https://github.com/Tencent/weui) MIT:
|
|
159
166
|
`/packages/taro-components/src/components/*.scss`
|
|
160
167
|
See `/LICENSE.txt` for details of the license.
|
|
161
168
|
|
|
@@ -165,10 +172,3 @@ Apache-2.0 (intersection-observer):
|
|
|
165
172
|
The following files embed [intersection-observer](https://github.com/GoogleChromeLabs/intersection-observer) Apache-2.0:
|
|
166
173
|
`/packages/taro-api/src/polyfill/intersection-observer.ts`
|
|
167
174
|
See `/LICENSE.txt` for details of the license.
|
|
168
|
-
|
|
169
|
-
==================
|
|
170
|
-
|
|
171
|
-
MIT (babel-plugin-jsx-dom-expressions):
|
|
172
|
-
The following files embed [babel-plugin-jsx-dom-expressions](https://github.com/ryansolid/dom-expressions/blob/main/packages/babel-plugin-jsx-dom-expressions) MIT:
|
|
173
|
-
`/packages/babel-plugin-transform-solid-jsx/src/*`
|
|
174
|
-
See `/LICENSE` for details of the license.
|
package/build/utils/ast.ts
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import path from '
|
|
2
|
-
|
|
1
|
+
import path from 'path'
|
|
3
2
|
import ts from 'typescript'
|
|
4
3
|
|
|
5
4
|
export interface DocEntry {
|
|
@@ -18,15 +17,6 @@ export interface DocEntry {
|
|
|
18
17
|
symbol?: DocEntry
|
|
19
18
|
}
|
|
20
19
|
|
|
21
|
-
export function pathsAreEqual (path1: string, path2: string) {
|
|
22
|
-
path1 = path.resolve(path1)
|
|
23
|
-
path2 = path.resolve(path2)
|
|
24
|
-
if (process.platform === 'win32') {
|
|
25
|
-
return path1.toLowerCase() === path2.toLowerCase()
|
|
26
|
-
}
|
|
27
|
-
return path1 === path2
|
|
28
|
-
}
|
|
29
|
-
|
|
30
20
|
export function generateDocumentation (
|
|
31
21
|
filepaths: string[],
|
|
32
22
|
options: ts.CompilerOptions,
|
|
@@ -41,7 +31,7 @@ export function generateDocumentation (
|
|
|
41
31
|
|
|
42
32
|
for (const sourceFile of program.getSourceFiles()) {
|
|
43
33
|
if (param.withDeclaration !== false || !sourceFile.isDeclarationFile) {
|
|
44
|
-
//
|
|
34
|
+
// 规范化路径,修复window环境无法生成definition.json文件
|
|
45
35
|
const normalSrcFile = path.normalize(sourceFile.fileName)
|
|
46
36
|
if ((param.mapAll === true && filepaths.includes(normalSrcFile)) || normalSrcFile === path.normalize(filepaths[0])) {
|
|
47
37
|
ts.forEachChild(sourceFile, (n) => visitAST(n, output))
|