Skip to content

Commit

Permalink
(chore) bump ts (#1158)
Browse files Browse the repository at this point in the history
  • Loading branch information
dummdidumm committed Sep 12, 2021
1 parent 692cb61 commit 2f56361
Show file tree
Hide file tree
Showing 9 changed files with 23 additions and 21 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"lint": "prettier --check . && eslint \"packages/**/*.{ts,js}\""
},
"dependencies": {
"typescript": "^4.3.2"
"typescript": "^4.4.3"
},
"devDependencies": {
"@sveltejs/eslint-config": "github:sveltejs/eslint-config#v5.2.0",
Expand Down
8 changes: 4 additions & 4 deletions packages/language-server/src/plugins/svelte/SvelteDocument.ts
Original file line number Diff line number Diff line change
Expand Up @@ -410,7 +410,7 @@ function wrapPreprocessors(preprocessors: PreprocessorGroup | PreprocessorGroup[
wrappedPreprocessor.script = async (args: any) => {
try {
return await preprocessor.script!(args);
} catch (e) {
} catch (e: any) {
e.__source = TranspileErrorSource.Script;
throw e;
}
Expand All @@ -421,7 +421,7 @@ function wrapPreprocessors(preprocessors: PreprocessorGroup | PreprocessorGroup[
wrappedPreprocessor.style = async (args: any) => {
try {
return await preprocessor.style!(args);
} catch (e) {
} catch (e: any) {
e.__source = TranspileErrorSource.Style;
throw e;
}
Expand Down Expand Up @@ -451,7 +451,7 @@ async function transpile(
processedScripts.push(res);
}
return res;
} catch (e) {
} catch (e: any) {
e.__source = TranspileErrorSource.Script;
throw e;
}
Expand All @@ -466,7 +466,7 @@ async function transpile(
processedStyles.push(res);
}
return res;
} catch (e) {
} catch (e: any) {
e.__source = TranspileErrorSource.Style;
throw e;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ function preprocessSvelteFile(document: Document, options: SvelteSnapshotOptions
nrPrependedLines = 1;
}
}
} catch (e) {
} catch (e: any) {
// Error start/end logic is different and has different offsets for line, so we need to convert that
const start: Position = {
line: e.start?.line - 1 ?? 0,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ describe('CompletionProviderImpl', () => {
label: 'b',
insertText: undefined,
kind: CompletionItemKind.Method,
sortText: '1',
sortText: '11',
commitCharacters: ['.', ',', '('],
preselect: undefined,
textEdit: undefined
Expand All @@ -101,7 +101,7 @@ describe('CompletionProviderImpl', () => {
label: 'b',
insertText: undefined,
kind: CompletionItemKind.Field,
sortText: '1',
sortText: '11',
commitCharacters: ['.', ',', '('],
preselect: undefined,
textEdit: undefined
Expand Down Expand Up @@ -406,7 +406,7 @@ describe('CompletionProviderImpl', () => {
line: 0
},
replacementSpan: undefined,
sortText: '1',
sortText: '11',
source: undefined,
sourceDisplay: undefined,
uri: fileNameToAbsoluteUri(filename)
Expand Down Expand Up @@ -1035,7 +1035,7 @@ describe('CompletionProviderImpl', () => {
label: 'blubb',
insertText: 'import { blubb } from "../definitions";',
kind: CompletionItemKind.Function,
sortText: '1',
sortText: '11',
commitCharacters: ['.', ',', '('],
preselect: undefined,
textEdit: {
Expand Down Expand Up @@ -1091,7 +1091,7 @@ describe('CompletionProviderImpl', () => {
label: 'toString',
insertText: '?.toString',
kind: CompletionItemKind.Method,
sortText: '1',
sortText: '11',
commitCharacters: ['.', ',', '('],
preselect: undefined,
textEdit: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -322,7 +322,7 @@ describe('DiagnosticsProvider', () => {
code: 2345,
message:
"Argument of type 'HTMLDivElement' is not assignable to parameter of type 'SVGElement & { getTotalLength(): number; }'.\n " +
"Type 'HTMLDivElement' is missing the following properties from type 'SVGElement': ownerSVGElement, viewportElement, correspondingElement, correspondingUseElement",
"Type 'HTMLDivElement' is missing the following properties from type 'SVGElement': ownerSVGElement, viewportElement",
range: {
end: {
character: 19,
Expand All @@ -341,7 +341,7 @@ describe('DiagnosticsProvider', () => {
code: 2345,
message:
"Argument of type 'HTMLParagraphElement' is not assignable to parameter of type 'HTMLInputElement'.\n " +
"Type 'HTMLParagraphElement' is missing the following properties from type 'HTMLInputElement': accept, alt, autocomplete, checked, and 48 more.",
"Type 'HTMLParagraphElement' is missing the following properties from type 'HTMLInputElement': accept, alt, autocomplete, capture, and 51 more.",
range: {
end: {
character: 12,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
<script>
const asd = 1;
asd.bla;
function a() {
return null;
}
a().b;
</script>
2 changes: 1 addition & 1 deletion packages/svelte-check/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ async function getDiagnostics(
result.hintCount
);
return result;
} catch (err) {
} catch (err: any) {
writer.failure(err);
return null;
}
Expand Down
2 changes: 1 addition & 1 deletion packages/svelte2tsx/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
"svelte": "~3.38.2",
"tiny-glob": "^0.2.6",
"tslib": "^1.10.0",
"typescript": "^4.3.2"
"typescript": "^4.4.3"
},
"peerDependencies": {
"svelte": "^3.24",
Expand Down
8 changes: 4 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2593,10 +2593,10 @@ type-fest@^0.8.1:
resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.8.1.tgz#09e249ebde851d3b1e48d27c105444667f17b83d"
integrity sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==

typescript@*, typescript@^4.3.2:
version "4.3.2"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.3.2.tgz#399ab18aac45802d6f2498de5054fcbbe716a805"
integrity sha512-zZ4hShnmnoVnAHpVHWpTcxdv7dWP60S2FsydQLV8V5PbS3FifjWFFRiHSWpDJahly88PRyV5teTSLoq4eG7mKw==
typescript@*,typescript@^4.4.3:
version "4.4.3"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.4.3.tgz#bdc5407caa2b109efd4f82fe130656f977a29324"
integrity sha512-4xfscpisVgqqDfPaJo5vkd+Qd/ItkoagnHpufr+i2QCHBsNYp+G7UAoyFl8aPtx879u38wPV65rZ8qbGZijalA==

unist-util-stringify-position@^2.0.0:
version "2.0.3"
Expand Down

0 comments on commit 2f56361

Please sign in to comment.