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

Add .scss extensions #1098

Merged

Conversation

firec0der
Copy link
Contributor

I use node-sass-chokidar, it transforms *.scss files to *.css and keeps them near *.scss origins.
So, during the first build everything is ok, but during the next, it fails because it sees 2 files (e.g variables.scss & variables.css) and can't decide which file should be included.

Here is my output:

{
  "status": 1,
  "file": "./node_modules/react-datepicker/src/stylesheets/datepicker.scss",
  "line": 1,
  "column": 1,
  "message": "It's not clear which file to import for '@import \"variables\"'.\nCandidates:\n  variables.scss\n  variables.css\nPlease delete or rename all but one of these files.\n",
  "formatted": "Error: It's not clear which file to import for '@import \"variables\"'.\n       Candidates:\n         variables.scss\n         variables.css\n       Please delete or rename all but one of these files.\n        on line 1 of node_modules/react-datepicker/src/stylesheets/datepicker.scss\n>> @import \"variables\";\n   ^\n"
}

@firec0der
Copy link
Contributor Author

firec0der commented Oct 30, 2017

I prefer to override variables with my own, so I have separate datepicker.scss file:

@import "from/my/colors.scss";

$datepicker__selected-color: $my-color !default;

@import "react-datepicker/src/stylesheets/datepicker.scss";

@martijnrusschen martijnrusschen merged commit 8f8106d into Hacker0x01:master Oct 30, 2017
@firec0der firec0der deleted the fix/add-missed-scss-extensions branch October 30, 2017 21:37
@firec0der
Copy link
Contributor Author

Thank you!

Squar89 pushed a commit to Squar89/react-datepicker2 that referenced this pull request Apr 10, 2019
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.

2 participants