libsass icon indicating copy to clipboard operation
libsass copied to clipboard

Issue with spread operator on a map as parameter for named variables

Open EikaMikiku opened this issue 5 years ago • 1 comments

This is a copy of issue over at node-sass repo. https://github.com/sass/node-sass/issues/2580

  • NPM version (6.4.1):
  • Node version (10.14.0):
  • Node Process ({ http_parser: '2.8.0', node: '10.14.0', v8: '6.8.275.32-node.36', uv: '1.23.2', zlib: '1.2.11', ares: '1.14.0', modules: '64', nghttp2: '1.34.0', napi: '3', openssl: '1.1.0j', icu: '62.1', unicode: '11.0', cldr: '33.1', tz: '2018e' }):
  • Node Platform (win32):
  • Node architecture (x64):
  • node-sass version (node-sass 4.11.0 (Wrapper) [JavaScript] libsass 3.5.4 (Sass Compiler) [C/C++]):
  • npm node-sass versions ([email protected]):

Running:

$map: ("lightness": 10%, "saturation": 10%);
$base: call(get-function('scale-color'), #dedede, $map...);
@debug $base;

Expecting:

//should spread to named parameters correctly
DEBUG: #2282ee

Output:

Error: not enough arguments for `scale-color'

Spreading a map like that into named variables used to work in the previous versions (switched from [email protected] recently). Or is there a different way to do this now?

EikaMikiku avatar Jan 14 '19 22:01 EikaMikiku

Reproduced on source map inspector

mgreter avatar Apr 12 '19 18:04 mgreter