-
Notifications
You must be signed in to change notification settings - Fork 104
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: show that imports aren't working well
Sadly, we can't do imports without TS screaming bloody murder in Vim: An import path cannot end with a '.d.ts' extension etc Related: microsoft/TypeScript#27481 We can suppress the error, but either way, the editor can't see the types, sadly obviating one of the big upsides of using TypeScript.
- Loading branch information
Showing
3 changed files
with
11 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,8 @@ | ||
// This is only for the benefit of the LanguageClient. | ||
// @ts-ignore | ||
import type Deno from '../vendor/deno/types.d.ts'; | ||
|
||
console.log(Deno.args); | ||
// @ts-ignore | ||
import test from './other.ts'; | ||
|
||
test(Deno.args); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
export default function(args: Array<string>) { | ||
console.log(...args); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"include": ["src/**/*.ts", "vendor/deno/types.d.ts"] | ||
} |