mirror of https://github.com/alibaba/ice.git
Merge pull request #7025 from alibaba/release/next
Release @ice/app 3.5.1
This commit is contained in:
commit
6b3167acf5
|
@ -1,5 +1,14 @@
|
||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
## 3.5.1
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- Updated dependencies [4130611d]
|
||||||
|
- Updated dependencies [2e274966]
|
||||||
|
- @ice/rspack-config@1.2.1
|
||||||
|
- @ice/runtime@1.5.1
|
||||||
|
|
||||||
## 3.5.0
|
## 3.5.0
|
||||||
|
|
||||||
### Minor Changes
|
### Minor Changes
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@ice/app",
|
"name": "@ice/app",
|
||||||
"version": "3.5.0",
|
"version": "3.5.1",
|
||||||
"description": "provide scripts and configuration used by web framework ice",
|
"description": "provide scripts and configuration used by web framework ice",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"main": "./esm/index.js",
|
"main": "./esm/index.js",
|
||||||
|
|
|
@ -1,5 +1,11 @@
|
||||||
# @ice/jsx-runtime
|
# @ice/jsx-runtime
|
||||||
|
|
||||||
|
## 0.3.1
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- 2e274966: fix: export createElement for backward compatibility
|
||||||
|
|
||||||
## 0.3.0
|
## 0.3.0
|
||||||
|
|
||||||
### Minor Changes
|
### Minor Changes
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@ice/jsx-runtime",
|
"name": "@ice/jsx-runtime",
|
||||||
"version": "0.3.0",
|
"version": "0.3.1",
|
||||||
"description": "JSX runtime for ice.",
|
"description": "JSX runtime for ice.",
|
||||||
"files": [
|
"files": [
|
||||||
"esm",
|
"esm",
|
||||||
|
@ -34,7 +34,8 @@
|
||||||
"jsx-runtime"
|
"jsx-runtime"
|
||||||
],
|
],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"style-unit": "^3.0.4"
|
"style-unit": "^3.0.4",
|
||||||
|
"@swc/helpers": "^0.5.13"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@ice/pkg": "^1.5.0",
|
"@ice/pkg": "^1.5.0",
|
||||||
|
|
|
@ -0,0 +1,5 @@
|
||||||
|
import { createElement as reactCreateElement } from 'react';
|
||||||
|
import { hijackElementProps } from './style.js';
|
||||||
|
export function createElement(type: any, props: any, ...children: any[]) {
|
||||||
|
return reactCreateElement(type, hijackElementProps(props), ...children);
|
||||||
|
}
|
|
@ -1 +1,2 @@
|
||||||
export * from './prod.js';
|
export * from './prod.js';
|
||||||
|
export { createElement } from './createElement.js';
|
||||||
|
|
|
@ -1,5 +1,11 @@
|
||||||
# @ice/miniapp-react-dom
|
# @ice/miniapp-react-dom
|
||||||
|
|
||||||
|
## 1.1.1
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- @ice/miniapp-runtime@1.2.1
|
||||||
|
|
||||||
## 1.1.0
|
## 1.1.0
|
||||||
|
|
||||||
### Minor Changes
|
### Minor Changes
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@ice/miniapp-react-dom",
|
"name": "@ice/miniapp-react-dom",
|
||||||
"version": "1.1.0",
|
"version": "1.1.1",
|
||||||
"description": "like react-dom, but for miniapps.",
|
"description": "like react-dom, but for miniapps.",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"types": "./esm/index.d.ts",
|
"types": "./esm/index.d.ts",
|
||||||
|
|
|
@ -1,5 +1,12 @@
|
||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
## 1.2.1
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- Updated dependencies [2e274966]
|
||||||
|
- @ice/runtime@1.5.1
|
||||||
|
|
||||||
## 1.2.0
|
## 1.2.0
|
||||||
|
|
||||||
### Minor Changes
|
### Minor Changes
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@ice/miniapp-runtime",
|
"name": "@ice/miniapp-runtime",
|
||||||
"version": "1.2.0",
|
"version": "1.2.1",
|
||||||
"description": "ice runtime for miniapps.",
|
"description": "ice runtime for miniapps.",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"types": "./esm/index.d.ts",
|
"types": "./esm/index.d.ts",
|
||||||
|
|
|
@ -39,7 +39,7 @@
|
||||||
"plugin"
|
"plugin"
|
||||||
],
|
],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@ice/jsx-runtime": "^0.3.0",
|
"@ice/jsx-runtime": "^0.3.1",
|
||||||
"@swc/helpers": "^0.5.1",
|
"@swc/helpers": "^0.5.1",
|
||||||
"accept-language-parser": "^1.5.0",
|
"accept-language-parser": "^1.5.0",
|
||||||
"universal-cookie": "^4.0.4",
|
"universal-cookie": "^4.0.4",
|
||||||
|
@ -56,8 +56,8 @@
|
||||||
"webpack-dev-server": "4.15.0"
|
"webpack-dev-server": "4.15.0"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ice/app": "^3.5.0",
|
"@ice/app": "^3.5.1",
|
||||||
"@ice/runtime": "^1.5.0"
|
"@ice/runtime": "^1.5.1"
|
||||||
},
|
},
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
|
|
|
@ -1,5 +1,13 @@
|
||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
## 1.2.1
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- cce46e9b: fix: should check skeleton file existed before read
|
||||||
|
- @ice/miniapp-runtime@1.2.1
|
||||||
|
- @ice/miniapp-react-dom@1.1.1
|
||||||
|
|
||||||
## 1.2.0
|
## 1.2.0
|
||||||
|
|
||||||
### Minor Changes
|
### Minor Changes
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@ice/plugin-miniapp",
|
"name": "@ice/plugin-miniapp",
|
||||||
"version": "1.2.0",
|
"version": "1.2.1",
|
||||||
"description": "ice.js plugin for miniapp.",
|
"description": "ice.js plugin for miniapp.",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
|
@ -50,8 +50,8 @@
|
||||||
"sax": "^1.2.4"
|
"sax": "^1.2.4"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@ice/app": "^3.5.0",
|
"@ice/app": "^3.5.1",
|
||||||
"@ice/runtime": "^1.5.0",
|
"@ice/runtime": "^1.5.1",
|
||||||
"webpack": "^5.88.0"
|
"webpack": "^5.88.0"
|
||||||
},
|
},
|
||||||
"repository": {
|
"repository": {
|
||||||
|
|
|
@ -588,6 +588,7 @@ export default class MiniPlugin {
|
||||||
path: pagePath,
|
path: pagePath,
|
||||||
isNative,
|
isNative,
|
||||||
stylePath: isNative ? this.getStylePath(pagePath) : undefined,
|
stylePath: isNative ? this.getStylePath(pagePath) : undefined,
|
||||||
|
templatePath: isNative ? this.getTemplatePath(pagePath) : undefined,
|
||||||
skeletonPath: isNative ? this.getSkeletonExtraPath(pagePath) : undefined,
|
skeletonPath: isNative ? this.getSkeletonExtraPath(pagePath) : undefined,
|
||||||
};
|
};
|
||||||
}),
|
}),
|
||||||
|
@ -690,10 +691,10 @@ export default class MiniPlugin {
|
||||||
}
|
}
|
||||||
this.addEntry(path.resolve(__dirname, '..', 'template/custom-wrapper'), 'custom-wrapper', META_TYPE.STATIC);
|
this.addEntry(path.resolve(__dirname, '..', 'template/custom-wrapper'), 'custom-wrapper', META_TYPE.STATIC);
|
||||||
|
|
||||||
const resolveComponentStyleEntry = (name: string, stylePaths: string[]) => {
|
const resolveComponentStyleEntry = (name: string, stylePaths: string[], ext = this.options.fileType.style) => {
|
||||||
for (const stylePath of stylePaths) {
|
for (const stylePath of stylePaths) {
|
||||||
if (fs.existsSync(stylePath)) {
|
if (fs.existsSync(stylePath)) {
|
||||||
this.addEntry(stylePath, this.getTargetFilePath(name, this.options.fileType.style), META_TYPE.NORMAL);
|
this.addEntry(stylePath, this.getTargetFilePath(name, ext), META_TYPE.NORMAL);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -709,12 +710,10 @@ export default class MiniPlugin {
|
||||||
this.addEntry(item.templatePath, this.getTemplatePath(item.name), META_TYPE.NORMAL);
|
this.addEntry(item.templatePath, this.getTemplatePath(item.name), META_TYPE.NORMAL);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (item.skeletonPath) {
|
if (item.skeletonPath && item.skeletonPath.template && fs.existsSync(item.skeletonPath.template)) {
|
||||||
if (item.skeletonPath.template) {
|
this.addEntry(item.skeletonPath.template, this.getTargetFilePath(item.name, `${this.options.fileType.skeletonMidExt}${this.options.fileType.templ}`), META_TYPE.NORMAL);
|
||||||
this.addEntry(item.skeletonPath.template, this.getTargetFilePath(item.name, `${this.options.fileType.skeletonMidExt}${this.options.fileType.templ}`), META_TYPE.NORMAL);
|
|
||||||
}
|
|
||||||
if (item.skeletonPath.style) {
|
if (item.skeletonPath.style) {
|
||||||
resolveComponentStyleEntry(this.getTargetFilePath(item.name, this.options.fileType.skeletonMidExt), item.skeletonPath.style);
|
resolveComponentStyleEntry(item.name, item.skeletonPath.style, `${this.options.fileType.skeletonMidExt}${this.options.fileType.style}`);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -1,5 +1,11 @@
|
||||||
# @ice/rspack-config
|
# @ice/rspack-config
|
||||||
|
|
||||||
|
## 1.2.1
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- 4130611d: fix: update splitChunk config
|
||||||
|
|
||||||
## 1.2.0
|
## 1.2.0
|
||||||
|
|
||||||
### Minor Changes
|
### Minor Changes
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@ice/rspack-config",
|
"name": "@ice/rspack-config",
|
||||||
"version": "1.2.0",
|
"version": "1.2.1",
|
||||||
"repository": "alibaba/ice",
|
"repository": "alibaba/ice",
|
||||||
"bugs": "https://github.com/alibaba/ice/issues",
|
"bugs": "https://github.com/alibaba/ice/issues",
|
||||||
"homepage": "https://v3.ice.work",
|
"homepage": "https://v3.ice.work",
|
||||||
|
|
|
@ -87,8 +87,9 @@ export const getVendorStrategy = (options: Configuration['splitChunks']) => {
|
||||||
|
|
||||||
const getSplitChunks = (_: string, strategy: string | boolean) => {
|
const getSplitChunks = (_: string, strategy: string | boolean) => {
|
||||||
if (strategy === false) {
|
if (strategy === false) {
|
||||||
// Empty splitChunks configuration if strategy is false.
|
// Set minChunks to a large number to disable the splitChunks feature.
|
||||||
return {};
|
// the value of Infinity is not work properly for this version of rspack.
|
||||||
|
return { minChunks: 100000, cacheGroups: { default: false } };
|
||||||
} else if (typeof strategy === 'string' && ['page-vendors', 'vendors'].includes(strategy)) {
|
} else if (typeof strategy === 'string' && ['page-vendors', 'vendors'].includes(strategy)) {
|
||||||
const splitChunksOptions = strategy === 'page-vendors' ? { chunks: 'all' } : {};
|
const splitChunksOptions = strategy === 'page-vendors' ? { chunks: 'all' } : {};
|
||||||
return getVendorStrategy(splitChunksOptions);
|
return getVendorStrategy(splitChunksOptions);
|
||||||
|
|
|
@ -1,5 +1,13 @@
|
||||||
# @ice/runtime
|
# @ice/runtime
|
||||||
|
|
||||||
|
## 1.5.1
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- 2e274966: feat: support hook of onBeforeHydrate
|
||||||
|
- Updated dependencies [2e274966]
|
||||||
|
- @ice/jsx-runtime@0.3.1
|
||||||
|
|
||||||
## 1.5.0
|
## 1.5.0
|
||||||
|
|
||||||
### Minor Changes
|
### Minor Changes
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@ice/runtime",
|
"name": "@ice/runtime",
|
||||||
"version": "1.5.0",
|
"version": "1.5.1",
|
||||||
"description": "Runtime module for ice.js",
|
"description": "Runtime module for ice.js",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"types": "./esm/index.d.ts",
|
"types": "./esm/index.d.ts",
|
||||||
|
@ -54,7 +54,7 @@
|
||||||
"./esm/polyfills/abortcontroller.js"
|
"./esm/polyfills/abortcontroller.js"
|
||||||
],
|
],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@ice/jsx-runtime": "^0.3.0",
|
"@ice/jsx-runtime": "^0.3.1",
|
||||||
"@ice/shared": "^1.1.0",
|
"@ice/shared": "^1.1.0",
|
||||||
"@remix-run/router": "1.14.2",
|
"@remix-run/router": "1.14.2",
|
||||||
"abortcontroller-polyfill": "1.7.5",
|
"abortcontroller-polyfill": "1.7.5",
|
||||||
|
|
|
@ -120,6 +120,9 @@ export default async function runClientApp(options: RunClientAppOptions) {
|
||||||
reportRecoverableError(error, errorInfo, { ignoreRuntimeWarning: revalidate });
|
reportRecoverableError(error, errorInfo, { ignoreRuntimeWarning: revalidate });
|
||||||
}),
|
}),
|
||||||
};
|
};
|
||||||
|
if (appConfig?.app?.onBeforeHydrate) {
|
||||||
|
appConfig?.app?.onBeforeHydrate();
|
||||||
|
}
|
||||||
return ReactDOM.hydrateRoot(container, element, hydrateOptions);
|
return ReactDOM.hydrateRoot(container, element, hydrateOptions);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -17,6 +17,7 @@ type App = Partial<{
|
||||||
strict: boolean;
|
strict: boolean;
|
||||||
errorBoundary: boolean;
|
errorBoundary: boolean;
|
||||||
onRecoverableError: (error: unknown, errorInfo: ErrorStack) => void;
|
onRecoverableError: (error: unknown, errorInfo: ErrorStack) => void;
|
||||||
|
onBeforeHydrate: () => void;
|
||||||
} & Record<AppLifecycle, VoidFunction>>;
|
} & Record<AppLifecycle, VoidFunction>>;
|
||||||
|
|
||||||
export interface ErrorStack {
|
export interface ErrorStack {
|
||||||
|
|
|
@ -1813,6 +1813,9 @@ importers:
|
||||||
|
|
||||||
packages/jsx-runtime:
|
packages/jsx-runtime:
|
||||||
dependencies:
|
dependencies:
|
||||||
|
'@swc/helpers':
|
||||||
|
specifier: ^0.5.13
|
||||||
|
version: 0.5.13
|
||||||
style-unit:
|
style-unit:
|
||||||
specifier: ^3.0.4
|
specifier: ^3.0.4
|
||||||
version: 3.0.5
|
version: 3.0.5
|
||||||
|
@ -1987,7 +1990,7 @@ importers:
|
||||||
packages/plugin-i18n:
|
packages/plugin-i18n:
|
||||||
dependencies:
|
dependencies:
|
||||||
'@ice/jsx-runtime':
|
'@ice/jsx-runtime':
|
||||||
specifier: ^0.3.0
|
specifier: ^0.3.1
|
||||||
version: link:../jsx-runtime
|
version: link:../jsx-runtime
|
||||||
'@swc/helpers':
|
'@swc/helpers':
|
||||||
specifier: ^0.5.1
|
specifier: ^0.5.1
|
||||||
|
@ -2154,10 +2157,10 @@ importers:
|
||||||
version: 1.2.4
|
version: 1.2.4
|
||||||
devDependencies:
|
devDependencies:
|
||||||
'@ice/app':
|
'@ice/app':
|
||||||
specifier: ^3.5.0
|
specifier: ^3.5.1
|
||||||
version: link:../ice
|
version: link:../ice
|
||||||
'@ice/runtime':
|
'@ice/runtime':
|
||||||
specifier: ^1.5.0
|
specifier: ^1.5.1
|
||||||
version: link:../runtime
|
version: link:../runtime
|
||||||
webpack:
|
webpack:
|
||||||
specifier: ^5.88.0
|
specifier: ^5.88.0
|
||||||
|
@ -2398,7 +2401,7 @@ importers:
|
||||||
packages/runtime:
|
packages/runtime:
|
||||||
dependencies:
|
dependencies:
|
||||||
'@ice/jsx-runtime':
|
'@ice/jsx-runtime':
|
||||||
specifier: ^0.3.0
|
specifier: ^0.3.1
|
||||||
version: link:../jsx-runtime
|
version: link:../jsx-runtime
|
||||||
'@ice/shared':
|
'@ice/shared':
|
||||||
specifier: ^1.1.0
|
specifier: ^1.1.0
|
||||||
|
@ -8575,6 +8578,12 @@ packages:
|
||||||
dependencies:
|
dependencies:
|
||||||
tslib: 2.5.0
|
tslib: 2.5.0
|
||||||
|
|
||||||
|
/@swc/helpers@0.5.13:
|
||||||
|
resolution: {integrity: sha512-UoKGxQ3r5kYI9dALKJapMmuK+1zWM/H17Z1+iwnNmzcJRnfFuevZs375TA5rW31pu4BS4NoSy1fRsexDXfWn5w==}
|
||||||
|
dependencies:
|
||||||
|
tslib: 2.5.0
|
||||||
|
dev: false
|
||||||
|
|
||||||
/@swc/types@0.1.4:
|
/@swc/types@0.1.4:
|
||||||
resolution: {integrity: sha512-z/G02d+59gyyUb7KYhKi9jOhicek6QD2oMaotUyG+lUkybpXoV49dY9bj7Ah5Q+y7knK2jU67UTX9FyfGzaxQg==}
|
resolution: {integrity: sha512-z/G02d+59gyyUb7KYhKi9jOhicek6QD2oMaotUyG+lUkybpXoV49dY9bj7Ah5Q+y7knK2jU67UTX9FyfGzaxQg==}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue