From acf5bda56146119d4899e7cccad3bba52757ea7d Mon Sep 17 00:00:00 2001 From: Haoqun Jiang Date: Fri, 18 Feb 2022 15:08:48 +0800 Subject: [PATCH] fix(cypress-ct): avoid cypress types polluting normal source files As pointed out in https://github.com/vuejs/create-vue/pull/56#issuecomment-1040326589 --- template/tsconfig/cypress-ct/tsconfig.app.json | 12 ++++++++++++ .../tsconfig/cypress-ct/tsconfig.cypress-ct.json | 8 ++++++++ template/tsconfig/cypress-ct/tsconfig.json | 14 ++++++++++++++ 3 files changed, 34 insertions(+) create mode 100644 template/tsconfig/cypress-ct/tsconfig.app.json create mode 100644 template/tsconfig/cypress-ct/tsconfig.cypress-ct.json create mode 100644 template/tsconfig/cypress-ct/tsconfig.json diff --git a/template/tsconfig/cypress-ct/tsconfig.app.json b/template/tsconfig/cypress-ct/tsconfig.app.json new file mode 100644 index 00000000..cdbea1d7 --- /dev/null +++ b/template/tsconfig/cypress-ct/tsconfig.app.json @@ -0,0 +1,12 @@ +{ + "extends": "@vue/tsconfig/tsconfig.web.json", + "include": ["env.d.ts", "src/**/*", "src/**/*.vue"], + "exclude": ["src/**/__tests__/*"], + "compilerOptions": { + "composite": true, + "baseUrl": ".", + "paths": { + "@/*": ["./src/*"] + } + } +} diff --git a/template/tsconfig/cypress-ct/tsconfig.cypress-ct.json b/template/tsconfig/cypress-ct/tsconfig.cypress-ct.json new file mode 100644 index 00000000..dec23bc6 --- /dev/null +++ b/template/tsconfig/cypress-ct/tsconfig.cypress-ct.json @@ -0,0 +1,8 @@ +{ + "extends": "./tsconfig.app.json", + "exclude": [], + "compilerOptions": { + "composite": true, + "lib": [] + } +} diff --git a/template/tsconfig/cypress-ct/tsconfig.json b/template/tsconfig/cypress-ct/tsconfig.json new file mode 100644 index 00000000..50fe5cdd --- /dev/null +++ b/template/tsconfig/cypress-ct/tsconfig.json @@ -0,0 +1,14 @@ +{ + "files": [], + "references": [ + { + "path": "./tsconfig.vite-config.json" + }, + { + "path": "./tsconfig.app.json" + }, + { + "path": "./tsconfig.cypress-ct.json" + } + ] +}