Open
Description
Currently vscode will auto import build-in node module without node:
prefix unless there is already another import with prefix.
Example:
No imports or one or more imports without node:
prefix:
One or more import with node:
prefix:
I would like to have a setting to force node:
prefix.
Related:
eslint-community/eslint-plugin-n#77
import-js/eslint-plugin-import#2717
Workarounds:
- Use eslint rule from
eslint-plugin-unicorn
plugin: https://github.com/sindresorhus/eslint-plugin-unicorn/blob/main/docs/rules/prefer-node-protocol.md - Use https://gist.github.com/alex-kinokon/f8f373e1a6bb01aa654d9085f2cff834 with https://www.npmjs.com/package/eslint-plugin-local-rules
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment