This repository has been archived by the owner on Jan 13, 2025. It is now read-only.
chore: Split build task into separate tasks for dist/demo #2453
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
As of #2437,
npm run build
now builds 2 sets of files at once: demo css/js, and dist css/js. These used to be split via theMDC_ENV
variable (see https://github.com/material-components/material-components-web/pull/2325/files#r176188331).The problem with this is now
npm run build
builds a lot more than it used to, and this causes ourcp-pkgs
script to fail due to the presence of files not matching the pattern it expects; this is something that we would've quickly tripped over upon next release if it weren't found now.In retrospect, Andy and I agree it's odd that we had
npm run build
building two almost completely different sets of files based on an environment variable; therefore this PR splits them out. Building the demos is only ever used for catalog deployment upon release, so I updated the command listed in our release docs accordingly.npm run build
will now proceed to act as it did before for building dist files.