Closed ckt1031 closed 1 year ago
Prettier isn't running well currently, you can format the code before merging to the main branch.
Hi @cktsun1031 thank you for contributing. Could you talk through these proposed changes a bit more?
transformation, so you don't have to config tsc and webpack-cli
This project uses tsc and webpack. What advantages does moving to tsup bring? tsc will still be required for typechecking, so this would be a substitution of webpack for tsup, netting the same project dependencies.
E2E are not using local packages, it uses production version from npm, so the tests are redundant because of that, but now it uses local's one
This is not true. This project uses pnpm workspaces, which installs the local packages. You can read more about this here https://pnpm.io/workspaces.
The change to withRoutes from a default export to a named export is a breaking change.
Unfortunately, my machine installed the remote version instead of the local one, idk whether it's my issue or not
The main advantage is that you can use the single cli command to bundle and export two both CJS and ESM formats, it also does bundling like solving json imports and automatically dts exporting, tsup does type checking before finishing the building.
You can ignore 😓 this PR if you want to stay in webpack, tsc bundling instead of tsup.
And also fixed serval bugs:
package.json
directly, tsup bundles it for youChanges: