Match-id-ea4942c4f8514e5b0adb9724b27bb99862b5a5c2
This commit is contained in:
commit
824b243b9e
|
@ -1,3 +1,7 @@
|
||||||
|
## 0.0.41 (2023-03-15)
|
||||||
|
- **core**: #105 redux + forwardRef组合使用场景会报错,redux获取组件类型不对
|
||||||
|
- **core**: 增加jsx-dev-runtime文件,给vite使用
|
||||||
|
|
||||||
## 0.0.40 (2023-03-08)
|
## 0.0.40 (2023-03-08)
|
||||||
- **core**: #103 使用Memo、React.forwardRef包装组件后,defaultProps失效
|
- **core**: #103 使用Memo、React.forwardRef包装组件后,defaultProps失效
|
||||||
- **core**: #104 --max-segment-num的style无法使用
|
- **core**: #104 --max-segment-num的style无法使用
|
||||||
|
|
|
@ -18,6 +18,8 @@ import {
|
||||||
TYPE_PROFILER as Profiler,
|
TYPE_PROFILER as Profiler,
|
||||||
TYPE_STRICT_MODE as StrictMode,
|
TYPE_STRICT_MODE as StrictMode,
|
||||||
TYPE_SUSPENSE as Suspense,
|
TYPE_SUSPENSE as Suspense,
|
||||||
|
TYPE_FORWARD_REF as ForwardRef,
|
||||||
|
TYPE_MEMO as Memo,
|
||||||
} from './src/external/JSXElementType';
|
} from './src/external/JSXElementType';
|
||||||
|
|
||||||
import { Component, PureComponent } from './src/renderer/components/BaseClassComponent';
|
import { Component, PureComponent } from './src/renderer/components/BaseClassComponent';
|
||||||
|
@ -87,10 +89,6 @@ const Horizon = {
|
||||||
useReducer,
|
useReducer,
|
||||||
useRef,
|
useRef,
|
||||||
useState,
|
useState,
|
||||||
Fragment,
|
|
||||||
Profiler,
|
|
||||||
StrictMode,
|
|
||||||
Suspense,
|
|
||||||
createElement,
|
createElement,
|
||||||
cloneElement,
|
cloneElement,
|
||||||
isValidElement,
|
isValidElement,
|
||||||
|
@ -115,6 +113,12 @@ const Horizon = {
|
||||||
isPortal,
|
isPortal,
|
||||||
isContextProvider,
|
isContextProvider,
|
||||||
isContextConsumer,
|
isContextConsumer,
|
||||||
|
ForwardRef,
|
||||||
|
Memo,
|
||||||
|
Fragment,
|
||||||
|
Profiler,
|
||||||
|
StrictMode,
|
||||||
|
Suspense,
|
||||||
};
|
};
|
||||||
|
|
||||||
export const version = __VERSION__;
|
export const version = __VERSION__;
|
||||||
|
@ -137,10 +141,6 @@ export {
|
||||||
useReducer,
|
useReducer,
|
||||||
useRef,
|
useRef,
|
||||||
useState,
|
useState,
|
||||||
Fragment,
|
|
||||||
Profiler,
|
|
||||||
StrictMode,
|
|
||||||
Suspense,
|
|
||||||
createElement,
|
createElement,
|
||||||
cloneElement,
|
cloneElement,
|
||||||
isValidElement,
|
isValidElement,
|
||||||
|
@ -167,6 +167,12 @@ export {
|
||||||
isPortal,
|
isPortal,
|
||||||
isContextProvider,
|
isContextProvider,
|
||||||
isContextConsumer,
|
isContextConsumer,
|
||||||
|
ForwardRef,
|
||||||
|
Memo,
|
||||||
|
Fragment,
|
||||||
|
Profiler,
|
||||||
|
StrictMode,
|
||||||
|
Suspense,
|
||||||
};
|
};
|
||||||
|
|
||||||
export default Horizon;
|
export default Horizon;
|
||||||
|
|
|
@ -0,0 +1,24 @@
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2020 Huawei Technologies Co.,Ltd.
|
||||||
|
*
|
||||||
|
* openGauss is licensed under Mulan PSL v2.
|
||||||
|
* You can use this software according to the terms and conditions of the Mulan PSL v2.
|
||||||
|
* You may obtain a copy of Mulan PSL v2 at:
|
||||||
|
*
|
||||||
|
* http://license.coscl.org.cn/MulanPSL2
|
||||||
|
*
|
||||||
|
* THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
|
||||||
|
* EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
|
||||||
|
* MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
|
||||||
|
* See the Mulan PSL v2 for more details.
|
||||||
|
*/
|
||||||
|
|
||||||
|
import {
|
||||||
|
TYPE_FRAGMENT as Fragment,
|
||||||
|
} from './src/external/JSXElementType';
|
||||||
|
import { jsx as jsxDEV } from './src/external/JSXElement';
|
||||||
|
|
||||||
|
export {
|
||||||
|
jsxDEV,
|
||||||
|
Fragment
|
||||||
|
};
|
|
@ -4,7 +4,7 @@
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"horizon"
|
"horizon"
|
||||||
],
|
],
|
||||||
"version": "0.0.40",
|
"version": "0.0.41",
|
||||||
"homepage": "",
|
"homepage": "",
|
||||||
"bugs": "",
|
"bugs": "",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
|
|
|
@ -18,6 +18,7 @@ import { TYPE_FORWARD_REF } from '../../external/JSXElementType';
|
||||||
export function forwardRef(render: Function) {
|
export function forwardRef(render: Function) {
|
||||||
return {
|
return {
|
||||||
vtype: TYPE_FORWARD_REF,
|
vtype: TYPE_FORWARD_REF,
|
||||||
|
$$typeof: TYPE_FORWARD_REF, // 规避三方件hoist-non-react-statics中,通过$$typeof获取类型,但获取不到导致的错误
|
||||||
render,
|
render,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -20,8 +20,8 @@ import fs from 'fs';
|
||||||
import replace from '@rollup/plugin-replace';
|
import replace from '@rollup/plugin-replace';
|
||||||
import copy from './copy-plugin';
|
import copy from './copy-plugin';
|
||||||
import execute from 'rollup-plugin-execute';
|
import execute from 'rollup-plugin-execute';
|
||||||
import { terser } from 'rollup-plugin-terser';
|
import {terser} from 'rollup-plugin-terser';
|
||||||
import { version as horizonVersion } from '@cloudsop/horizon/package.json';
|
import {version as horizonVersion} from '@cloudsop/horizon/package.json';
|
||||||
|
|
||||||
const extensions = ['.js', '.ts'];
|
const extensions = ['.js', '.ts'];
|
||||||
|
|
||||||
|
@ -107,17 +107,29 @@ function genConfig(mode) {
|
||||||
}
|
}
|
||||||
|
|
||||||
function genJSXRuntimeConfig(mode) {
|
function genJSXRuntimeConfig(mode) {
|
||||||
return {
|
return {
|
||||||
input: path.resolve(libDir, 'jsx-runtime.ts'),
|
input: path.resolve(libDir, 'jsx-runtime.ts'),
|
||||||
output: [
|
output: {
|
||||||
{
|
file: outputResolve('jsx-runtime.js'),
|
||||||
file: outputResolve('jsx-runtime.js'),
|
format: 'cjs',
|
||||||
format: 'cjs',
|
},
|
||||||
}
|
plugins: [
|
||||||
],
|
...getBasicPlugins(mode)
|
||||||
plugins: [
|
]
|
||||||
...getBasicPlugins(mode)
|
};
|
||||||
]
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
export default [genConfig('development'), genConfig('production'), genJSXRuntimeConfig('')];
|
|
||||||
|
function genJSXDEVRuntimeConfig(mode) {
|
||||||
|
return {
|
||||||
|
input: path.resolve(libDir, 'jsx-dev-runtime.ts'),
|
||||||
|
output: {
|
||||||
|
file: outputResolve('jsx-dev-runtime.js'),
|
||||||
|
format: 'cjs',
|
||||||
|
},
|
||||||
|
plugins: [
|
||||||
|
...getBasicPlugins(mode)
|
||||||
|
]
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
export default [genConfig('development'), genConfig('production'), genJSXRuntimeConfig(''), genJSXDEVRuntimeConfig('')];
|
||||||
|
|
Loading…
Reference in New Issue