Exclude test files from build

This commit is contained in:
Franck Royer 2021-05-11 11:33:20 +10:00
parent 0e9f2c2ecc
commit 0974f313fd
No known key found for this signature in database
GPG Key ID: A82ED75A8DFC50A4
5 changed files with 11 additions and 3 deletions

View File

@ -1,7 +1,7 @@
{
"root": true,
"parser": "@typescript-eslint/parser",
"parserOptions": { "project": "./tsconfig.json" },
"parserOptions": { "project": "./tsconfig.dev.json" },
"env": { "es6": true },
"ignorePatterns": ["node_modules", "build", "coverage", "proto"],
"plugins": ["import", "eslint-comments", "functional"],

View File

@ -16,6 +16,7 @@
"build": "run-s build:*",
"build:main": "tsc -p tsconfig.json",
"build:module": "tsc -p tsconfig.module.json",
"build:dev": "tsc -p tsconfig.dev.json",
"fix": "run-s fix:*",
"fix:prettier": "prettier \"src/**/*.ts\" \"./*.json\" --write",
"fix:lint": "eslint src --ext .ts --fix",

7
tsconfig.dev.json Normal file
View File

@ -0,0 +1,7 @@
{
"extends": "./tsconfig",
"compilerOptions": {
"noEmit": true
},
"exclude": ["node_modules/**"]
}

View File

@ -46,7 +46,7 @@
"typeRoots": ["node_modules/@types", "src/types"]
},
"include": ["src/**/*.ts"],
"exclude": ["node_modules/**"],
"exclude": ["node_modules/**", "src/**/*.spec.ts", "src/test_utils"],
"compileOnSave": false,
"ts-node": {
"files": true

View File

@ -5,5 +5,5 @@
"outDir": "build/module",
"module": "esnext"
},
"exclude": ["node_modules/**"]
"exclude": ["node_modules/**", "src/**/*.spec.ts", "src/test_utils"]
}