npm-package-json-lint icon indicating copy to clipboard operation
npm-package-json-lint copied to clipboard

feat: add scope for dependency rules

Open mohanraj-r opened this issue 3 years ago • 1 comments

Instead of having the same check expressed with different names for the different scopes (prod, dev etc), it would be good to have a rule specify scope(s).

e.g.

'no-absolute-version-dependencies': ['prod', 'dev'],
'prefer-alphabetical-dependencies': ['peer', 'optional']

mohanraj-r avatar Apr 19 '22 00:04 mohanraj-r

makes great sense, but the format might be like `xx: ['error', scope?]', where scope default is all

justnewbee avatar Oct 26 '23 02:10 justnewbee