From 3e6f83089f645a5e99877484ab10a3cbc08c95eb Mon Sep 17 00:00:00 2001 From: Xyz Date: Tue, 7 Dec 2021 02:18:48 +0800 Subject: [PATCH 1/9] =?UTF-8?q?docs=EF=BC=9Amodify=20the=20script=20to=20s?= =?UTF-8?q?tart=20example=20project=20(#1775)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CONTRIBUTING.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index da690b033..51c73aa4f 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -42,7 +42,7 @@ $ yarn watch ```bash $ cd path/to/remax/packages/remax $ yarn link -$ cd path/to/remax/packages/@remax/cli +$ cd path/to/remax/packages/remax-cli $ yarn link $ git clone git@github.com:remaxjs/examples.git remax-examples $ cd remax-examples/ali # 找一个你要调试的例子 From 0e0a6b503a7db785c65e37c06e1a909b339b68ed Mon Sep 17 00:00:00 2001 From: SuperLuckyBo <45282970+1198994985@users.noreply.github.com> Date: Tue, 7 Dec 2021 22:41:47 +0800 Subject: [PATCH 2/9] perf: optimize update performance (#1777) Co-authored-by: fengbo --- packages/remax-runtime/src/VNode.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/packages/remax-runtime/src/VNode.ts b/packages/remax-runtime/src/VNode.ts index 24d0c4624..efedf4363 100644 --- a/packages/remax-runtime/src/VNode.ts +++ b/packages/remax-runtime/src/VNode.ts @@ -181,13 +181,15 @@ export default class VNode { return; } + const parentPath = this.parent!.path; + for (let i = 0; i < payload.length; i = i + 2) { const [propName, propValue] = toRawProps(payload[i], payload[i + 1], this.type); - let path = [...this.parent!.path, 'nodes', this.id.toString(), 'props']; + let path = [...parentPath, 'nodes', this.id.toString(), 'props']; if (RuntimeOptions.get('platform') === 'ali') { - path = [...this.parent!.path, `children[${this.index}].props`]; + path = [...parentPath, `children[${this.index}].props`]; } this.container.requestUpdate({ From 8b1f245dfb7e0a45384d6fe4a0055e2fb5955abd Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 7 Dec 2021 22:42:03 +0800 Subject: [PATCH 3/9] build(deps-dev): bump memfs from 3.2.0 to 3.4.0 (#1772) Bumps [memfs](https://github.com/streamich/memfs) from 3.2.0 to 3.4.0. - [Release notes](https://github.com/streamich/memfs/releases) - [Changelog](https://github.com/streamich/memfs/blob/master/CHANGELOG.md) - [Commits](https://github.com/streamich/memfs/compare/v3.2.0...v3.4.0) --- updated-dependencies: - dependency-name: memfs dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- yarn.lock | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/yarn.lock b/yarn.lock index 80396db06..052c18439 100644 --- a/yarn.lock +++ b/yarn.lock @@ -10057,10 +10057,10 @@ fs-mkdirp-stream@^1.0.0: graceful-fs "^4.1.11" through2 "^2.0.3" -fs-monkey@1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/fs-monkey/-/fs-monkey-1.0.1.tgz#4a82f36944365e619f4454d9fff106553067b781" - integrity sha512-fcSa+wyTqZa46iWweI7/ZiUfegOZl0SG8+dltIwFXo7+zYU9J9kpS3NB6pZcSlJdhvIwp81Adx2XhZorncxiaA== +fs-monkey@1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/fs-monkey/-/fs-monkey-1.0.3.tgz#ae3ac92d53bb328efe0e9a1d9541f6ad8d48e2d3" + integrity sha512-cybjIfiiE+pTWicSCLFHSrXZ6EilF30oh91FDP9S2B051prEa7QWfrVTQm10/dDpswBDXZugPa1Ogu8Yh+HV0Q== fs-readdir-recursive@^1.1.0: version "1.1.0" @@ -13719,11 +13719,11 @@ mem@^5.0.0: p-is-promise "^2.1.0" memfs@^3.1.2: - version "3.2.0" - resolved "https://registry.yarnpkg.com/memfs/-/memfs-3.2.0.tgz#f9438e622b5acd1daa8a4ae160c496fdd1325b26" - integrity sha512-f/xxz2TpdKv6uDn6GtHee8ivFyxwxmPuXatBb1FBwxYNuVpbM3k/Y1Z+vC0mH/dIXXrukYfe3qe5J32Dfjg93A== + version "3.4.0" + resolved "https://registry.yarnpkg.com/memfs/-/memfs-3.4.0.tgz#8bc12062b973be6b295d4340595736a656f0a257" + integrity sha512-o/RfP0J1d03YwsAxyHxAYs2kyJp55AFkMazlFAZFR2I2IXkxiUTXRabJ6RmNNCQ83LAD2jy52Khj0m3OffpNdA== dependencies: - fs-monkey "1.0.1" + fs-monkey "1.0.3" memoize-one@^5.1.1: version "5.2.1" From b42bb257881af49000a917effbc968988cc89ca7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 14 Dec 2021 01:51:54 +0800 Subject: [PATCH 4/9] build(deps): bump @babel/preset-typescript from 7.14.5 to 7.16.0 (#1785) Bumps [@babel/preset-typescript](https://github.com/babel/babel/tree/HEAD/packages/babel-preset-typescript) from 7.14.5 to 7.16.0. - [Release notes](https://github.com/babel/babel/releases) - [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md) - [Commits](https://github.com/babel/babel/commits/v7.16.0/packages/babel-preset-typescript) --- updated-dependencies: - dependency-name: "@babel/preset-typescript" dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- yarn.lock | 176 ++++++++++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 152 insertions(+), 24 deletions(-) diff --git a/yarn.lock b/yarn.lock index 052c18439..20556b5f4 100644 --- a/yarn.lock +++ b/yarn.lock @@ -9,6 +9,13 @@ dependencies: "@babel/highlight" "^7.14.5" +"@babel/code-frame@^7.16.0": + version "7.16.0" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.16.0.tgz#0dfc80309beec8411e65e706461c408b0bb9b431" + integrity sha512-IF4EOMEV+bfYwOmNxGzSnjR2EmQod7f1UXOpZM3l4i4o4QNwzjtJAu/HxdjHq0aYBvdqMuQEY1eg0nqW9ZPORA== + dependencies: + "@babel/highlight" "^7.16.0" + "@babel/compat-data@^7.12.1", "@babel/compat-data@^7.12.7", "@babel/compat-data@^7.13.15", "@babel/compat-data@^7.14.0": version "7.14.0" resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.14.0.tgz#a901128bce2ad02565df95e6ecbf195cf9465919" @@ -102,6 +109,15 @@ jsesc "^2.5.1" source-map "^0.5.0" +"@babel/generator@^7.16.0": + version "7.16.0" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.16.0.tgz#d40f3d1d5075e62d3500bccb67f3daa8a95265b2" + integrity sha512-RR8hUCfRQn9j9RPKEVXo9LiwoxLPYn6hNZlvUOR8tSnaxlD0p0+la00ZP9/SnRt6HchKr+X0fO2r8vrETiJGew== + dependencies: + "@babel/types" "^7.16.0" + jsesc "^2.5.1" + source-map "^0.5.0" + "@babel/helper-annotate-as-pure@^7.10.4": version "7.10.4" resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.10.4.tgz#5bf0d495a3f757ac3bda48b5bf3b3ba309c72ba3" @@ -116,6 +132,13 @@ dependencies: "@babel/types" "^7.14.5" +"@babel/helper-annotate-as-pure@^7.16.0": + version "7.16.0" + resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.16.0.tgz#9a1f0ebcda53d9a2d00108c4ceace6a5d5f1f08d" + integrity sha512-ItmYF9vR4zA8cByDocY05o0LGUkp1zhbTQOH1NFyl5xXEqlTJQCEJjieriw+aFpxo16swMxUnUiKS7a/r4vtHg== + dependencies: + "@babel/types" "^7.16.0" + "@babel/helper-builder-binary-assignment-operator-visitor@^7.10.4": version "7.10.4" resolved "https://registry.yarnpkg.com/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.10.4.tgz#bb0b75f31bf98cbf9ff143c1ae578b87274ae1a3" @@ -192,17 +215,17 @@ "@babel/helper-replace-supers" "^7.14.5" "@babel/helper-split-export-declaration" "^7.14.5" -"@babel/helper-create-class-features-plugin@^7.14.6": - version "7.14.6" - resolved "https://registry.yarnpkg.com/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.14.6.tgz#f114469b6c06f8b5c59c6c4e74621f5085362542" - integrity sha512-Z6gsfGofTxH/+LQXqYEK45kxmcensbzmk/oi8DmaQytlQCgqNZt9XQF8iqlI/SeXWVjaMNxvYvzaYw+kh42mDg== +"@babel/helper-create-class-features-plugin@^7.16.0": + version "7.16.0" + resolved "https://registry.yarnpkg.com/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.16.0.tgz#090d4d166b342a03a9fec37ef4fd5aeb9c7c6a4b" + integrity sha512-XLwWvqEaq19zFlF5PTgOod4bUA+XbkR4WLQBct1bkzmxJGB0ZEJaoKF4c8cgH9oBtCDuYJ8BP5NB9uFiEgO5QA== dependencies: - "@babel/helper-annotate-as-pure" "^7.14.5" - "@babel/helper-function-name" "^7.14.5" - "@babel/helper-member-expression-to-functions" "^7.14.5" - "@babel/helper-optimise-call-expression" "^7.14.5" - "@babel/helper-replace-supers" "^7.14.5" - "@babel/helper-split-export-declaration" "^7.14.5" + "@babel/helper-annotate-as-pure" "^7.16.0" + "@babel/helper-function-name" "^7.16.0" + "@babel/helper-member-expression-to-functions" "^7.16.0" + "@babel/helper-optimise-call-expression" "^7.16.0" + "@babel/helper-replace-supers" "^7.16.0" + "@babel/helper-split-export-declaration" "^7.16.0" "@babel/helper-create-regexp-features-plugin@^7.12.1": version "7.12.7" @@ -266,6 +289,15 @@ "@babel/template" "^7.14.5" "@babel/types" "^7.14.5" +"@babel/helper-function-name@^7.16.0": + version "7.16.0" + resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.16.0.tgz#b7dd0797d00bbfee4f07e9c4ea5b0e30c8bb1481" + integrity sha512-BZh4mEk1xi2h4HFjWUXRQX5AEx4rvaZxHgax9gcjdLWdkjsY7MKt5p0otjsg5noXw+pB+clMCjw+aEVYADMjog== + dependencies: + "@babel/helper-get-function-arity" "^7.16.0" + "@babel/template" "^7.16.0" + "@babel/types" "^7.16.0" + "@babel/helper-get-function-arity@^7.14.5": version "7.14.5" resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.14.5.tgz#25fbfa579b0937eee1f3b805ece4ce398c431815" @@ -273,6 +305,13 @@ dependencies: "@babel/types" "^7.14.5" +"@babel/helper-get-function-arity@^7.16.0": + version "7.16.0" + resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.16.0.tgz#0088c7486b29a9cb5d948b1a1de46db66e089cfa" + integrity sha512-ASCquNcywC1NkYh/z7Cgp3w31YW8aojjYIlNg4VeJiHkqyP4AzIvr4qx7pYDb4/s8YcsZWqqOSxgkvjUz1kpDQ== + dependencies: + "@babel/types" "^7.16.0" + "@babel/helper-hoist-variables@^7.10.4", "@babel/helper-hoist-variables@^7.14.5": version "7.14.5" resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.14.5.tgz#e0dd27c33a78e577d7c8884916a3e7ef1f7c7f8d" @@ -280,6 +319,13 @@ dependencies: "@babel/types" "^7.14.5" +"@babel/helper-hoist-variables@^7.16.0": + version "7.16.0" + resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.16.0.tgz#4c9023c2f1def7e28ff46fc1dbcd36a39beaa81a" + integrity sha512-1AZlpazjUR0EQZQv3sgRNfM9mEVWPK3M6vlalczA+EECcPz3XPh6VplbErL5UoMpChhSck5wAJHthlj1bYpcmg== + dependencies: + "@babel/types" "^7.16.0" + "@babel/helper-member-expression-to-functions@^7.12.1": version "7.12.7" resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.12.7.tgz#aa77bd0396ec8114e5e30787efa78599d874a855" @@ -301,6 +347,13 @@ dependencies: "@babel/types" "^7.14.5" +"@babel/helper-member-expression-to-functions@^7.16.0": + version "7.16.0" + resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.16.0.tgz#29287040efd197c77636ef75188e81da8bccd5a4" + integrity sha512-bsjlBFPuWT6IWhl28EdrQ+gTvSvj5tqVP5Xeftp07SEuz5pLnsXZuDkDD3Rfcxy0IsHmbZ+7B2/9SHzxO0T+sQ== + dependencies: + "@babel/types" "^7.16.0" + "@babel/helper-module-imports@^7.0.0", "@babel/helper-module-imports@^7.12.1", "@babel/helper-module-imports@^7.12.5", "@babel/helper-module-imports@^7.7.4": version "7.12.5" resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.12.5.tgz#1bfc0229f794988f76ed0a4d4e90860850b54dfb" @@ -358,6 +411,13 @@ dependencies: "@babel/types" "^7.14.5" +"@babel/helper-optimise-call-expression@^7.16.0": + version "7.16.0" + resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.16.0.tgz#cecdb145d70c54096b1564f8e9f10cd7d193b338" + integrity sha512-SuI467Gi2V8fkofm2JPnZzB/SUuXoJA5zXe/xzyPP2M04686RzFKFHPK6HDVN6JvWBIEW8tt9hPR7fXdn2Lgpw== + dependencies: + "@babel/types" "^7.16.0" + "@babel/helper-plugin-utils@^7.0.0", "@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.12.13", "@babel/helper-plugin-utils@^7.13.0", "@babel/helper-plugin-utils@^7.14.5", "@babel/helper-plugin-utils@^7.8.0", "@babel/helper-plugin-utils@^7.8.3": version "7.14.5" resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.14.5.tgz#5ac822ce97eec46741ab70a517971e443a70c5a9" @@ -401,6 +461,16 @@ "@babel/traverse" "^7.14.5" "@babel/types" "^7.14.5" +"@babel/helper-replace-supers@^7.16.0": + version "7.16.0" + resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.16.0.tgz#73055e8d3cf9bcba8ddb55cad93fedc860f68f17" + integrity sha512-TQxuQfSCdoha7cpRNJvfaYxxxzmbxXw/+6cS7V02eeDYyhxderSoMVALvwupA54/pZcOTtVeJ0xccp1nGWladA== + dependencies: + "@babel/helper-member-expression-to-functions" "^7.16.0" + "@babel/helper-optimise-call-expression" "^7.16.0" + "@babel/traverse" "^7.16.0" + "@babel/types" "^7.16.0" + "@babel/helper-simple-access@^7.12.1": version "7.12.1" resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.12.1.tgz#32427e5aa61547d38eb1e6eaf5fd1426fdad9136" @@ -436,6 +506,13 @@ dependencies: "@babel/types" "^7.14.5" +"@babel/helper-split-export-declaration@^7.16.0": + version "7.16.0" + resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.16.0.tgz#29672f43663e936df370aaeb22beddb3baec7438" + integrity sha512-0YMMRpuDFNGTHNRiiqJX19GjNXA4H0E8jZ2ibccfSxaCogbm3am5WN/2nQNj0YnQwGWM1J06GOcQ2qnh3+0paw== + dependencies: + "@babel/types" "^7.16.0" + "@babel/helper-validator-identifier@^7.10.4", "@babel/helper-validator-identifier@^7.14.5": version "7.14.5" resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.14.5.tgz#d0f0e277c512e0c938277faa85a3968c9a44c0e8" @@ -446,6 +523,11 @@ resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.14.8.tgz#32be33a756f29e278a0d644fa08a2c9e0f88a34c" integrity sha512-ZGy6/XQjllhYQrNw/3zfWRwZCTVSiBLZ9DHVZxn9n2gip/7ab8mv2TWlKPIBk26RwedCBoWdjLmn+t9na2Gcow== +"@babel/helper-validator-identifier@^7.15.7": + version "7.15.7" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.15.7.tgz#220df993bfe904a4a6b02ab4f3385a5ebf6e2389" + integrity sha512-K4JvCtQqad9OY2+yTU8w+E82ywk/fe+ELNlt1G8z3bVGlZfn/hOcQQsUhGhW/N+tb3fxK800wLtKOE/aM0m72w== + "@babel/helper-validator-option@^7.12.1", "@babel/helper-validator-option@^7.12.17", "@babel/helper-validator-option@^7.14.5": version "7.14.5" resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.14.5.tgz#6e72a1fff18d5dfcb878e1e62f1a021c4b72d5a3" @@ -498,6 +580,15 @@ chalk "^2.0.0" js-tokens "^4.0.0" +"@babel/highlight@^7.16.0": + version "7.16.0" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.16.0.tgz#6ceb32b2ca4b8f5f361fb7fd821e3fddf4a1725a" + integrity sha512-t8MH41kUQylBtu2+4IQA3atqevA2lRgqA2wyVB/YiWmsDSuylZZuXOUy9ric30hfzauEFfdsuk/eXTRrGrfd0g== + dependencies: + "@babel/helper-validator-identifier" "^7.15.7" + chalk "^2.0.0" + js-tokens "^4.0.0" + "@babel/parser@7.12.5": version "7.12.5" resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.12.5.tgz#b4af32ddd473c0bfa643bd7ff0728b8e71b81ea0" @@ -513,6 +604,11 @@ resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.14.8.tgz#66fd41666b2d7b840bd5ace7f7416d5ac60208d4" integrity sha512-syoCQFOoo/fzkWDeM0dLEZi5xqurb5vuyzwIMNZRNun+N/9A4cUZeQaE7dTrB8jGaKuJRBtEOajtnmw0I5hvvA== +"@babel/parser@^7.16.0", "@babel/parser@^7.16.3": + version "7.16.4" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.16.4.tgz#d5f92f57cf2c74ffe9b37981c0e72fee7311372e" + integrity sha512-6V0qdPUaiVHH3RtZeLIsc+6pDhbYzHR8ogA8w+f+Wc77DuXto19g2QUwveINoS34Uw+W8/hQDGJCx+i4n7xcng== + "@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@^7.14.5": version "7.14.5" resolved "https://registry.yarnpkg.com/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining/-/plugin-bugfix-v8-spread-parameters-in-optional-chaining-7.14.5.tgz#4b467302e1548ed3b1be43beae2cc9cf45e0bb7e" @@ -984,10 +1080,10 @@ dependencies: "@babel/helper-plugin-utils" "^7.14.5" -"@babel/plugin-syntax-typescript@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.14.5.tgz#b82c6ce471b165b5ce420cf92914d6fb46225716" - integrity sha512-u6OXzDaIXjEstBRRoBCQ/uKQKlbuaeE5in0RvWdA4pN6AhqxTIwUsnHPU1CFZA/amYObMsuWhYfRl3Ch90HD0Q== +"@babel/plugin-syntax-typescript@^7.16.0": + version "7.16.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.16.0.tgz#2feeb13d9334cc582ea9111d3506f773174179bb" + integrity sha512-Xv6mEXqVdaqCBfJFyeab0fH2DnUoMsDmhamxsSi4j8nLd4Vtw213WMJr55xxqipC/YVWyPY3K0blJncPYji+dQ== dependencies: "@babel/helper-plugin-utils" "^7.14.5" @@ -1570,14 +1666,14 @@ dependencies: "@babel/helper-plugin-utils" "^7.14.5" -"@babel/plugin-transform-typescript@^7.12.1", "@babel/plugin-transform-typescript@^7.14.5": - version "7.14.6" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.14.6.tgz#6e9c2d98da2507ebe0a883b100cde3c7279df36c" - integrity sha512-XlTdBq7Awr4FYIzqhmYY80WN0V0azF74DMPyFqVHBvf81ZUgc4X7ZOpx6O8eLDK6iM5cCQzeyJw0ynTaefixRA== +"@babel/plugin-transform-typescript@^7.12.1", "@babel/plugin-transform-typescript@^7.16.0": + version "7.16.1" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.16.1.tgz#cc0670b2822b0338355bc1b3d2246a42b8166409" + integrity sha512-NO4XoryBng06jjw/qWEU2LhcLJr1tWkhpMam/H4eas/CDKMX/b2/Ylb6EI256Y7+FVPCawwSM1rrJNOpDiz+Lg== dependencies: - "@babel/helper-create-class-features-plugin" "^7.14.6" + "@babel/helper-create-class-features-plugin" "^7.16.0" "@babel/helper-plugin-utils" "^7.14.5" - "@babel/plugin-syntax-typescript" "^7.14.5" + "@babel/plugin-syntax-typescript" "^7.16.0" "@babel/plugin-transform-unicode-escapes@^7.12.1": version "7.12.1" @@ -1890,13 +1986,13 @@ "@babel/plugin-transform-typescript" "^7.12.1" "@babel/preset-typescript@^7.7.4": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/preset-typescript/-/preset-typescript-7.14.5.tgz#aa98de119cf9852b79511f19e7f44a2d379bcce0" - integrity sha512-u4zO6CdbRKbS9TypMqrlGH7sd2TAJppZwn3c/ZRLeO/wGsbddxgbPDUZVNrie3JWYLQ9vpineKlsrWFvO6Pwkw== + version "7.16.0" + resolved "https://registry.yarnpkg.com/@babel/preset-typescript/-/preset-typescript-7.16.0.tgz#b0b4f105b855fb3d631ec036cdc9d1ffd1fa5eac" + integrity sha512-txegdrZYgO9DlPbv+9QOVpMnKbOtezsLHWsnsRF4AjbSIsVaujrq1qg8HK0mxQpWv0jnejt0yEoW1uWpvbrDTg== dependencies: "@babel/helper-plugin-utils" "^7.14.5" "@babel/helper-validator-option" "^7.14.5" - "@babel/plugin-transform-typescript" "^7.14.5" + "@babel/plugin-transform-typescript" "^7.16.0" "@babel/register@7.12.1": version "7.12.1" @@ -1952,6 +2048,15 @@ "@babel/parser" "^7.14.5" "@babel/types" "^7.14.5" +"@babel/template@^7.16.0": + version "7.16.0" + resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.16.0.tgz#d16a35ebf4cd74e202083356fab21dd89363ddd6" + integrity sha512-MnZdpFD/ZdYhXwiunMqqgyZyucaYsbL0IrjoGjaVhGilz+x8YB++kRfygSOIj1yOtWKPlx7NBp+9I1RQSgsd5A== + dependencies: + "@babel/code-frame" "^7.16.0" + "@babel/parser" "^7.16.0" + "@babel/types" "^7.16.0" + "@babel/traverse@7.12.5": version "7.12.5" resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.12.5.tgz#78a0c68c8e8a35e4cacfd31db8bb303d5606f095" @@ -1997,6 +2102,21 @@ debug "^4.1.0" globals "^11.1.0" +"@babel/traverse@^7.16.0": + version "7.16.3" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.16.3.tgz#f63e8a938cc1b780f66d9ed3c54f532ca2d14787" + integrity sha512-eolumr1vVMjqevCpwVO99yN/LoGL0EyHiLO5I043aYQvwOJ9eR5UsZSClHVCzfhBduMAsSzgA/6AyqPjNayJag== + dependencies: + "@babel/code-frame" "^7.16.0" + "@babel/generator" "^7.16.0" + "@babel/helper-function-name" "^7.16.0" + "@babel/helper-hoist-variables" "^7.16.0" + "@babel/helper-split-export-declaration" "^7.16.0" + "@babel/parser" "^7.16.3" + "@babel/types" "^7.16.0" + debug "^4.1.0" + globals "^11.1.0" + "@babel/types@7.12.6": version "7.12.6" resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.12.6.tgz#ae0e55ef1cce1fbc881cd26f8234eb3e657edc96" @@ -2022,6 +2142,14 @@ "@babel/helper-validator-identifier" "^7.14.8" to-fast-properties "^2.0.0" +"@babel/types@^7.16.0": + version "7.16.0" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.16.0.tgz#db3b313804f96aadd0b776c4823e127ad67289ba" + integrity sha512-PJgg/k3SdLsGb3hhisFvtLOw5ts113klrpLuIPtCJIU+BB24fqq6lf8RWqKJEjzqXR9AEH1rIb5XTqwBHB+kQg== + dependencies: + "@babel/helper-validator-identifier" "^7.15.7" + to-fast-properties "^2.0.0" + "@bcoe/v8-coverage@^0.2.3": version "0.2.3" resolved "https://registry.yarnpkg.com/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz#75a2e8b51cb758a7553d6804a5932d7aace75c39" From 2f41917004b9f5e0875e077edd8e4a387f0e4ef9 Mon Sep 17 00:00:00 2001 From: watsonhaw Date: Fri, 17 Dec 2021 21:50:43 +0800 Subject: [PATCH 5/9] =?UTF-8?q?perf(cli):=20=E5=BC=80=E5=90=AF=20babel-loa?= =?UTF-8?q?der=20=E7=BC=93=E5=AD=98=EF=BC=8C=E4=BC=98=E5=8C=96=E7=BC=96?= =?UTF-8?q?=E8=AF=91=E9=80=9F=E5=BA=A6=20(#1789)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: watsonhaw <348748267@qq.com> --- packages/remax-cli/src/build/webpack/config.mini.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/remax-cli/src/build/webpack/config.mini.ts b/packages/remax-cli/src/build/webpack/config.mini.ts index e6412e1f8..57b4c4705 100644 --- a/packages/remax-cli/src/build/webpack/config.mini.ts +++ b/packages/remax-cli/src/build/webpack/config.mini.ts @@ -110,6 +110,7 @@ export default function webpackConfig(builder: Builder): webpack.Configuration { .options({ usePlugins: [TurboRender.preprocess(options)], reactPreset: false, + cacheDirectory: true, }); } @@ -154,6 +155,7 @@ export default function webpackConfig(builder: Builder): webpack.Configuration { ], reactPreset: true, api: builder.api, + cacheDirectory: true, compact: process.env.NODE_ENV === 'production', }) .end() From 209963b0db994591d440a2436dffd157f5ac0dc9 Mon Sep 17 00:00:00 2001 From: watsonhaw Date: Sat, 18 Dec 2021 23:04:03 +0800 Subject: [PATCH 6/9] =?UTF-8?q?fix(toutiao):=20=E6=96=B0=E5=A2=9Eai/ar?= =?UTF-8?q?=E8=83=BD=E5=8A=9B=E6=8E=A5=E5=8F=A3=20(#1792)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: watsonhaw <348748267@qq.com> --- packages/remax-toutiao/src/api/index.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/remax-toutiao/src/api/index.ts b/packages/remax-toutiao/src/api/index.ts index 872e32418..376c76380 100644 --- a/packages/remax-toutiao/src/api/index.ts +++ b/packages/remax-toutiao/src/api/index.ts @@ -109,3 +109,7 @@ export const setTabBarBadge = promisify(tt.setTabBarBadge); export const removeTabBarBadge = promisify(tt.removeTabBarBadge); export const hideTabBarRedDot = promisify(tt.hideTabBarRedDot); export const hideTabBar = promisify(tt.hideTabBar); +// AI/AR能力 +export const getAlgorithmManager = promisify(tt.getAlgorithmManager); +export const createStickerManager = promisify(tt.createStickerManager); +export const createBytennEngineContext = promisify(tt.createBytennEngineContext); From 18fffef670cc4dbe6d3d0ea532fb944cc4f4adf7 Mon Sep 17 00:00:00 2001 From: watsonhaw Date: Sat, 18 Dec 2021 23:04:52 +0800 Subject: [PATCH 7/9] =?UTF-8?q?fix(toutiao):=20=E6=96=B0=E5=A2=9E=20Movabl?= =?UTF-8?q?eArea/MovableView=E7=BB=84=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * fix(toutiao): 新增 MovableArea/MovableView组件 * test: 更新头条测试文件 Co-authored-by: watsonhaw <348748267@qq.com> --- .../expected/__remax_runtime_options__.js | 36 + .../fixtures/toutiao/expected/base.ttml | 3450 ++++++++++++++--- .../__tests__/components/MovableArea.test.tsx | 11 + .../__tests__/components/MovableView.test.tsx | 11 + .../__snapshots__/MovableArea.test.tsx.snap | 7 + .../__snapshots__/MovableView.test.tsx.snap | 19 + .../src/hostComponents/MovableArea/index.ts | 19 + .../src/hostComponents/MovableArea/node.ts | 11 + .../src/hostComponents/MovableView/index.ts | 83 + .../src/hostComponents/MovableView/node.ts | 29 + .../remax-toutiao/src/hostComponents/index.ts | 2 + .../remax-toutiao/src/hostComponents/node.ts | 4 + packages/remax-toutiao/src/types/component.ts | 24 + packages/remax-toutiao/templates/base.ejs | 57 +- packages/remax-toutiao/templates/children.ejs | 30 + .../remax-toutiao/templates/component.ejs | 75 +- packages/remax-toutiao/tsconfig.json | 5 +- 17 files changed, 3185 insertions(+), 688 deletions(-) create mode 100644 packages/remax-toutiao/src/__tests__/components/MovableArea.test.tsx create mode 100644 packages/remax-toutiao/src/__tests__/components/MovableView.test.tsx create mode 100644 packages/remax-toutiao/src/__tests__/components/__snapshots__/MovableArea.test.tsx.snap create mode 100644 packages/remax-toutiao/src/__tests__/components/__snapshots__/MovableView.test.tsx.snap create mode 100644 packages/remax-toutiao/src/hostComponents/MovableArea/index.ts create mode 100644 packages/remax-toutiao/src/hostComponents/MovableArea/node.ts create mode 100644 packages/remax-toutiao/src/hostComponents/MovableView/index.ts create mode 100644 packages/remax-toutiao/src/hostComponents/MovableView/node.ts create mode 100644 packages/remax-toutiao/templates/children.ejs diff --git a/packages/remax-cli/src/__tests__/integration/fixtures/toutiao/expected/__remax_runtime_options__.js b/packages/remax-cli/src/__tests__/integration/fixtures/toutiao/expected/__remax_runtime_options__.js index b71cd55c0..bce0fbd74 100644 --- a/packages/remax-cli/src/__tests__/integration/fixtures/toutiao/expected/__remax_runtime_options__.js +++ b/packages/remax-cli/src/__tests__/integration/fixtures/toutiao/expected/__remax_runtime_options__.js @@ -513,6 +513,42 @@ module.exports = { "onLoad": "bindload", "onError": "binderror" } + }, + "movable-area": { + "alias": { + "id": "id", + "className": "class", + "style": "style", + "width": "width", + "height": "height" + } + }, + "movable-view": { + "alias": { + "id": "id", + "className": "class", + "style": "style", + "direction": "direction", + "width": "width", + "height": "height", + "x": "x", + "y": "y", + "disabled": "disabled", + "outOfBounds": "out-of-bounds", + "damping": "damping", + "friction": "friction", + "scale": "scale", + "scaleMin": "scale-min", + "scaleMax": "scale-max", + "scaleValue": "scale-value", + "onTouchStart": "touchstart", + "onTouchMove": "touchmove", + "onTouchEnd": "touchend", + "onTouchCancel": "touchcancel", + "onChange": "bindchange", + "onChangeEnd": "bindchangeend", + "onScale": "bindscale" + } } }, pageEvents: { diff --git a/packages/remax-cli/src/__tests__/integration/fixtures/toutiao/expected/base.ttml b/packages/remax-cli/src/__tests__/integration/fixtures/toutiao/expected/base.ttml index 9a8d06a81..c788edf79 100644 --- a/packages/remax-cli/src/__tests__/integration/fixtures/toutiao/expected/base.ttml +++ b/packages/remax-cli/src/__tests__/integration/fixtures/toutiao/expected/base.ttml @@ -1,634 +1,2820 @@