Skip to content

Conversation

@lunelson
Copy link
Contributor

This PR contains a:

  • bugfix
  • new feature
  • code refactor
  • test update
  • typo fix
  • metadata update

Motivation / Use-Case

This PR adds support for supplying the functions option as a function of the Loader Context. This corresponds to part of the issue I filed here.

Breaking Changes

None. Added a test similar to the one for the "data as function"; it passes.

@jsf-clabot
Copy link

jsf-clabot commented Dec 16, 2018

CLA assistant check
All committers have signed the CLA.

@lunelson lunelson changed the title Functions function Allow passing functions option as function Dec 16, 2018
@codecov
Copy link

codecov bot commented Dec 16, 2018

Codecov Report

Merging #651 into master will increase coverage by 0.02%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #651      +/-   ##
==========================================
+ Coverage      98%   98.02%   +0.02%     
==========================================
  Files           6        6              
  Lines         150      152       +2     
==========================================
+ Hits          147      149       +2     
  Misses          3        3
Impacted Files Coverage Δ
lib/normalizeOptions.js 96.96% <100%> (+0.19%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2d6045b...fc6c195. Read the comment docs.

Allows the `functions` option for node-sass or dart-sass to be a function, in which case it will be passed the Loader Context as argument
Adds a test for the case where the functions option is supplied as a function. Passes the Loader Context and also checks that it is available.
@lunelson
Copy link
Contributor Author

I've tried to follow all the guidelines but I don't know how to make the travis build pass here, it's failing with "Invalid revision range"

Copy link
Member

@alexander-akait alexander-akait left a comment

Choose a reason for hiding this comment

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

Strange error on CI, don't worry looks good, we will release this in next version, thanks

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.

3 participants