Created
February 20, 2019 03:22
-
-
Save chenyong/3c78bcc6cb06424cb7922089fa7b73ac to your computer and use it in GitHub Desktop.
Some type errors found in upgrading ant typescript
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
✖ 「atl」: Checking finished with 31 errors | |
[at-loader] ../node_modules/@types/react-router/index.d.ts:104:55 | |
TS2344: Type 'keyof T' does not satisfy the constraint 'string'. | |
Type 'string | number | symbol' is not assignable to type 'string'. | |
Type 'number' is not assignable to type 'string'. | |
[at-loader] ../node_modules/@types/react-router-dom/index.d.ts:15:5 | |
TS2305: Module '"../../../../../../../Users/chen/work/web/node_modules/@types/react-router"' has no exported member 'generatePath'. | |
[at-loader] ./ts/report/models/component.ts:55:23 | |
TS2345: Argument of type '(IObservableArray<{ name: string; value: string | number | boolean | ({ plantIds: ...; projectIds: ...; componentIds: ...; processIds: ...; deviceIds: ...; dimensionIds: ...; toolingIds: ...; } & { updatePlantTree(snapshot: any): void; } & IStateTreeNode) | (IObservableArray<...> & ... 1 more ... & ISnapshottable<.....' is not assignable to parameter of type 'IStateTreeNode'. | |
Type 'IObservableArray<{ name: string; value: string | number | boolean | ({ plantIds: ...; projectIds: ...; componentIds: ...; processIds: ...; deviceIds: ...; dimensionIds: ...; toolingIds: ...; } & { updatePlantTree(snapshot: any): void; } & IStateTreeNode) | (IObservableArray<...> & ... 1 more ... & ISnapshottable<......' has no properties in common with type 'IStateTreeNode'. | |
[at-loader] ./ts/report/models/Report.ts:76:23 | |
TS2559: Type 'IObservableArray<{ id: string; name: string; size: number; type: EResourceType; } & IStateTreeNode> & { toJSON?(): Snapshot<{ id: string; name: string; size: number; type: EResourceType; }>[]; } & ISnapshottable<...>' has no properties in common with type 'IStateTreeNode'. | |
[at-loader] ./ts/report/components/pagination/Pagination.tsx:103:7 | |
TS2322: Type '"distributed"' is not assignable to type 'TextJustifyProperty'. | |
[at-loader] ./ts/report/components/text/Text.tsx:99:7 | |
TS2322: Type '"distributed"' is not assignable to type 'TextJustifyProperty'. | |
[at-loader] ../shared/common/jimo-tree.tsx:4:16 | |
TS2305: Module '"../../../../../../Users/chen/work/web/node_modules/antd/lib/tree"' has no exported member 'AntTreeNodeEvent'. | |
[at-loader] ../shared/common/common-table.tsx:242:9 | |
TS2322: Type '(selectedRows: T[]) => void' is not assignable to type '(selectedRowKeys: string[] | number[]) => void'. | |
Types of parameters 'selectedRows' and 'selectedRowKeys' are incompatible. | |
Type 'string[] | number[]' is not assignable to type 'T[]'. | |
Type 'string[]' is not assignable to type 'T[]'. | |
Type 'string' is not assignable to type 'T'. | |
[at-loader] ./ts/pages/causeAnalysis/cause-analysis/CauseAnalysisNodeModal.tsx:293:37 | |
TS2339: Property 'cardinality' does not exist on type 'ReactNode'. | |
Property 'cardinality' does not exist on type 'string'. | |
[at-loader] ./ts/pages/causeAnalysis/cause-analysis/CauseAnalysisNodeModal.tsx:293:69 | |
TS2339: Property 'name' does not exist on type 'ReactNode'. | |
Property 'name' does not exist on type 'string'. | |
[at-loader] ./ts/components/common/DatePickerGroupFormItem.tsx:108:15 | |
TS2322: Type '(date: Moment | [Moment, Moment]) => void' is not assignable to type '(dates: RangePickerValue, dateStrings: [string, string]) => void'. | |
Types of parameters 'date' and 'dates' are incompatible. | |
Type 'RangePickerValue' is not assignable to type 'Moment | [Moment, Moment]'. | |
Type 'undefined[]' is not assignable to type 'Moment | [Moment, Moment]'. | |
Type 'undefined[]' is missing the following properties from type '[Moment, Moment]': 0, 1 | |
[at-loader] ./ts/components/common/DatePickerGroupFormItem.tsx:181:13 | |
TS2322: Type '(date: Moment | [Moment, Moment]) => void' is not assignable to type '(dates: RangePickerValue, dateStrings: [string, string]) => void'. | |
[at-loader] ../shared/common/table-select.tsx:342:67 | |
TS2339: Property 'getElementsByTagName' does not exist on type 'Element | Text'. | |
Property 'getElementsByTagName' does not exist on type 'Text'. | |
[at-loader] ./ts/pages/gaugeManagement/component/taskManagement/new-dropdown-btn.tsx:24:12 | |
TS2322: Type '{ children: string; key: string; value: IWorkflow; }' is not assignable to type 'IntrinsicAttributes & IntrinsicClassAttributes<MenuItem> & Readonly<{ children?: ReactNode; }> & Readonly<MenuItemProps>'. | |
Property 'value' does not exist on type 'IntrinsicAttributes & IntrinsicClassAttributes<MenuItem> & Readonly<{ children?: ReactNode; }> & Readonly<MenuItemProps>'. | |
[at-loader] ../shared/form/region-tree-selector.tsx:11:10 | |
TS2305: Module '"../../../../../../Users/chen/work/web/node_modules/antd/lib/tree-select/interface"' has no exported member 'TreeData'. | |
[at-loader] ./ts/pages/inventoryManagement/check/check-record/record-list.tsx:187:17 | |
TS2322: Type 'RangePickerValue' is not assignable to type '[Moment, Moment]'. | |
Type 'undefined[]' is not assignable to type '[Moment, Moment]'. | |
[at-loader] ./ts/models/flow/Flow.ts:52:23 | |
TS2559: Type 'IObservableArray<{ id: string; name: string; kind: string; description: string; createdAt: string; updatedAt: string; enabled: boolean; config: { boxCapacity: ...; ageLimit: ...; } & IStateTreeNode; componentId: string; ... 4 more ...; loadDimensionsState: RequestState; } & { ...; } & IStateTreeNode> & { ...; } & IS...' has no properties in common with type 'IStateTreeNode'. | |
[at-loader] ../shared/common/confirm.tsx:59:81 | |
TS2339: Property 'infoCircle' does not exist on type 'typeof EJimoIcon'. | |
[at-loader] ./ts/pages/measurementDataAnalysis/alert-rules-setting/AlertSigmaConditions.tsx:36:10 | |
TS2322: Type '{ children: (string | Element)[]; label: string; labelCol: { style: { textAlign: string; }; sm: { span: number; }; }; wrapperCol: { sm: { span: number; }; }; }' is not assignable to type 'Pick<{ readonly children?: ReactNode; readonly prefixCls?: string; readonly className?: string; readonly id?: string; readonly label?: ReactNode; readonly labelCol?: ColProps; readonly wrapperCol?: ColProps; ... 6 more ...; readonly colon?: boolean; } & Pick<...>, "style" | ... 10 more ... | "extra">'. | |
Types of property 'labelCol' are incompatible. | |
Type '{ style: { textAlign: string; }; sm: { span: number; }; }' is not assignable to type 'ColProps'. | |
Types of property 'style' are incompatible. | |
Type '{ textAlign: string; }' is not assignable to type 'CSSProperties'. | |
Types of property 'textAlign' are incompatible. | |
Type 'string' is not assignable to type 'TextAlignProperty'. | |
[at-loader] ./ts/pages/measurementDataAnalysis/alert-rules-setting/AlertSigmaConditions.tsx:52:10 | |
TS2322: Type '{ children: Element; label: string; labelCol: { style: { textAlign: string; }; sm: { span: number; }; }; wrapperCol: { sm: { span: number; }; }; }' is not assignable to type 'Pick<{ readonly children?: ReactNode; readonly prefixCls?: string; readonly className?: string; readonly id?: string; readonly label?: ReactNode; readonly labelCol?: ColProps; readonly wrapperCol?: ColProps; ... 6 more ...; readonly colon?: boolean; } & Pick<...>, "style" | ... 10 more ... | "extra">'. | |
Types of property 'labelCol' are incompatible. | |
Type '{ style: { textAlign: string; }; sm: { span: number; }; }' is not assignable to type 'ColProps'. | |
[at-loader] ../shared/common/base-table-filter.tsx:45:38 | |
TS2345: Argument of type 'CSSProperties' is not assignable to parameter of type 'ClassNameArg'. | |
Type 'CSSProperties' is not assignable to type '{ [key: string]: string | boolean; }'. | |
Index signature is missing in type 'CSSProperties'. | |
[at-loader] ./ts/pages/orderManagement/order/order-statistics/history-order-sale.tsx:81:10 | |
TS2322: Type '{ mode: string; style: { width: number; }; open: boolean; onOpenChange: (status: any) => void; onPanelChange: (date: any) => Promise<void>; allowClear: false; value: Moment; format: EMomentLayout; }' is not assignable to type 'Readonly<DatePickerProps>'. | |
Types of property 'mode' are incompatible. | |
Type 'string' is not assignable to type '"time" | "date" | "year" | "month"'. | |
[at-loader] ../shared/form/region-tree-dropdown.tsx:9:22 | |
TS2305: Module '"../../../../../../Users/chen/work/web/node_modules/antd/lib/tree-select"' has no exported member 'TreeData'. | |
[at-loader] ./ts/components/shell/nav-bar-icons.ts:5:29 | |
TS1096: An index signature must have exactly one parameter. | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment