Skip to content

@example breaks when example includes @ character (org package imports) #39371

Closed
@mesqueeb

Description

@mesqueeb

TS Template added by @mjbvz

TypeScript Version: 4.0.0-dev.20200701

Search Terms

  • jsdoc
  • example
  • code block
  • quick info

  • VSCode Version:
Version: 1.46.1
Commit: cd9ea6488829f560dc949a8b2fb789f3cdc05f5d
Date: 2020-06-17T21:17:14.222Z (1 wk ago)
Electron: 7.3.1
Chrome: 78.0.3904.130
Node.js: 12.8.1
V8: 7.8.279.23-electron.0
OS: Darwin x64 19.4.0
  • OS Version:
macOS 10.15.4 (19E2269)

Steps to Reproduce:

  1. hover over a JSDoc with an @example with an @ in the example (eg. an organisation package import)
  2. see the error:

Screenshot 2020-06-30 12 51 17

As you can see from the screenshot, the whole code @example is broken because it's written require('@google-cloud/storage') inside the example.

Does this issue occur when all extensions are disabled?: Yes

Metadata

Metadata

Assignees

Labels

BugA bug in TypeScriptFix AvailableA PR has been opened for this issueVS Code PriorityCritical issues that VS Code needs fixed in the current TypeScript milestone

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions