chrisjshull / homebridge-nest

Nest plugin for HomeBridge
707 stars 111 forks source link

Move `eslint` for plugin `dependencies` to `devDependencies` #479

Closed timrogers closed 2 years ago

timrogers commented 2 years ago

This updates the plugin's dependencies so that eslint is one of the devDependencies, rather than one of the main dependencies.

This reduces the amount to install and thus the install time when installing the plugin - especially given the eslint itself has quite a lot of onward dependencies.

This should be okay, since the project does not use ESLint at runtime. As the eslint docs put it:

Make sure your plugins (and ESLint) are both in your project's package.json as devDependencies (or dependencies, if your project uses ESLint at runtime).

or in the words of Allesandro Segala:

There are some clear-cut cases, or almost. Packages like eslint are always a devDependency …unless, of course, you’re building a CLI whose job is running eslint, in which case you’d add it as a dependency!