TypeScript Version: 4.0.0-dev.20200516
Search Terms:: JSDoc invalid dts
Code
/** * @param {Array=} y desc */functionx(y){}/** * @param {function (Olm.InboundGroupSession)} func Invoked */functiony(func){}/** * @return {(Array.<> | null)} list of devices */functionz(){}/** * * @return {?Promise} A promise */functionw(){}Compiler Options
{
"compilerOptions": {
"noImplicitAny": true,
"strictFunctionTypes": true,
"strictPropertyInitialization": true,
"strictBindCallApply": true,
"noImplicitThis": true,
"noImplicitReturns": true,
"alwaysStrict": true,
"esModuleInterop": true,
"checkJs": true,
"allowJs": true,
"declaration": true,
"experimentalDecorators": true,
"emitDecoratorMetadata": true,
"moduleResolution": 2,
"target": "ES2017",
"jsx": "React",
"module": "ESNext"
}
}Invalid outputs:
/** * @param {Array=} y desc */declarefunctionx(y?: Array|undefined): void;// ~~~~~~~~~~~~~~~~~~~~~~~~~^ Missing generics/** * @param {function (Olm.InboundGroupSession)} func Invoked */declarefunctiony(func: (arg0: any)=>): void;// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^ invalid type signature/** * @return {(Array.<> | null)} list of devices */declarefunctionz(): (Array|null);// ~~~~~~~~~~~~~~~~~~~~~~~~~^ missing generics/** * * @return {?Promise} A promise */declarefunctionw(): Promise|null;// ~~~~~~~~~~~~~~~~~~~~~~~~~~^ missing genericsPlayground Link:Provided
TypeScript Version: 4.0.0-dev.20200516
Search Terms:: JSDoc invalid dts
Code
Compiler Options
{ "compilerOptions": { "noImplicitAny": true, "strictFunctionTypes": true, "strictPropertyInitialization": true, "strictBindCallApply": true, "noImplicitThis": true, "noImplicitReturns": true, "alwaysStrict": true, "esModuleInterop": true, "checkJs": true, "allowJs": true, "declaration": true, "experimentalDecorators": true, "emitDecoratorMetadata": true, "moduleResolution": 2, "target": "ES2017", "jsx": "React", "module": "ESNext" } }Invalid outputs:
Playground Link:Provided