jeffijoe / typesync

Install missing TypeScript typings for dependencies in your package.json.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add typesync rc file support

septs opened this issue · comments

commented

Configure ignore dependencies, ignore packages, etc via typesync rc file.

sample file path:

project directory/.typesync-rc.json
project directory/[any first-level subdirectory]/.typesync-rc.json

sample file format:

{
  "ignoreDependencies": ["peer"],
  "ignorePackages": ["express"]
}

What is the difference between "dependencies" and "packages"? I find them ambiguous.

commented

ignoreDependencies is to keep this feature

typesync/README.md

Lines 40 to 48 in 23f8a5c

## `--ignoredeps`
To ignore certain sections, you can use the `--ignoredeps=` flag. For example, to ignore `devDependencies`, use `--ignoredeps=dev`. To ignore multiple, comma-separate them, like this: `--ignoredeps=deps,peer` (ignores `dependencies` and `peerDependencies`).
* `--ignoredeps=deps` — ignores `dependencies`
* `--ignoredeps=dev` — ignores `devDependencies`
* `--ignoredeps=peer` — ignores `peerDependencies`
* `--ignoredeps=optional` — ignores `optionalDependencies`

commented

ignorePackages is ignore specific single package,
e.q: #46 the case

Ah gotcha!

commented

I don't know where the entry settings for loading configuration file should be
If you can tell me, I can submit a pull request

Could use cosmoconfig and put it behind a configuration service so it can be faked for testing.