-
-
Notifications
You must be signed in to change notification settings - Fork 32.6k
[infra] WIP - use .mjs extension instead of nested package.json #46500
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
Netlify deploy previewhttps://deploy-preview-46500--material-ui.netlify.app/ Bundle size report
|
24185d9
to
1d174b6
Compare
packages/mui-types/package.json
Outdated
"build:stable": "node ../../scripts/build.mjs stable", | ||
"build:types": "tsx ../../scripts/buildTypes.mts", | ||
"build:copy-files": "node ../../scripts/copyFiles.mjs", | ||
"build:stable": "MUI_EXPERIMENTAL_MJS=true node ../../scripts/build.mjs stable", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was thinking we could just set this in CI globally? Then test with the pkg-pr-new packages on that parcel project
Signed-off-by: Jan Potoms <[email protected]>
This reverts commit 81bcffd.
@@ -239,14 +239,6 @@ jobs: | |||
pnpm --filter @mui/material typescript:module-augmentation | |||
pnpm --filter @mui/joy typescript:module-augmentation | |||
pnpm --filter @mui/system typescript:module-augmentation | |||
- run: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Getting rid of this. It does exactly nothing as far as I can see. Have enquired about this before and never received any comment on this doing something useful.
"packageExtensions": { | ||
"@pigment-css/react": { | ||
"peerDependencies": { | ||
"@mui/types": "7" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing peer dependency in pigment
@@ -3,7 +3,7 @@ | |||
// Actual .ts source files are transpiled via babel | |||
"extends": "./tsconfig.json", | |||
"compilerOptions": { | |||
"composite": true, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does removing this do ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Makes it a standalone project, without project references. We're not building with tsc --buid
so project references don't do much for us. We're running our own builds in order. We can't use tsc --build
because that doesn't support being run in parallel on projects that share project references. The only way we could potentially use it is to generate all type declarations at once with a single tsc
command for the whole repo. Or with parallellism set to 1 for the build. At which point we may as well just build in topological order, which we already do. In essence we don't need project references because with lerna we're already doing what project references do, without all the limitations they set.
We're building types in topological order, so we can rely on types of dependencies existing. We can remove the
paths
andreferences
from these files and make those builds self-contained. This is necessary to be able to rewrite generated .d.ts files to .d.mts. Otherwise typescript tries to find source files for those .d.mts files and those don't exist (it looks for .mts source files).