Skip to content

Pass @warn as warnings to webpack #588

@adiron

Description

@adiron

At the moment I'm working on a project with a workflow that uses sass-loader in order to compile SCSS.

There is a Sass mixin with a @warn directive in it. At the moment it outputs warnings such as this to stdout:

WARNING: Warning message
         on line 56 of src/test.scss, in function `something`

I think it could be more useful if Webpack was aware of the warning. In the same way that eslint-loader can raise warnings. e.g.:

/path/to/code/file.js
  1:20  warning  'foobar' is defined but never used  no-unused-vars

Is this something I can do right now with sass-loader in any way? I think developers using similar workflows could benefit from seeing the warnings in a more organized fashion coming out of Webpack, rather than scattered warnings straight into stdout

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions