idux
idux copied to clipboard
V1.0.0 升级指南
- [x] I have searched the issues of this repository and believe that this is not a duplicate.
欢迎来到 @idux 的第一个正式版本,之前版本的用户请参考下列注意事项进行升级。
如果在升级过程中遇到问题,欢迎提出。 如果发现本指南存在遗漏/错误,请指出! 或者你遇到了新的问题并解决了,欢迎补充!
开始之前
- 首先确保你
Node.js>=16.10.0 - 创建新的分支,或者使用其他方式备份当前项目
升级步骤
- 将
@idux/cdk,@idux/components和@idux/pro全部升级到 v1.0.0-rc.9 版本 - 参考下面列出的 breaking changes, 按照提示修改代码
- 运行项目,确保控制台没有
@idux的警告日志 - 将
@idux/cdk,@idux/components和@idux/pro全部升级到 v1.0.0 正式版本
注意事项
-
Select, RadioGroup 和 CheckboxGroup 的 dataSource 默认使用 key 作为选项的值,不再兼容 value, 必须指定
getKey="value"<script lang="ts"> const dataSource = [{ label: 'Tom', value: 'tom'}, { label: 'Jerry', value: 'jerry' }] </script> <template> <IxSelect :dataSource="dataSource" getKey="value" /> </template>
V1.0.0 breaking changes
下面列举出了从 alpha.0 - rc.9 版本间所有的破坏性变更。
CDK
- click-outside
- the
clickOutsidewas deprecated, please usevClickOutsideinstead'
- the
- forms
- the
trimofValidatorOptionswas deprecated. - the
setValidatorwas deprecated, please usesetValidatorsinstead. - the
setAsyncValidatorwas deprecated, please usesetAsyncValidatorsinstead. - the
useValueControlwas deprecated, please useuseControloruseAccessorAndControlinstead. - the
useValueAccessorwas deprecated, please useuseAccessororuseAccessorAndControlinstead.
- the
- popper
- the
modifierswas deprecated, please usemiddlewaresinstead. - the
forceUpdatewas deprecated. - the
onFirstUpdatewas deprecated.
- the
- resize
- the
const { stop } = useResizeObserver()was deprecated, please useconst stop = useResizeObserver()instead.
- the
- scroll
- the
itemKeyofVirtualScrollPropswas deprecated, please usegetKeyinstead.
- the
Components
- cascader
- the
additionalofCascaderDatawas deprecated, please usecustomAdditionalinstead.
- the
- checkbox
- the
optionswas deprecated, please usedataSourceinstead.
- the
- config
- the
targetofDrawerConfigwas deprecated, please usecontainerinstead. - the
targetofDropdownConfigwas deprecated, please useoverlayContainerinstead. - the
targetofImageViewerConfigwas deprecated, please usecontainerinstead. - the
targetofMenuConfigwas deprecated, please useoverlayContainerinstead. - the
targetofMessageConfigwas deprecated, please usecontainerinstead. - the
targetofModalConfigwas deprecated, please usecontainerinstead. - the
targetofNotificationConfigwas deprecated, please usecontainerinstead. - the
targetofPopconfirmConfigwas deprecated, please useoverlayContainerinstead. - the
targetofPopoverConfigwas deprecated, please useoverlayContainerinstead. - the
targetofSelectConfigwas deprecated, please useoverlayContainerinstead. - the
valueKeyofSelectConfigwas deprecated, please usegetKeyinstead. - the
rowKeyofTableConfigwas deprecated, please usegetKeyinstead. - the
targetofTooltipConfigwas deprecated, please useoverlayContainerinstead. - the
nodeKeyofTreeConfigwas deprecated, please usegetKeyinstead. - the
nodeKeyofTreeSelectConfigwas deprecated, please usegetKeyinstead. - the
targetofTreeSelectConfigwas deprecated, please useoverlayContainerinstead.
- the
- divider
- the
positionwas deprecated, please uselabelPlacementinstead. - the
typewas deprecated, please useverticalinstead.
- the
- drawer
- the
targetwas deprecated, please usecontainerinstead. - the
wrapperClassNamewas deprecated.
- the
- dropdown
- the
targetwas deprecated, please useoverlayContainerinstead.
- the
- form
- the
hasFeedbackwas deprecated. - the
statusIconwas deprecated. - the
extrawas deprecated, please usedescriptioninstead. - the
extraMessagewas deprecated, please usedescriptioninstead. - the
useFormAccessorwas deprecated, please useuseAccessorAndControl+useFormItemRegisterinstead.
- the
- image
- the
targetwas deprecated, please usecontainerinstead.
- the
- menu
- the
targetwas deprecated, please useoverlayContainerinstead. - the
additionalofMenuIDatawas deprecated, please usecustomAdditionalinstead'. - the
slotsofMenuDatawas deprecated, please usecustomIconandcustomLabelinstead'.
- the
- message
- the
targetwas deprecated, please usecontainerinstead.
- the
- modal
- the
targetwas deprecated, please usecontainerinstead. - the
wrapperClassNamewas deprecated.
- the
- notification
- the
targetwas deprecated, please usecontainerinstead.
- the
- radio
- the
optionswas deprecated, please usedataSourceinstead.
- the
- select
- the
maxLabelCountwas deprecated, please usemaxLabelinstead. - the
optionswas deprecated, please usedataSourceinstead. - the
searchFilterwas deprecated, please usesearchFninstead'. - the
targetwas deprecated, please useoverlayContainerinstead. - the
valueKeywas deprecated, please usegetKeyinstead. - the
additionalofSelectDatawas deprecated, please usecustomAdditionalinstead.
- the
- space
- the
directionwas deprecated, please useverticalinstead. - the
splitwas deprecated, please useseparatorinstead.
- the
- table
- the
rowClassNamewas deprecated, please usecustomAdditionalinstead. - the
rowKeywas deprecated, please usegetKeyinstead. - the
scrll.xwas deprecated, please usescrll.widthinstead. - the
scrll.ywas deprecated, please usescrll.heightinstead. - the
additionalofTableColumnwas deprecated, please usecustomAdditionalinstead'. - the
customRenderofTableColumnwas deprecated, please usecustomCellof TableColumn instead'. - the
responsiveofTableColumnwas deprecated.
- the
- tooltip, popover, popconfirm
- the
targetwas deprecated, please useoverlayContainerinstead.
- the
- tree
- the
cascadeandcheckStrategyare deprecated, please usecascaderStrategyinstead. - the
nodeKeyare deprecated, please usegetKeyinstead. - the
additionalofTreeNodewas deprecated, please usecustomAdditionalinstead'.
- the
- tree-select
- the
cascadeandcheckStrategyare deprecated, please usecascaderStrategyinstead. - the
maxLabelCountare deprecated, please usemaxLabelinstead. - the
nodeKeyare deprecated, please usegetKeyinstead. - the
targetare deprecated, please useoverlayContainerinstead. - the
additionalofTreeNodewas deprecated, please usecustomAdditionalinstead.
- the
- typography
- the directive was deprecated.