Skip to content

Errors during plugin require() are masked #242

Description

@eemeli

When a plugin throws an error when it's required, postcss-cli always prints Plugin Error: Cannot find module '${plugin}' rather than reporting the actual error.

I spent a little while today debugging because of this, as I was getting the above error due to cssnano throwing a BrowserslistError due to a bad config. That root cause would have been significantly easier to figure out if the original error had not been masked.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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