Skip to content

Commit

Permalink
feat: export typescript dependency (#1339)
Browse files Browse the repository at this point in the history
  • Loading branch information
sergei-dyshel committed Jul 23, 2022
1 parent 2a67697 commit a76b1ed
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
3 changes: 2 additions & 1 deletion README.md
Expand Up @@ -137,7 +137,8 @@ Similar to custom formatting, extending the built-in parsing works practically t
```ts
// my-constructor-parser.ts
import { Context, StringType, ReferenceType, BaseType, SubNodeParser } from "ts-json-schema-generator";
import ts from "typescript";
// use typescript exported by TJS to avoid version conflict
import ts from "ts-json-schema-generator";

export class MyConstructorParser implements SubNodeParser {
supportsNode(node: ts.Node): boolean {
Expand Down
3 changes: 3 additions & 0 deletions index.ts
Expand Up @@ -158,3 +158,6 @@ export * from "./src/NodeParser/VoidTypeNodeParser";
export * from "./src/SchemaGenerator";

export * from "./factory";

import ts from "typescript";
export { ts };

0 comments on commit a76b1ed

Please sign in to comment.