Runs Prettier as a TSLint rule and reports differences as individual TSLint issues.
# using npmnpm install --save-dev tslint-plugin-prettier prettier# using yarnyarn add --dev tslint-plugin-prettier prettier
NOTE: To use this plugin, it'd better to also use tslint-config-prettier to disable all prettier-related rules, so as to avoid conflicts between existed rules.
If there is no option provided, it'll try to load config file and/or
.editorconfigif possible, uses Prettier's default option if not found.
If you don't want to load
.editorconfig, disable it in the third argument.
If you'd like to specify which config file to use, just put its path (relative to
process.cwd()) in the second argument, the following example shows how to load the config file from
If you'd like to specify options manually, just put Prettier Options in the second argument, for example:
It will respect your .prettierignore file in your project root ( process.cwd() ) but if you would like to use a different file you can provide it in the third argument, for example:
# lintyarn run lint# buildyarn run build# testyarn run test
MIT © Ika