-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: Cleanup duplication across tsconfig files in packages #30764
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,7 @@ | ||
{ | ||
"extends": "../ts/tsconfig.json", | ||
"compilerOptions": { | ||
"target": "es2015", | ||
"module": "commonjs", | ||
"allowJs": true, | ||
"allowSyntheticDefaultImports": true, | ||
"esModuleInterop": true, | ||
"noImplicitAny": false, | ||
"importHelpers": true, | ||
"strict": false | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,55 +1,12 @@ | ||
{ | ||
"extends": "../ts/tsconfig.json", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. newly extended |
||
"compilerOptions": { | ||
/* Basic Options */ | ||
"target": "ES2018", | ||
"module": "esnext", | ||
"lib": ["dom", "ESNext"], | ||
/* | ||
* Allow javascript files to be compiled. | ||
* Override this in modules that need JS | ||
*/ | ||
"noEmit": true, | ||
"jsx": "preserve", | ||
"preserveWatchOutput": true, | ||
// "checkJs": true, /* Report errors in .js files. */ | ||
// "jsx": "preserve", /* Specify JSX code generation: 'preserve', 'react-native', or 'react'. */ | ||
/* Generates corresponding '.d.ts' file. */ | ||
// "declaration": true, | ||
// "declarationMap": true, /* Generates a sourcemap for each corresponding '.d.ts' file. */ | ||
/* Generates corresponding '.map' file. */ | ||
"sourceMap": true, | ||
/* Import emit helpers from 'tslib'. */ | ||
"importHelpers": true, | ||
"strictNullChecks": true, | ||
// "downlevelIteration": true, /* Provide full support for iterables in 'for-of', spread, and destructuring when targeting 'ES5' or 'ES3'. */ | ||
// "isolatedModules": true, /* Transpile each file as a separate module (similar to 'ts.transpileModule'). */ | ||
/* Strict Type-Checking Options */ | ||
// "traceResolution": true, | ||
"strict": true, | ||
"noImplicitAny": false, | ||
"noImplicitThis": false, | ||
"forceConsistentCasingInFileNames": true, | ||
/** | ||
* Skip type checking of all declaration files (*.d.ts). | ||
* TODO: Look into changing this in the future | ||
*/ | ||
/* Additional Checks */ | ||
"skipLibCheck": true, | ||
/* Report errors on unused locals. */ | ||
// "noEmit": true, | ||
"noUnusedLocals": false, | ||
// "noUnusedParameters": true, /* Report errors on unused parameters. */ | ||
/* Report error when not all code paths in function return a value. */ | ||
"noImplicitReturns": true, | ||
// "noFallthroughCasesInSwitch": true, /* Report errors for fallthrough cases in switch statement. */ | ||
/* Module Resolution Options */ | ||
"moduleResolution": "node", /* Specify module resolution strategy: 'node' (Node.js) or 'classic' (TypeScript pre-1.6). */ | ||
// "baseUrl": "./", /* Base directory to resolve non-absolute module names. */ | ||
// "paths": {}, /* A series of entries which re-map imports to lookup locations relative to the 'baseUrl'. */ | ||
// "rootDirs": ["../driver/src"], /* List of root folders whose combined content represents the structure of the project at runtime. */ | ||
// "typeRoots": [] /* List of folders to include type definitions from. */ | ||
|
||
/* Type declaration files to be included in compilation. */ | ||
"noErrorTruncation": true, | ||
"paths": { | ||
"@cy/i18n": ["../frontend-shared/src/locales/i18n"], | ||
"@cy/components/*": ["../frontend-shared/src/components/*"] | ||
|
@@ -63,17 +20,5 @@ | |
"cypress-real-events", | ||
"cypress" | ||
], | ||
"allowSyntheticDefaultImports": true, | ||
"esModuleInterop": true, | ||
"noErrorTruncation": true, | ||
"experimentalDecorators": true, | ||
"resolveJsonModule": true, | ||
"ignoreDeprecations": "5.0", | ||
/* | ||
* TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior | ||
* as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. | ||
*/ | ||
"importsNotUsedAsValues": "error", | ||
"useUnknownInCatchVariables": false | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,8 @@ | ||
{ | ||
"extends": "../ts/tsconfig.json", | ||
"compilerOptions": { | ||
"strict": true, | ||
"allowJs": false, | ||
"noImplicitAny": true, | ||
"noUnusedLocals": false, | ||
"resolveJsonModule": true, | ||
"experimentalDecorators": true, | ||
"noUncheckedIndexedAccess": true, | ||
"ignoreDeprecations": "5.0", | ||
/* | ||
* TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior | ||
* as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. | ||
*/ | ||
"importsNotUsedAsValues": "error", | ||
"outDir": "dist", | ||
"declaration": true | ||
}, | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,6 @@ | |
"./index.ts" | ||
], | ||
"compilerOptions": { | ||
"skipLibCheck": true | ||
}, | ||
"files": [ | ||
"./../ts/index.d.ts" | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,15 @@ | ||
import type playwright from 'playwright-webkit' | ||
import { domainMatch } from 'tough-cookie' | ||
|
||
// @ts-ignore | ||
export type CyCookie = Pick<chrome.cookies.Cookie, 'name' | 'value' | 'expirationDate' | 'hostOnly' | 'domain' | 'path' | 'secure' | 'httpOnly'> & { | ||
// use `undefined` instead of `unspecified` | ||
sameSite?: 'no_restriction' | 'lax' | 'strict' | ||
} | ||
|
||
// Cypress uses the webextension-style filtering | ||
// https://developer.chrome.com/extensions/cookies#method-getAll | ||
// @ts-ignore | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I can't quite understand why these server checks weren't failing before. Here ts cannot find 'chrome' |
||
export type CyCookieFilter = chrome.cookies.GetAllDetails | ||
|
||
export const cookieMatches = (cookie: CyCookie | playwright.Cookie, filter: CyCookieFilter) => { | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -125,6 +125,7 @@ export = { | |
show: true, | ||
frame: true, | ||
transparent: false, | ||
// @ts-ignore | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. cannot find getPathToIcon - I think there's something strange with the icons package export/import, but don't think this should be a part of this PR |
||
icon: image.createFromPath(cyIcons.getPathToIcon('icon_64x64.png')), | ||
}, | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
newly extended