Skip to content
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

Import of another scss is not working #52

Open
nettiopsu opened this issue Jan 10, 2019 · 5 comments
Open

Import of another scss is not working #52

nettiopsu opened this issue Jan 10, 2019 · 5 comments

Comments

@nettiopsu
Copy link

nettiopsu commented Jan 10, 2019

Hello!

I am trying to import another scss file with partials into theme.scss. It seems this is not supported?

Use case: There are multiple websites under the same brand. They share same logo, fonts and so on. However, parameters like website colors can vary from site to site, since they have different content

I would like to have a theme file with same basics: fonts, sizes, line heights and so on, which differ from standard

I want to be able to extend this theme with other colors and some other parameters.

This plugin returns me this errors for import at the moment:

Could not compile the SCSS theme file "./theme.scss" for the purpose of variable extraction. This is likely because it contains a Sass error.

Error: Invalid CSS after "...test { content:": expected expression (e.g. 1px, bold), was '@import "../src/bas'\n on line 1 of stdin\n>> .test { content: @import "../src/base-theme.scss" }

theme.scss:

@import "../src/base-theme.scss";
$primary-color: yellow;

Is there some workaround for it?

@nettiopsu
Copy link
Author

It seems that it is supported in scss-to-json library (which is used in this project) as "dependencies" parameter:
https://github.com/ryanbahniuk/scss-to-json

@vrsotto
Copy link

vrsotto commented Sep 7, 2019

@nettiopsu hi! we're you able to solve this issue? i hope you could share your solution

@mazeeblanke
Copy link

any update on this ?

@vrsotto
Copy link

vrsotto commented Oct 24, 2019

I followed this https://dailyjsx.com/antd-rescript-sass-boilerplate -- and address my problem in nadunindunil/antd-rescripts-boilerplate#1

@mrszympek
Copy link

Same problem here 🙋🏻‍♂️ Any solution?

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

No branches or pull requests

4 participants