Skip to content

Commit 5948aab

Browse files
authored
fix: switch to merging allOf keywords instead of extending them (#109)
1 parent 6fdfdc9 commit 5948aab

File tree

4 files changed

+184
-297
lines changed

4 files changed

+184
-297
lines changed

src/simplification/Simplifier.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import simplifyName from './SimplifyName';
1212

1313
export class Simplifier {
1414
static defaultOptions: SimplificationOptions = {
15-
allowInheritance: true
15+
allowInheritance: false
1616
}
1717

1818
private anonymCounter = 1;
@@ -148,7 +148,7 @@ export class Simplifier {
148148
*
149149
* @param schema to simplify
150150
*/
151-
export function simplify(schema: Schema | boolean): CommonModel[] {
152-
const simplifier = new Simplifier();
151+
export function simplify(schema: Schema | boolean, options?: SimplificationOptions): CommonModel[] {
152+
const simplifier = new Simplifier(options);
153153
return simplifier.simplify(schema);
154154
}

0 commit comments

Comments
 (0)