check if package.json contains dependencies not in node_modules
问题 I'm looking for a way to check if there are packages that need to be installed that currently are not. For example, there is a package.json dependency that was not previously installed or a package.json dependency version that was not previously installed. To be clear, I'm not looking for outdated packages. If this is not possible, I would be ok with knowing whether npm install installed or removed any packages. 回答1: Try using the --dry-run flag . According to the docs man npm-install : The -