typescript-go icon indicating copy to clipboard operation
typescript-go copied to clipboard

Staging repo for development of native port of TypeScript

Results 434 typescript-go issues
Sort by recently updated
recently updated
newest added

## Steps to reproduce I don't have a repo, but I can create it if mandatory ## Behavior with `[email protected]` running `tsc --customConditions null` overrides the customConditions and sets it...

Domain: CLI

Mentioned in #1008 but creating an issue specifically about semantic highlighting ## Feature request Add semantic highlighting support for editors In VS Code, we've gotten pretty used to this feature...

Domain: Editor

This panicked while I was typing out a new test case. ``` panic handling request textDocument/completion Could not find symbol 'sourceMapsEnabled' by key 'sourceMapsEnabled' in module "/home/jabaile/.cache/typescript/7.0/node_modules/@types/graceful-fs/index" goroutine 2147 [running]:...

Domain: Editor
Crash

With vtsls in zed: But using tsgo: I'm unsure whether this is something the zed extension should be handling or not... but I'm unable to work with tsgo until this...

Domain: Editor

### Summary Prevent a slice out-of-range panic in the LSP when computing completions/auto-imports for edge-case positions or empty symbol names. The change adds minimal bounds checks and early returns around...

```ts const m = new Map([ [/*a*/'0', ['0', false]]/*b*/, ]); ``` Request completions at `/*a*/` or `/*b*/`. ``` [error] panic handling requesttextDocument/completionruntime error: index out of range [-1]goroutine 3826 [running]:...

Crash

```ts export class SomeInterface { /** ruh-roh! */ /*$1*/property: string; } export class SomeClass { /** ruh-roh! */ /*$2*/property = "value"; } ``` Request completions at the beginning of either...

Domain: JS
Crash

``` workspaces └── projectDir └── aaa.ts ``` `aaa.ts`: ```ts export function foo() {} ``` If you run the following commands through the LSP ``` {"kind":"request","method":"initialize","params":{"processId":165768,"capabilities":{"textDocument":{"completion":{"completionItem":{"snippetSupport":true,"insertReplaceSupport":true,"resolveSupport":{"properties":["documentation","detail","additionalTextEdits"]},"commitCharactersSupport":true,"deprecatedSupport":true,"preselectSupport":true,"labelDetailsSupport":true,"documentationFormat":["markdown","plaintext"],"insertTextModeSupport":{"valueSet":[1,2]}},"contextSupport":true},"definition":{"linkSupport":true},"references":{},"documentSymbol":{"hierarchicalDocumentSymbolSupport":true,"labelSupport":true},"foldingRange":{"foldingRange":{"collapsedText":true}},"codeAction":{"disabledSupport":true,"dataSupport":true,"codeActionLiteralSupport":{"codeActionKind":{"valueSet":["quickfix","refactor","refactor.extract","refactor.inline","refactor.rewrite","source","source.organizeImports"]}}},"hover":{"contentFormat":["markdown","plaintext"]},"diagnostic":{"relatedDocumentSupport":true},"declaration":{"linkSupport":true},"implementation":{"linkSupport":true},"typeDefinition":{"linkSupport":true},"rename":{}},"workspace":{"symbol":{}}},"rootUri":"file:///workspaces/projectDir/"}} {"kind":"notification","method":"initialized","params":{}} ``` and then run...

Crash

## Summary This PR adds proper mutex protection to the `projects` map in the API struct to prevent potential race conditions. ## Problem The `projects` map in `internal/api/api.go` was the...