The build gets completed locally and the pack gets created successfully. However, once I merged the code on DevOps I got the following errors.
Error 1:
D:/a/1/s/submission/src/themes/themename/views/components/cartlineitem.component.tsx
ERROR in D:/a/1/s/submission/src/themes/themename/views/components/cartlineitem.component.tsx(635,22):
TS2786: 'Image' cannot be used as a JSX component.
Its instance type 'Image' 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("D:/a/1/s/submission/node_modules/@types/enzyme/node_modules/@types/react/index").ReactNode'.
Type '{}' is not assignable to type 'ReactNode'.
Type '{}' is missing the following properties from type 'ReactPortal': key, children, type, props
Error 2:
D:/a/1/s/submission/src/themes/themename/views/navigation-menu.view.tsx
ERROR in D:/a/1/s/submission/src/themes/themename/views/navigation-menu.view.tsx(607,18):
TS2786: 'Image' cannot be used as a JSX component.
Its instance type 'Image' is not a valid JSX element.
Errors during webpack build. See previous several lines for additional messages (written as 'stats-client-build-errors.json').
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
-- Error building application.
-- undefined
error Command failed with exit code 1.
The build gets completed locally and the pack gets created successfully. However, once I merged the code on DevOps I got the following errors.
Looking forward for any solution on the same.
Thanks, Aman