Skip to content

Commit 6e28106

Browse files
committed
chore: stricter tsconfig
1 parent b7656c3 commit 6e28106

File tree

2 files changed

+16
-11
lines changed

2 files changed

+16
-11
lines changed

src/giget.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -52,10 +52,10 @@ export async function downloadTemplate(
5252
options.provider || (registry ? "registry" : "github");
5353

5454
let source: string = input;
55-
const sourceProvierMatch = input.match(sourceProtoRe);
56-
if (sourceProvierMatch) {
57-
providerName = sourceProvierMatch[1];
58-
source = input.slice(sourceProvierMatch[0].length);
55+
const sourceProviderMatch = input.match(sourceProtoRe);
56+
if (sourceProviderMatch) {
57+
providerName = sourceProviderMatch[1]!;
58+
source = input.slice(sourceProviderMatch[0].length);
5959
if (providerName === "http" || providerName === "https") {
6060
source = input;
6161
}

tsconfig.json

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,18 @@
11
{
22
"compilerOptions": {
33
"target": "ESNext",
4-
"module": "ESNext",
5-
"moduleResolution": "Node",
4+
"module": "preserve",
5+
"moduleDetection": "force",
66
"esModuleInterop": true,
7+
"allowSyntheticDefaultImports": true,
8+
"allowJs": true,
79
"resolveJsonModule": true,
8-
"strict": true
9-
},
10-
"include": [
11-
"src"
12-
]
10+
"strict": true,
11+
"isolatedModules": true,
12+
"verbatimModuleSyntax": true,
13+
"noUncheckedIndexedAccess": true,
14+
"forceConsistentCasingInFileNames": true,
15+
"noImplicitOverride": true,
16+
"noEmit": true
17+
}
1318
}

0 commit comments

Comments
 (0)