-
-
Notifications
You must be signed in to change notification settings - Fork 740
Closed
Milestone
Description
Search terms
@default
, complex object, jsdoc tag
Expected Behavior
Typedoc should support complex @default
values.
Actual Behavior
./index.ts:12:10 - warning Encountered an unescaped open brace without an inline tag
12 * uuid({ foo: "bar" })
./index.ts:12:23 - warning Unmatched closing brace
12 * uuid({ foo: "bar" })
It doesn't output the warning, when using an @example
tag.
IMO @default
refers to a value and thus should behave the same as @example
.
Steps to reproduce the bug
import type { ProjectReflection, TypeDocOptions } from "typedoc";
import { Application, TSConfigReader } from "typedoc";
/**
* Foo.
*/
export function foo(options: {
/**
* @example uuid({ foo: "bar" })
*/
bar: string;
}) {
return options.bar;
}
function loadProject(
options: Partial<TypeDocOptions> = {
entryPoints: ["index.ts"],
pretty: true,
cleanOutputDir: true,
}
): [Application, ProjectReflection] {
const app = new Application();
app.options.addReader(new TSConfigReader());
app.bootstrap(options);
const project = app.convert();
app.generateJson(project, "output.json");
return [app, project];
}
loadProject();
Environment
- Typedoc version: 0.23.28
- TypeScript version: 5.0.3, 4.9.5 (doesn't really matter)
- Node.js version: v18.15.0
- OS: Win10