@krutoo/presets
v0.0.1
Published
Configs and other presets
Readme
Presets
Set of presets for format/lint/test/build etc.
Install
npm add -D @krutoo/presetsUsage
ESLint
// eslint.config.{js,ts}
import preset from '@krutoo/presets/eslint';
export default [
...preset,
// ...optionally your overrides and other configs
];Prettier
When using JS/TS:
// prettier.config.{js,ts}
export { default } from '@krutoo/presets/prettier';When using JSON:
// .prettierrc.json
"@krutoo/presets/prettier"TypeScript
For static analysis in your editor/IDE and for tsc -p . --noEmit:
// tsconfig.json
{
"extends": "@krutoo/presets/tsconfig.check.json",
}This preset will check all files in your project root, where tsconfig.json placed.
For build your package via tsc -p tsconfig.build.json:
// tsconfig.build.json
{
"extends": "@krutoo/presets/tsconfig.build.json",
}This preset will try to build from src folder to dist folder.
To Do
binto use likenpx presets --init --allfor automatically create config files
