@contember/schema-utils
Advanced tools
Comparing version 1.4.0-rc.8 to 2.0.0-alpha.8
@@ -1,12 +0,12 @@ | ||
export declare const readerRole: import("@contember/schema-definition/dist/src/acl/definition").Role<"reader">; | ||
export declare const editorRole: import("@contember/schema-definition/dist/src/acl/definition").Role<"editor">; | ||
export declare const categoryEditorVariable: import("@contember/schema-definition/dist/src/acl/definition").VariableDefinition<"category", import("@contember/schema-definition/dist/src/acl/definition").Role<"editor">, import("@contember/schema").Acl.EntityVariable>; | ||
export declare const readerRole: import("@contember/schema-definition/dist/types/acl/definition").Role<"reader">; | ||
export declare const editorRole: import("@contember/schema-definition/dist/types/acl/definition").Role<"editor">; | ||
export declare const categoryEditorVariable: import("@contember/schema-definition/dist/types/acl/definition").VariableDefinition<"category", import("@contember/schema-definition/dist/types/acl/definition").Role<"editor">, import("@contember/schema").Acl.EntityVariable>; | ||
export declare class Article { | ||
title: import("@contember/schema-definition/dist/src/model/definition").ColumnDefinition; | ||
deletedAt: import("@contember/schema-definition/dist/src/model/definition").ColumnDefinition; | ||
category: import("@contember/schema-definition/dist/src/model/definition/types").Interface<import("@contember/schema-definition/dist/src/model/definition").ManyHasOneDefinitionImpl>; | ||
title: import("@contember/schema-definition/dist/types/model/definition").ColumnDefinition; | ||
deletedAt: import("@contember/schema-definition/dist/types/model/definition").ColumnDefinition; | ||
category: import("@contember/schema-definition/dist/types/model/definition/types").Interface<import("@contember/schema-definition/dist/types/model/definition").ManyHasOneDefinitionImpl>; | ||
} | ||
export declare class Category { | ||
name: import("@contember/schema-definition/dist/src/model/definition").ColumnDefinition; | ||
name: import("@contember/schema-definition/dist/types/model/definition").ColumnDefinition; | ||
} | ||
//# sourceMappingURL=acl.d.ts.map |
export declare class Article { | ||
title: import("@contember/schema-definition/dist/src/model/definition").ColumnDefinition; | ||
title: import("@contember/schema-definition/dist/types/model/definition").ColumnDefinition; | ||
} | ||
//# sourceMappingURL=basic.d.ts.map |
@@ -1,6 +0,6 @@ | ||
export declare const articleState: import("@contember/schema-definition/dist/src/model/definition").EnumDefinition<"draft" | "published">; | ||
export declare const articleState: import("@contember/schema-definition/dist/types/model/definition").EnumDefinition<"draft" | "published">; | ||
export declare class Article { | ||
title: import("@contember/schema-definition/dist/src/model/definition").ColumnDefinition; | ||
state: import("@contember/schema-definition/dist/src/model/definition/types").Interface<import("@contember/schema-definition/dist/src/model/definition").ColumnDefinition>; | ||
title: import("@contember/schema-definition/dist/types/model/definition").ColumnDefinition; | ||
state: import("@contember/schema-definition/dist/types/model/definition/types").Interface<import("@contember/schema-definition/dist/types/model/definition").ColumnDefinition>; | ||
} | ||
//# sourceMappingURL=enum.d.ts.map |
export declare class Article { | ||
title: import("@contember/schema-definition/dist/src/model/definition").ColumnDefinition; | ||
category: import("@contember/schema-definition/dist/src/model/definition/types").Interface<import("@contember/schema-definition/dist/src/model/definition").ManyHasOneDefinitionImpl>; | ||
tags: import("@contember/schema-definition/dist/src/model/definition/types").Interface<import("@contember/schema-definition/dist/src/model/definition").ManyHasManyDefinitionImpl>; | ||
title: import("@contember/schema-definition/dist/types/model/definition").ColumnDefinition; | ||
category: import("@contember/schema-definition/dist/types/model/definition/types").Interface<import("@contember/schema-definition/dist/types/model/definition").ManyHasOneDefinitionImpl>; | ||
tags: import("@contember/schema-definition/dist/types/model/definition/types").Interface<import("@contember/schema-definition/dist/types/model/definition").ManyHasManyDefinitionImpl>; | ||
} | ||
export declare class Category { | ||
name: import("@contember/schema-definition/dist/src/model/definition").ColumnDefinition; | ||
articles: import("@contember/schema-definition/dist/src/model/definition/types").Interface<import("@contember/schema-definition/dist/src/model/definition").OneHasManyDefinitionImpl>; | ||
name: import("@contember/schema-definition/dist/types/model/definition").ColumnDefinition; | ||
articles: import("@contember/schema-definition/dist/types/model/definition/types").Interface<import("@contember/schema-definition/dist/types/model/definition").OneHasManyDefinitionImpl>; | ||
} | ||
export declare class Tag { | ||
name: import("@contember/schema-definition/dist/src/model/definition").ColumnDefinition; | ||
tags: import("@contember/schema-definition/dist/src/model/definition/types").Interface<import("@contember/schema-definition/dist/src/model/definition").ManyHasManyInverseDefinitionImpl>; | ||
name: import("@contember/schema-definition/dist/types/model/definition").ColumnDefinition; | ||
tags: import("@contember/schema-definition/dist/types/model/definition/types").Interface<import("@contember/schema-definition/dist/types/model/definition").ManyHasManyInverseDefinitionImpl>; | ||
} | ||
//# sourceMappingURL=relations.d.ts.map |
export declare class Article { | ||
title: import("@contember/schema-definition/dist/src/model/definition").ColumnDefinition; | ||
title: import("@contember/schema-definition/dist/types/model/definition").ColumnDefinition; | ||
} | ||
//# sourceMappingURL=unique.d.ts.map |
{ | ||
"name": "@contember/schema-utils", | ||
"version": "1.4.0-rc.8", | ||
"version": "2.0.0-alpha.8", | ||
"license": "Apache-2.0", | ||
"main": "dist/src/index.js", | ||
"typings": "dist/src/index.d.ts", | ||
"main": "./dist/production/index.js", | ||
"typings": "./dist/types/index.d.ts", | ||
"exports": { | ||
"typescript": "./src/index.ts", | ||
"default": "./dist/src/index.js" | ||
".": { | ||
"import": { | ||
"types": "./dist/types/index.d.ts", | ||
"development": "./dist/development/index.js", | ||
"production": "./dist/production/index.js", | ||
"typescript": "./src/index.ts", | ||
"default": "./dist/production/index.js" | ||
}, | ||
"require": { | ||
"types": "./dist/types/index.d.ts", | ||
"development": "./dist/development/index.cjs", | ||
"production": "./dist/production/index.cjs", | ||
"typescript": "./src/index.ts", | ||
"default": "./dist/production/index.cjs" | ||
} | ||
} | ||
}, | ||
"scripts": { | ||
"test": "vitest --dir ./tests/cases" | ||
}, | ||
"dependencies": { | ||
"@contember/schema": "1.4.0-rc.8", | ||
"@contember/typesafe": "1.4.0-rc.8" | ||
"@contember/schema": "2.0.0-alpha.8", | ||
"@contember/typesafe": "2.0.0-alpha.8" | ||
}, | ||
"devDependencies": { | ||
"@contember/schema-definition": "1.4.0-rc.8", | ||
"@contember/schema-definition": "2.0.0-alpha.8", | ||
"@types/node": "^20.9.0" | ||
} | ||
}, | ||
"type": "module" | ||
} |
{ | ||
"extends": "../tsconfig.settings.json", | ||
"compilerOptions": { | ||
"outDir": "../dist/src", | ||
"outDir": "../dist/types", | ||
"esModuleInterop": true | ||
@@ -6,0 +6,0 @@ }, |
@@ -11,4 +11,5 @@ import { createSchema } from '@contember/schema-definition' | ||
import { DefinitionCodeGenerator } from '../../../src/definition-generator/DefinitionCodeGenerator' | ||
import { dirname } from 'node:path' | ||
import { fileURLToPath } from 'node:url' | ||
const tests = [ | ||
@@ -25,3 +26,3 @@ ['basic', basic], | ||
const generator = new DefinitionCodeGenerator() | ||
const content = await readFile(join(__dirname, `schemas/${name}.ts`), 'utf-8') | ||
const content = await readFile(join(dirname(fileURLToPath(import.meta.url)), `schemas/${name}.ts`), 'utf-8') | ||
const generated = generator.generate(schema) | ||
@@ -31,3 +32,3 @@ try { | ||
} catch (e) { | ||
await writeFile(join(__dirname, `schemas/${name}.actual.ts`), generated, 'utf8') | ||
await writeFile(join(dirname(fileURLToPath(import.meta.url)), `schemas/${name}.actual.ts`), generated, 'utf8') | ||
throw e | ||
@@ -34,0 +35,0 @@ } |
@@ -8,4 +8,5 @@ { | ||
"references": [ | ||
{ "path": "../src" } | ||
{ "path": "../src" }, | ||
{ "path": "../../schema-definition/src" }, | ||
] | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
1539111
445
16707
1
Yes
1
+ Added@contember/schema@2.0.0-alpha.8(transitive)
+ Added@contember/typesafe@2.0.0-alpha.8(transitive)
- Removed@contember/schema@1.4.0-rc.8(transitive)
- Removed@contember/typesafe@1.4.0-rc.8(transitive)