-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Errors on the console with TypeScript code fixes #1638
Labels
Milestone
Comments
I can reproduce also with the TS cc @orta |
alexdima
added
upstream
and removed
bug
Issue identified by VS Code Team member as probable bug
labels
Dec 17, 2019
Confirmed, this feels like my bug yeah 👍 |
Yeah, it's in the monaco-typescript implementation, the compiler didn't raise with /// <reference path="fourslash.ts" />
//// const test = 'foobar';
//// throw new Error(test);
//// test;
verify.codeFixAll({
fixId: "addMissingNewOperator",
fixAllDescription: "Add missing 'new' operator to all calls",
newFileContent:
`class C {
constructor(num?: number) {}
}
var a = new C();
var b = new C(3);`
}); |
alexdima
added
bug
Issue identified by VS Code Team member as probable bug
and removed
upstream
labels
Feb 17, 2020
This was referenced Sep 18, 2020
Closed
Closed
pgherveou
pushed a commit
to pgherveou/monaco-typescript
that referenced
this issue
Sep 21, 2020
…ixesAtPosition` calls
pgherveou
pushed a commit
to pgherveou/monaco-typescript
that referenced
this issue
Sep 21, 2020
* Format signature and parameter documentation as Markdown * Add support for creating a custom webworker subclass * Make a useful sample * Tidy up * Settle on customTSWorkerFactory * Adds a vfs project * Tightens the public API * update deps * update to [email protected] * Add prettier * Run prettier * Use the global `monaco` only in the AMD case (see microsoft/monaco-editor#1974) * Add deprecated diagnostic tag if a symbol is reported as deprecated * Add deprecated tag to suggestion if entry is marked as deprecated * Include tags in documentation string of suggestion items * Align tag representation in suggestion items and hovers * 4.0.0 * small style tweaks * 4.0.1 * improve `.npmignore` * Allows setting lib with shortnames * Remove declare modifiers (microsoft/monaco-editor#2121) * 4.0.2 * Update import TS * Use typescript language for hover tooltip header * update `package-lock.json` * Adopt `async` * Increase `printWidth` * `var` -> `let` * Fixes microsoft/monaco-editor#1937: Remove debugger statement * Fixes microsoft/monaco-editor#1638: Protect against failing `getCodeFixesAtPosition` calls * Fixes microsoft/monaco-editor#1998: make sure to always increase the version number * Adopt latest `monaco-editor-core`, update to TS 4.0.3 * 4.1.0 * Add missing setWorkerOptions * commit generated file * update upstream and enable regex Co-authored-by: Sebastian Pahnke <[email protected]> Co-authored-by: Orta <[email protected]> Co-authored-by: Alex Dima <[email protected]> Co-authored-by: Spencer <[email protected]>
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
monaco-editor version: > 0.18.1 (not released yet)
Browser: Chrome/Edge
OS: Windows 10
Steps or JS usage snippet reproducing the issue:
microsoft/monaco-typescript#40 added support for code fixes which is not released yet. You can play around with that however in the TypeScript playground. Using the following code I get errors on the console when moving the cursor on either side of the last semicolon:
Playground link:
http://www.typescriptlang.org/play/index.html?ts=3.7-Beta#code/MYewdgzgLgBFCm0YF4YHIBmIQCMCGATmgNwBQUAFgSAO4xjx0CiB1BAFAtAJRldTEgA
/cc @orta
The text was updated successfully, but these errors were encountered: