|
| 1 | +# typescript-deno-plugin |
| 2 | + |
| 3 | +> Deno language service plugin for TypeScript. |
| 4 | +
|
| 5 | +## Editor Support |
| 6 | + |
| 7 | +This plugin requires TypeScript 2.3 or later. It can provide intellisense in TypeScript files within any editors that uses TypeScript to power their language features. |
| 8 | + |
| 9 | +### With VS Code |
| 10 | + |
| 11 | +The simplest way to use this plugin is to install the [TypeScript Deno Plugin VS Code extension](). This extension enables the plugin when using VS Code's version of TypeScript. |
| 12 | + |
| 13 | +If you are using a workspace version of TypeScript, you must manually install the plugin alongside the version of TypeScript in your workspace. |
| 14 | + |
| 15 | +**use npm**: |
| 16 | + |
| 17 | +```bash |
| 18 | +npm install --save-dev typescript-deno-plugin typescript |
| 19 | +``` |
| 20 | + |
| 21 | +or **use yarn**: |
| 22 | + |
| 23 | +```bash |
| 24 | +yarn add -D typescript-deno-plugin typescript |
| 25 | +``` |
| 26 | + |
| 27 | +Then add a `plugins` section to your [tsconfig.json](http://www.typescriptlang.org/docs/handbook/tsconfig-json.html). |
| 28 | + |
| 29 | +```json |
| 30 | +{ |
| 31 | + "compilerOptions": { |
| 32 | + "plugins": [ |
| 33 | + { |
| 34 | + "name": "typescript-deno-plugin" |
| 35 | + } |
| 36 | + ] |
| 37 | + } |
| 38 | +} |
| 39 | +``` |
| 40 | + |
| 41 | +Finally, run the `Select TypeScript version` command in VS Code to switch to use the workspace version of TypeScript for VS Code's JavaScript and TypeScript language support. You can find more information about managing typescript versions [in the VS Code documentation](https://code.visualstudio.com/Docs/languages/typescript#_using-newer-typescript-versions). |
| 42 | + |
| 43 | +### With Visual Studio |
| 44 | + |
| 45 | +This plugin works Visual Studio 2017 using the TypeScript 2.3+ SDK. |
| 46 | + |
| 47 | +First install the plugin in your project. |
| 48 | + |
| 49 | +**use npm**: |
| 50 | + |
| 51 | +```bash |
| 52 | +npm install --save-dev typescript-deno-plugin typescript |
| 53 | +``` |
| 54 | + |
| 55 | +or **use yarn**: |
| 56 | + |
| 57 | +```bash |
| 58 | +yarn add -D typescript-deno-plugin typescript |
| 59 | +``` |
| 60 | + |
| 61 | +Then add a plugins section to your [tsconfig.json](http://www.typescriptlang.org/docs/handbook/tsconfig-json.html). |
| 62 | + |
| 63 | +```json |
| 64 | +{ |
| 65 | + "compilerOptions": { |
| 66 | + "plugins": [ |
| 67 | + { |
| 68 | + "name": "typescript-deno-plugin" |
| 69 | + } |
| 70 | + ] |
| 71 | + } |
| 72 | +} |
| 73 | +``` |
| 74 | + |
| 75 | +Then reload your project to make sure the plugin has been loaded properly. |
| 76 | + |
| 77 | +### With Atom |
| 78 | + |
| 79 | +This plugin works with the [Atom TypeScript plugin](https://atom.io/packages/atom-typescript). |
| 80 | + |
| 81 | +First install the plugin and a copy of TypeScript in your workspace. |
| 82 | + |
| 83 | +**use npm**: |
| 84 | + |
| 85 | +```bash |
| 86 | +npm install --save-dev typescript-deno-plugin typescript |
| 87 | +``` |
| 88 | + |
| 89 | +or **use yarn**: |
| 90 | + |
| 91 | +```bash |
| 92 | +yarn add -D typescript-deno-plugin typescript |
| 93 | +``` |
| 94 | + |
| 95 | +Then add a plugins section to your [tsconfig.json](http://www.typescriptlang.org/docs/handbook/tsconfig-json.html). |
| 96 | + |
| 97 | +```json |
| 98 | +{ |
| 99 | + "compilerOptions": { |
| 100 | + "plugins": [ |
| 101 | + { |
| 102 | + "name": "typescript-deno-plugin" |
| 103 | + } |
| 104 | + ] |
| 105 | + } |
| 106 | +} |
| 107 | +``` |
| 108 | + |
| 109 | +Then restart Atom. |
| 110 | + |
| 111 | +### Credits |
| 112 | + |
| 113 | +- [justjavac](https://github.com/justjavac) |
| 114 | + |
| 115 | +### License |
| 116 | + |
| 117 | +typescript-deno-plugin is released under the MIT License. See the bundled [LICENSE](./LICENSE) file for details. |
0 commit comments