Skip to content

Conversation

@alastair
Copy link
Member

@alastair alastair commented Mar 17, 2025

Upgrade from parcel 1 to parcel 2

Parcel 2 includes a new version of sass, which has some deprecated functions, use

npx sass-migrator module --built-in-only --migrate-deps freesound/static/bw-frontend/styles/index.scss

to upgrade this syntax.

We had "node": "^11.11.0", set in our requirements file, which seemed to cause node to run in an "backwards compatible" version which we didn't want. This was causing all sorts of errors during install and runing.

Parcel 2 can't just copy files that aren't entrypoints, so we can't use our current build file which uses parcel to just copy some static files. Either look at a plugin like https://github.com/elwin013/parcel-reporter-static-files-copy or see if we can use django collectstatic to do this.

We have some outstanding issues with the specific version of bootstrap we're using, specifically our use of the make-container-max-widths() and make-grid-columns() mixins, which have been removed in newer versions. Need to work out what's going on here.

Many deprecation warnings still that should be fixed, for example run

npx parcel build --no-optimize freesound/static/bw-frontend/src/index.js

to see them

DEPRECATION WARNING [color-functions]: darken() is deprecated. Suggestions:
DEPRECATION WARNING [mixed-decls]: Sass's behavior for declarations that appear after nested
DEPRECATION WARNING [slash-div]: Using / for division outside of calc() is deprecated and will be removed in Dart Sass 2.0.0.
DEPRECATION WARNING [global-builtin]: Global built-in functions are deprecated and will be removed in Dart Sass 3.0.0.
DEPRECATION WARNING [import]: Sass @import rules are deprecated and will be removed in Dart Sass 3.0.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants