Bug: n/no-restricted-require
does not work for relative imports (as opposed to no-restricted-modules
from ESLint)
#151
Labels
Environment
Node version: 18.18.0
npm version: 9.4.2
ESLint version: 8.52.0
eslint-plugin-n version: 16.4.0
Operating System: macOS 14
What rule do you want to report?
n/no-restricted-require
Link to Minimal Reproducible Example
https://stackblitz.com/edit/stackblitz-starters-veyq3i?file=.eslintrc.yml
What did you expect to happen?
Run
npm run lint
, expected to see an error because the glob "**/" pattern at the beginning should match the "../" in the require statementParticipation
Additional comments
It looks like the issue is with Minimatch. I suggest switching to another glob matcher
The text was updated successfully, but these errors were encountered: