Skip to content

Conversation

devinrhode2
Copy link

This is the first time I've ever touched eslint rule stuff, but I feel pretty good about this change, and was able to maintain the 100% test coverage on this rule.

closes mysticatea#318 (no-process-env: accept a custom error message)
"node/no-process-env": [
"error",
{
"customMessage": "Use the env wrapper instead."
Copy link
Author

@devinrhode2 devinrhode2 Jan 23, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I made this sample message deliberately bad to drive the point that users need to edit it for their use case.

In my case it'll be something like: "Use safeEnv from 'src/env' instead."

@voxpelli
Copy link

eslint-plugin-n is the maintained version of this module.

We switched to it in eg. eslint-config-standard / standard and it is maintained by me and other members of the official ESLint community organization.

Try that module out and if it isn't fixed there, then open a new PR in that project.

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

Labels

None yet

2 participants