google / google/closure-compiler
Allow to write typedef without variable
- Dominant language
- JavaScript
- Stars
- 7.7k
- Forks
- 1.2k
- Avg merge
- 2d 12h
- Merged PRs (30d)
- 6
Description
It's quite common in the Node.js world to write Typedef with JSDoc without creating any variables, e.g.,
```js
/**
* Parse the config and extract arguments from the `process.argv` array.
* @param {Config} config The configuration for parsing.
* @param {string} config.abc The test variable
*/
export function parse(config = {}) {
const { abc } = config
console.log(abc)
}
/**
* @typedef {Object} Config
* @prop {string} abc The test variable
*/
```
The Google Closure Compiler does not understand those types, and VS Code does not understand the compiler notation with variables. Could you make it so it's possible extract the types without variables please.
Contributor guide
Assessment
This issue has not been assessed yet.