Hi all! Getting an error on the npm run build:types (tsc) stage of the build process. I set up the root-config project using create-single-spa. I then updated single-spa-layout to "^2.1.0" and ran npm run build.
Steps to reproduce
Create root-config project by running creat-single-spa
Select root-config
Confirm the project will use TypeScript
Confirm the project will use single-spa-layout
Delete node_modules and package-lock.json
After the project is created, update single-spa-layout to version 2.1.0
Run npm i
Run npm run build
Error
[build:*types] node_modules/single-spa-layout/dist/types/browser/constructApplications.d.ts(36,5): error TS1170: A computed property name in a type literal must refer to an expression whose type is a literal type or a 'unique symbol' type.
[build:*types] node_modules/single-spa-layout/dist/types/browser/constructApplications.d.ts(36,5): error TS2464: A computed property name must be of type 'string', 'number', 'symbol', or 'any'.
[build:*types] node_modules/single-spa-layout/dist/types/isomorphic/constructRoutes.d.ts(74,81): error TS2694: Namespace '"/Users/jason.dielman/bx/codebase/platform-ui-host/node_modules/@types/parse5/index"' has no exported member 'DefaultTreeDocument'.
[build:*types] node_modules/single-spa-layout/node_modules/single-spa/typings/single-spa.d.ts(1,1): error TS6200: Definitions of the following identifiers conflict with those in another file: CustomPropsFn, AppProps, ParcelConfig, ParcelProps, ParcelConfigObject, Parcel, LifeCycleFn, LifeCycles, StartOpts, Application, ActivityFn, Activity, RegisterApplicationConfig, SingleSpaCustomEventDetail, NOT_LOADED, LOADING_SOURCE_CODE, NOT_BOOTSTRAPPED, BOOTSTRAPPING, NOT_MOUNTED, MOUNTING, MOUNTED, UPDATING, UNMOUNTING, UNLOADING, SKIP_BECAUSE_BROKEN, LOAD_ERROR, AppError
[build:*types] node_modules/single-spa-layout/node_modules/single-spa/typings/single-spa.d.ts(3,5): error TS2374: Duplicate index signature for type 'string'.
[build:*types] node_modules/single-spa-layout/node_modules/single-spa/typings/single-spa.d.ts(4,5): error TS2374: Duplicate index signature for type 'number'.
[build:*types] node_modules/single-spa-layout/node_modules/single-spa/typings/single-spa.d.ts(98,5): error TS2374: Duplicate index signature for type 'string'.
[build:*types] node_modules/single-spa-layout/node_modules/single-spa/typings/single-spa.d.ts(105,5): error TS2717: Subsequent property declarations must have the same type. Property '[MOUNTED]' must be of type '[]', but here has type 'string[]'.
[build:*types] node_modules/single-spa-layout/node_modules/single-spa/typings/single-spa.d.ts(106,5): error TS2717: Subsequent property declarations must have the same type. Property '[NOT_MOUNTED]' must be of type '[]', but here has type 'string[]'.
[build:*types] node_modules/single-spa-layout/node_modules/single-spa/typings/single-spa.d.ts(107,5): error TS2717: Subsequent property declarations must have the same type. Property '[NOT_LOADED]' must be of type '[]', but here has type 'string[]'.
[build:*types] node_modules/single-spa-layout/node_modules/single-spa/typings/single-spa.d.ts(108,5): error TS2717: Subsequent property declarations must have the same type. Property '[SKIP_BECAUSE_BROKEN]' must be of type '[]', but here has type 'string[]'.
[build:*types] node_modules/single-spa/typings/single-spa.d.ts(1,1): error TS6200: Definitions of the following identifiers conflict with those in another file: CustomPropsFn, AppProps, ParcelConfig, ParcelProps, ParcelConfigObject, Parcel, LifeCycleFn, LifeCycles, StartOpts, Application, ActivityFn, Activity, RegisterApplicationConfig, SingleSpaCustomEventDetail, NOT_LOADED, LOADING_SOURCE_CODE, NOT_BOOTSTRAPPED, BOOTSTRAPPING, NOT_MOUNTED, MOUNTING, MOUNTED, UPDATING, UNMOUNTING, UNLOADING, SKIP_BECAUSE_BROKEN, LOAD_ERROR, AppError
[build:*types] node_modules/single-spa/typings/single-spa.d.ts(3,5): error TS2374: Duplicate index signature for type 'string'.
[build:*types] node_modules/single-spa/typings/single-spa.d.ts(4,5): error TS2374: Duplicate index signature for type 'number'.
[build:*types] node_modules/single-spa/typings/single-spa.d.ts(139,5): error TS2374: Duplicate index signature for type 'string'.
[build:*types] npm run build:types exited with code 2
Trying to dive into this a bit more, but if anyone has run into this in the meantime any help is very much appreciated 👍
Hi all! Getting an error on the
npm run build:types
(tsc) stage of the build process. I set up the root-config project usingcreate-single-spa
. I then updated single-spa-layout to"^2.1.0"
and rannpm run build
.Steps to reproduce
creat-single-spa
root-config
node_modules
andpackage-lock.json
2.1.0
npm i
npm run build
Error
Trying to dive into this a bit more, but if anyone has run into this in the meantime any help is very much appreciated 👍