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

Separate yamm.css and _yamm.scss to different directories #72

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Separate yamm.css and _yamm.scss to different directories #72

wants to merge 1 commit into from

Conversation

jdufresne
Copy link

Move the compiled yamm.css to a dist directory.

When compiling yamm3 using webpack and sass, the following error is
received:

SassError: It's not clear which file to import for '@import ".../node_modules/@geedmo/yamm3/yamm/yamm"'.
       Candidates:
         .../node_modules/@geedmo/yamm3/yamm/_yamm.scss
         .../node_modules/@geedmo/yamm3/yamm/yamm.css
       Please delete or rename all but one of these files.
        on line 1 of .../app/javascript/stylesheets/application.scss

By moving the compiled output to a separate directory, it avoids the
ambiguity. The source files continue to live in the yamm directory. The
output now lives in the dist directory, which is commonly used by other
projects (e.g. jQuery).

Move the compiled yamm.css to a `dist` directory.

When compiling yamm3 using webpack and sass, the following error is
received:

    SassError: It's not clear which file to import for '@import ".../node_modules/@geedmo/yamm3/yamm/yamm"'.
           Candidates:
             .../node_modules/@geedmo/yamm3/yamm/_yamm.scss
             .../node_modules/@geedmo/yamm3/yamm/yamm.css
           Please delete or rename all but one of these files.
            on line 1 of .../app/javascript/stylesheets/application.scss

By moving the compiled output to a separate directory, it avoids the
ambiguity. The source files continue to live in the yamm directory. The
output now lives in the dist directory, which is commonly used by other
projects (e.g. jQuery).
@jdufresne
Copy link
Author

Another solution would be to remove the _yamm.scss file entirely. That would also remove the ambiguity. As the file contains no variables, functions, mixins or other interesting SASS features, it doesn't really offer a practical advantage over the CSS file. They are equivalent. Let me know if you would prefer I go that route instead.

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.

1 participant