Skip to content
This repository was archived by the owner on Aug 10, 2026. It is now read-only.

Make Sass implementation agnostic ( supporting dart-sass ) - #17

Open
fsubal wants to merge 4 commits into
fetch:masterfrom
fsubal:feature/sass-implementation-agnostic
Open

Make Sass implementation agnostic ( supporting dart-sass )#17
fsubal wants to merge 4 commits into
fetch:masterfrom
fsubal:feature/sass-implementation-agnostic

Conversation

@fsubal

@fsubal fsubal commented Oct 8, 2018

Copy link
Copy Markdown

Resolves: #16


I made this library to be sass-implementation agnostic, that means, add support for dart-sass.

With these changes, node-sass-asset-functions now accepts implementation option ( which excepts require('node-sass') or require('sass'), and when absent it will be implicitly node-sass )


For some reason the test is not passing ( Maybe dart-sass cannot read file correctly, even though the path looks correct ), which is now I'm searching why... Help wanted by someone.

Comment thread __tests__/test.js
})
})
})
describe.each(['node-sass', 'sass'])('with require("%s")', function(impl) {

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Currently installed version of jest did not support describe.each, so I updated jest

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just for the record, the test failure was not due to the jest version ( it also failed with jest@16.0.2 with ['node-sass', 'sass'].forEach instead of describe.each )

@marlonmarcello

Copy link
Copy Markdown

Love this, can we get it merged @koenpunt ?

@koenpunt koenpunt left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see I still have a pending review comment here.

Comment thread __tests__/test.js
options = options || {}
options.images_path = __dirname + '/images'
options.fonts_path = __dirname + '/fonts'
options.implemantation = sass

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
options.implemantation = sass
options.implementation = sass

@ghost

ghost commented Feb 29, 2024

Copy link
Copy Markdown

hey folks, can this PR get merged in? would be super helpful since node-sass is basically decrepit at this point

@ghost

ghost commented Feb 29, 2024

Copy link
Copy Markdown

for those who want to install this now

npm i --save-dev fetch/node-sass-asset-functions#pull/17/head
"devDependencies": {
  "node-sass-asset-functions": "github:fetch/node-sass-asset-functions#pull/17/head",
}

@koenpunt

koenpunt commented Feb 29, 2024

Copy link
Copy Markdown
Contributor

I've released a new version to npm that replaces node-sass with sass (Dart Sass). Development will continue in this fork: https://github.com/koenpunt/node-sass-asset-functions

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Supporting option for dart-sass ? ( or drop node-sass as dependency )

3 participants