Skip to content

unable to read tslint, not found. #133

@kevin074

Description

@kevin074

I init a tslint via https://palantir.github.io/tslint/ quick start direction
Then installed typescript-formatter according to direction on github
Finally tried tsfmt -r to test the package, error showed:
"Error: Cannot find module 'tslint'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:581:15)
at Function.Module._load (internal/modules/cjs/loader.js:507:25)
at Module.require (internal/modules/cjs/loader.js:637:17)
at require (internal/modules/cjs/helpers.js:20:18)
at /usr/local/lib/node_modules/typescript-formatter/lib/provider/tslintjson.js:131:86"

then tried tsfmt -r --no-tslint and the compilation was completed with replacements done.

All commands done at the root directory where tsconfig.json and tslint.json also lives.
I have also tried to do the commands in the folder where the TS files lives (but not the .json files), and the same error is shown.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions