scss-lint
scss-lint copied to clipboard
Allow unknown property names in `:export` block
I'm using CSS Modules with SCSS (via https://gatsbyjs.org). I'm using the CSS Modules :export feature to send my SCSS variables to Javascript:
:export {
headerHeight: $header-height;
}
When I do this, I get a scss-lint error "Unknown property: 'headerHeight'".
I'd like the ability with scss-lint to use arbitrary property names within an :export block (possibly behind a rule toggle).
My current workaround is doing
:export {
#{'headerHeight'}: $header-height;
}
but it's pretty ugly just to get around the linter rule.