| Summary: | Cannot remove unused ClassDeclaration | ||
|---|---|---|---|
| Product: | [ECD] Orion | Reporter: | Michael Rennie <Michael_Rennie> |
| Component: | JS Tools | Assignee: | Michael Rennie <Michael_Rennie> |
| Status: | RESOLVED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P2 | ||
| Version: | 13.0 | ||
| Target Milestone: | 14.0 | ||
| Hardware: | PC | ||
| OS: | Mac OS X | ||
| Whiteboard: | |||
Typo'd that, I meant to say 'ClassDeclaration' not 'ClassExpression' |
Consider the following snippet: class FooBar { constructor() { this.doIt = function doIt() {console.log("made a class!");}; } } in the editor, FooBar will be tagged as being unused. If you try to use the quickfix, nothing happens. ClassExpressions do not automatically export into the global scope, so if it is not instantiated or exported, the fix is legit and should remove the class (if clicked)