Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • C create-react-app
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 1,547
    • Issues 1,547
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 417
    • Merge requests 417
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Meta
  • create-react-app
  • Merge requests
  • !9629

Allow specifying Dart Sass implementation

  • Review changes

  • Download
  • Email patches
  • Plain diff
Open Administrator requested to merge github/fork/christopher-francisco/dart-sass into main Sep 11, 2020
  • Overview 6
  • Commits 2
  • Pipelines 0
  • Changes 2

Created by: christopher-francisco

Description

For cases where you're not able to completely remove node-sass, causing sass-loader to pick it up, you can now explicitly specify you want to use Dart Sass through USE_DART_SASS=true env variable. See #9628 for the complete use case

Testing strategy

Manually tested it by doing the following

  1. Created a new app with yarn create-react-app my-app
  2. Added a few sass files with @use directive (only supported by Dart Sass)
  3. Added sass dependnecy
  4. Ran yarn start. Comiplation succeeded
  5. Added node-sass dependency (we now have both)
  6. Ran yarn start. Compilation failed
  7. Ran USE_DART_SASS=true yarn start. Comiplation succeeded

Screenshot

Screen Shot 2020-09-11 at 11 57 56 AM

You can see both sass and node-sass installed at the bottom right corner. App started with USE_DART_SASS=true yarn start

What's Missing?

  • Find a way to automate a test similar to the one described above
  • Updating documentation

Closes #9629

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: github/fork/christopher-francisco/dart-sass