-
Notifications
You must be signed in to change notification settings - Fork 29
Support pure JS sass
executable
#344
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: main
Are you sure you want to change the base?
Conversation
9683817
to
2b23fac
Compare
a57567f
to
ec05f2d
Compare
ec05f2d
to
75f77ee
Compare
5d51360
to
b2dfcb2
Compare
d233142
to
dd17ebb
Compare
7334197
to
c1ad745
Compare
c1ad745
to
c5827d5
Compare
c5827d5
to
3f07e60
Compare
sass --embedded
in pure JS modesass
executable
3f07e60
to
fa0b0af
Compare
3744f85
to
76097f0
Compare
bdcf7c9
to
ffb708b
Compare
e7fa973
to
d38f850
Compare
d38f850
to
8bcb141
Compare
6e8a3c8
to
4848227
Compare
lib/src/compiler-module.ts
Outdated
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.
The reason to split this into a different module is that compiler-path
contains IIFE that may throw on load, but in tool scripts, we need to know the compiler-module name to setup dev environment without throwing. Therefore it's moved to a separate file.
c9c3970
to
8176dad
Compare
e2bae73
to
68738e7
Compare
Because this PR assumes that the dartvm and dart2js sass-compiler will behave exactly same from an external viewpoint, this PR only run test the against dartvm in the CI. The dart2js based CI test is configured in the dart-sass repo itself. Therefore, this PR has no dependency on dart-sass side of PR, and can be merged independently. - I would like to have this PR merged first, so that I don't have to keep resolving merge conflict every time the version number is bumped. Of course, if we merge this PR first before merging the dart-sass PR, the API mode won't work. However, at least it allows users to run @nex3 With the above said, it would be nice if you can take a look and merge this, even if we don't merge dart-sass PR right away. |
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'm on board to land this first.
However, at least it allows users to run npm exe sass-embedded consistently on all platforms without native dart support.
I don't completely understand this. It looks like this PR only affects local development. How will it affect what users can do at all?
Today if you run |
Code review feedbacks have been applied. |
sass/dart-sass#2413
This PR changes how compiler is setup for local development. Instead of symlink the compiler into a special vendor directory:
build/dart-sass/build
->node_modules/sass-embedded-${platform}-${arch}/dart-sass
.build/dart-sass/build/npm
->node_modules/sass
.Only one kind of compiler will be installed by
init.ts
, that the other kind will be removed if exists.In the
compiler-path.ts
, loading the compiler is attempted in the order of: