$ tsc && cross-env NODE_OPTIONS=--max-old-space-size=6096 vite build
src/App.tsx:222:80 - error TS2769: No overload matches this call.
Overload 1 of 2, '(props: (RouteProps<"/job-task/:busiId/output/:taskId/:outputType", { busiId: string; } & { taskId: string; } & { outputType: string; }> & OmitNative<{}, keyof RouteProps<string, { [x: string]: string | undefined; }>>) | Readonly<...>): Route<...>', gave the following error.
Type 'typeof index' is not assignable to type 'ComponentType<any> | ComponentType<RouteComponentProps<any, StaticContext, unknown>> | undefined'.
Type 'typeof index' is not assignable to type 'ComponentClass<any, any>'.
Types of property 'contextType' are incompatible.
Type 'React.Context<any> | undefined' is not assignable to type 'import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").Context<any> | undefined'.
Type 'React.Context<any>' is not assignable to type 'import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").Context<any>'.
The types of 'Provider.propTypes' are incompatible between these types.
Type 'React.WeakValidationMap<React.ProviderProps<any>> | undefined' is not assignable to type 'import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").WeakValidationMap<import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").ProviderProps<any>> | undefined'.
Type 'React.WeakValidationMap<React.ProviderProps<any>>' is not assignable to type 'import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").WeakValidationMap<import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").ProviderProps<any>>'.
Types of property 'children' are incompatible.
Type 'React.Validator<React.ReactNode> | undefined' is not assignable to type 'import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").Validator<import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").ReactNode> | undefined'.
Type 'React.Validator<React.ReactNode>' is not assignable to type 'import("F:/WebStormProject/fe-sar/node_modules/@types/prop-types/index").Validator<import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").ReactNode>'.
Type 'React.ReactNode' is not assignable to type 'import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").ReactNode'.
Overload 2 of 2, '(props: RouteProps<"/job-task/:busiId/output/:taskId/:outputType", { busiId: string; } & { taskId: string; } & { outputType: string; }> & OmitNative<{}, keyof RouteProps<string, { [x: string]: string | undefined; }>>, context: any): Route<...>', gave the following error.
Type 'typeof index' is not assignable to type 'ComponentType<any> | ComponentType<RouteComponentProps<any, StaticContext, unknown>> | undefined'.
222 <Route exact path='/job-task/:busiId/output/:taskId/:outputType' component={TaskOutput} />
~~~~~~~~~
node_modules/@types/react-router/index.d.ts:92:5
92 component?: React.ComponentType<RouteComponentProps<any>> | React.ComponentType<any> | undefined;
~~~~~~~~~
The expected type comes from property 'component' which is declared here on type 'IntrinsicAttributes & IntrinsicClassAttributes<Route<{}, "/job-task/:busiId/output/:taskId/:outputType">> & Readonly<...>'
node_modules/@types/react-router/index.d.ts:92:5
92 component?: React.ComponentType<RouteComponentProps<any>> | React.ComponentType<any> | undefined;
~~~~~~~~~
The expected type comes from property 'component' which is declared here on type 'IntrinsicAttributes & IntrinsicClassAttributes<Route<{}, "/job-task/:busiId/output/:taskId/:outputType">> & Readonly<...>'
src/App.tsx:223:86 - error TS2769: No overload matches this call.
Overload 1 of 2, '(props: (RouteProps<"/job-task/:busiId/output/:taskId/:host/:outputType", { busiId: string; } & { taskId: string; } & { host: string; } & { outputType: string; }> & OmitNative<{}, keyof RouteProps<...>>) | Readonly<...>): Route<...>', gave the following error.
Type 'typeof index' is not assignable to type 'ComponentType<any> | ComponentType<RouteComponentProps<any, StaticContext, unknown>> | undefined'.
Type 'typeof index' is not assignable to type 'ComponentClass<any, any>'.
Types of property 'contextType' are incompatible.
Type 'React.Context<any> | undefined' is not assignable to type 'import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").Context<any> | undefined'.
Overload 2 of 2, '(props: RouteProps<"/job-task/:busiId/output/:taskId/:host/:outputType", { busiId: string; } & { taskId: string; } & { host: string; } & { outputType: string; }> & OmitNative<{}, keyof RouteProps<...>>, context: any): Route<...>', gave the following error.
Type 'typeof index' is not assignable to type 'ComponentType<any> | ComponentType<RouteComponentProps<any, StaticContext, unknown>> | undefined'.
223 <Route exact path='/job-task/:busiId/output/:taskId/:host/:outputType' component={TaskHostOutput} />
~~~~~~~~~
node_modules/@types/react-router/index.d.ts:92:5
92 component?: React.ComponentType<RouteComponentProps<any>> | React.ComponentType<any> | undefined;
~~~~~~~~~
The expected type comes from property 'component' which is declared here on type 'IntrinsicAttributes & IntrinsicClassAttributes<Route<{}, "/job-task/:busiId/output/:taskId/:host/:outputType">> & Readonly<...>'
node_modules/@types/react-router/index.d.ts:92:5
92 component?: React.ComponentType<RouteComponentProps<any>> | React.ComponentType<any> | undefined;
~~~~~~~~~
The expected type comes from property 'component' which is declared here on type 'IntrinsicAttributes & IntrinsicClassAttributes<Route<{}, "/job-task/:busiId/output/:taskId/:host/:outputType">> & Readonly<...>'
src/components/PromGraphCpt/Table.tsx:162:12 - error TS2786: 'DatePicker' cannot be used as a JSX component.
Its instance type 'Component<PickerProps<Moment> & { status?: "" | "error" | "warning" | undefined; }, unknown, any> & CommonPickerMethods' is not a valid JSX element.
The types returned by 'render()' are incompatible between these types.
Type 'React.ReactNode' is not assignable to type 'import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").ReactNode'.
162 <DatePicker
~~~~~~~~~~
src/components/PromQueryBuilder/Operations/index.tsx:36:12 - error TS2786: 'SortableBody' cannot be used as a JSX component.
Its instance type 'Component<{ children: any; } & SortableContainerProps, any, any>' is not a valid JSX element.
The types returned by 'render()' are incompatible between these types.
Type 'React.ReactNode' is not assignable to type 'import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").ReactNode'.
36 <SortableBody
~~~~~~~~~~~~
src/components/PromQueryBuilder/Operations/Operation.tsx:84:22 - error TS2345: Argument of type 'number | null' is not assignable to parameter of type 'VisualQueryOperationParamValue'.
Type 'null' is not assignable to type 'VisualQueryOperationParamValue'.
84 onChange(val);
~~~
src/components/PromQueryBuilder/Operations/Operation.tsx:205:6 - error TS2786: 'SortableItem' cannot be used as a JSX component.
Its instance type 'Component<{ children: any; } & SortableElementProps, any, any>' is not a valid JSX element.
The types returned by 'render()' are incompatible between these types.
Type 'React.ReactNode' is not assignable to type 'import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").ReactNode'.
Type '{}' is not assignable to type 'ReactNode'.
205 <SortableItem key={operation.id} index={index}>
~~~~~~~~~~~~
src/components/PromQueryBuilder/Operations/Operation.tsx:208:12 - error TS2786: 'DragHandle' cannot be used as a JSX component.
Its instance type 'Component<{ children: any; }, any, any>' is not a valid JSX element.
The types returned by 'render()' are incompatible between these types.
Type 'React.ReactNode' is not assignable to type 'import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").ReactNode'.
208 <DragHandle>{operationDef.name}</DragHandle>
~~~~~~~~~~
src/pages/dashboard/Editor/TransformationsEditor/OrganizeFields/OrganizeFields.tsx:47:10 - error TS2786: 'SortableBody' cannot be used as a JSX component.
Its instance type 'Component<{ children: any; } & SortableContainerProps, any, any>' is not a valid JSX element.
The types returned by 'render()' are incompatible between these types.
Type 'React.ReactNode' is not assignable to type 'import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").ReactNode'.
47 <SortableBody
~~~~~~~~~~~~
src/pages/dashboard/Editor/TransformationsEditor/OrganizeFields/OrganizeFields.tsx:75:16 - error TS2786: 'SortableItem' cannot be used as a JSX component.
Its instance type 'Component<{ children: any; } & SortableElementProps, any, any>' is not a valid JSX element.
The types returned by 'render()' are incompatible between these types.
Type 'React.ReactNode' is not assignable to type 'import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").ReactNode'.
75 <SortableItem key={field} index={index}>
~~~~~~~~~~~~
src/pages/dashboard/Editor/TransformationsEditor/OrganizeFields/OrganizeFields.tsx:78:22 - error TS2786: 'DragHandle' cannot be used as a JSX component.
Its instance type 'Component<unknown, any, any>' is not a valid JSX element.
The types returned by 'render()' are incompatible between these types.
Type 'React.ReactNode' is not assignable to type 'import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").ReactNode'.
78 <DragHandle />
~~~~~~~~~~
src/pages/traceCpt/Search.tsx:326:72 - error TS2322: Type 'number | null' is not assignable to type 'number | undefined'.
Type 'null' is not assignable to type 'number | undefined'.
326 onChange={(num_traces) => setSearch({ ...search, num_traces })}
~~~~~~~~~~
src/pages/warning/shield/components/operateForm.tsx:267:26 - error TS2786: 'DatePicker' cannot be used as a JSX component.
Its instance type 'Component<PickerProps<Moment> & { status?: "" | "error" | "warning" | undefined; }, unknown, any> & CommonPickerMethods' is not a valid JSX element.
267 <DatePicker showTime onChange={timeChange} />
~~~~~~~~~~
src/pages/warning/shield/components/operateForm.tsx:283:26 - error TS2786: 'DatePicker' cannot be used as a JSX component.
Its instance type 'Component<PickerProps<Moment> & { status?: "" | "error" | "warning" | undefined; }, unknown, any> & CommonPickerMethods' is not a valid JSX element.
283 <DatePicker showTime onChange={timeChange} />
~~~~~~~~~~
src/plugins/TDengine/components/Meta/index.tsx:238:12 - error TS2786: 'Draggable' cannot be used as a JSX component.
Its instance type 'Draggable' is not a valid JSX element.
The types returned by 'render()' are incompatible between these types.
Type 'React.ReactNode' is not assignable to type 'import("F:/WebStormProject/fe-sar/node_modules/@types/react-router/node_modules/@types/react/ts5.0/index").ReactNode'.
238 <Draggable disabled={disabled} bounds={bounds} onStart={(event, uiData) => onStart(event, uiData)}>
~~~~~~~~~
Found 14 errors in 8 files.
Errors Files
2 src/App.tsx:222
1 src/components/PromGraphCpt/Table.tsx:162
1 src/components/PromQueryBuilder/Operations/index.tsx:36
3 src/components/PromQueryBuilder/Operations/Operation.tsx:84
3 src/pages/dashboard/Editor/TransformationsEditor/OrganizeFields/OrganizeFields.tsx:47
1 src/pages/traceCpt/Search.tsx:326
2 src/pages/warning/shield/components/operateForm.tsx:267
1 src/plugins/TDengine/components/Meta/index.tsx:238
error Command failed with exit code 2.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
fe能run,但无法编译