dylang/npm-check

Npm-check 5.1 is too zealous while looking for missing modules

Open

#123 ouverte le 4 avr. 2016

Voir sur GitHub
 (12 commentaires) (7 réactions) (0 assignés)JavaScript (278 forks)batch import
help wantedissue is in a dependencywho else wants this?

Métriques du dépôt

Stars
 (6 438 stars)
Métriques de merge PR
 (Merge moyen 5h 4m) (6 PRs mergées en 30 j)

Description

Hello! First of all, thanks for your work, I love this helper as I love to keep my projects with depencies up to date!

Anyway since updating to 5.1 I noticed an annoying behaviour: npm-check is starting to look for modules everywhere, even in .eslintrc or karma.conf.js!

The worst part is that I use webpack resolve's modulesDirectories options to load my modules with absolute paths from the root of my project, so I have a lot of this calls:

import Header from 'components/header' or import * as api from 'utils/api'

Before 5.1 they were ignored, while now they are all caught making the report unreadable:

actions                             �  MISSING!  Not installed.
                                        �  PKG ERR!  Not in the package.json. Found in: \src\scripts\actio
ns\animations.js, \src\scripts\actions\blocks.js, \src\scripts\actions\currentConversation.js, \src\script
s\actions\mail.js, \src\scripts\components\Main.jsx...

and so on.

I tried also with the -s flag but it skips a lot of modules so it's not viable either.

Guide contributeur