Check if a package has a dependency in either devDependencies or dependencies
the name of the package to check for
Optional
optional version to check for, defaults to any version
override the working directory
Check if a package has a dependency in either devDependencies or dependencies