Skip to content

Commit 49cfe40

Browse files
committed
fix: Reverted back to static imports for JSON
1 parent 02cce95 commit 49cfe40

3 files changed

Lines changed: 37 additions & 39 deletions

File tree

package-lock.json

Lines changed: 14 additions & 17 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
{
22
"name": "codify-schemas",
3-
"version": "1.0.60",
3+
"version": "1.0.63",
44
"description": "",
55
"type": "module",
66
"main": "dist/index.js",
77
"typings": "dist/index.d.ts",
88
"scripts": {
99
"test": "vitest",
10-
"prepublish": "tsc"
10+
"prepublishOnly": "tsc"
1111
},
1212
"keywords": [],
1313
"author": "",
@@ -16,6 +16,7 @@
1616
"ajv": "^8.12.0"
1717
},
1818
"devDependencies": {
19+
"@types/node": "20.17.14",
1920
"vitest": "^1.4.0",
2021
"typescript": "^5.3.3",
2122
"ajv-formats": "^3.0.1"

src/index.ts

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,23 @@
1-
const ConfigFileSchema = (await import('./config-file-schema.json', {assert: {type: 'json'}})).default
2-
const ProjectSchema = (await import('./project-schema.json', {assert: {type: 'json'}})).default
3-
const ResourceSchema = (await import('./resource-schema.json', {assert: {type: 'json'}})).default
4-
const IpcMessageSchema = (await import('./ipc-message-schema.json', {assert: {type: 'json'}})).default
5-
const IpcMessageV2Schema = (await import('./ipc-message-schema-v2.json', {assert: {type: 'json'}})).default
6-
const ApplyRequestDataSchema = (await import('./messages/apply-request-data-schema.json', {assert: {type: 'json'}})).default
7-
const ApplyResponseDataSchema = (await import('./messages/apply-response-data-schema.json', {assert: {type: 'json'}})).default
8-
const ErrorResponseDataSchema = (await import('./messages/error-response-data-schema.json', {assert: {type: 'json'}})).default
9-
const GetResourceInfoRequestDataSchema = (await import('./messages/get-resource-info-request-data-schema.json', {assert: {type: 'json'}})).default
10-
const GetResourceInfoResponseDataSchema = (await import('./messages/get-resource-info-response-data-schema.json', {assert: {type: 'json'}})).default
11-
const ImportRequestDataSchema = (await import('./messages/import-request-data-schema.json', {assert: {type: 'json'}})).default
12-
const ImportResponseDataSchema = (await import('./messages/import-response-data-schema.json', {assert: {type: 'json'}})).default
13-
const PlanRequestDataSchema = (await import('./messages/plan-request-data-schema.json', {assert: {type: 'json'}})).default
14-
const PlanResponseDataSchema = (await import('./messages/plan-response-data-schema.json', {assert: {type: 'json'}})).default
15-
const ValidateRequestDataSchema = (await import('./messages/validate-request-data-schema.json', {assert: {type: 'json'}})).default
16-
const ValidateResponseDataSchema = (await import('./messages/validate-response-data-schema.json', {assert: {type: 'json'}})).default
17-
const InitializeRequestDataSchema = (await import('./messages/initialize-request-data-schema.json', {assert: {type: 'json'}})).default
18-
const InitializeResponseDataSchema = (await import('./messages/initialize-response-data-schema.json', {assert: {type: 'json'}})).default
19-
const SudoRequestDataSchema = (await import('./messages/sudo-request-data-schema.json', {assert: {type: 'json'}})).default
20-
const SudoRequestResponseDataSchema = (await import('./messages/sudo-response-data-schema.json', {assert: {type: 'json'}})).default
1+
import ConfigFileSchema from './config-file-schema.json' with {type: 'json'}
2+
import ProjectSchema from './project-schema.json' with {type: 'json'}
3+
import ResourceSchema from './resource-schema.json' with {type: 'json'}
4+
import IpcMessageSchema from './ipc-message-schema.json' with {type: 'json'}
5+
import IpcMessageV2Schema from './ipc-message-schema-v2.json' with {type: 'json'}
6+
import ApplyRequestDataSchema from './messages/apply-request-data-schema.json' with {type: 'json'}
7+
import ApplyResponseDataSchema from './messages/apply-response-data-schema.json' with {type: 'json'}
8+
import ErrorResponseDataSchema from './messages/error-response-data-schema.json' with {type: 'json'}
9+
import GetResourceInfoRequestDataSchema from './messages/get-resource-info-request-data-schema.json' with {type: 'json'}
10+
import GetResourceInfoResponseDataSchema from './messages/get-resource-info-response-data-schema.json' with {type: 'json'}
11+
import ImportRequestDataSchema from './messages/import-request-data-schema.json' with {type: 'json'}
12+
import ImportResponseDataSchema from './messages/import-response-data-schema.json' with {type: 'json'}
13+
import PlanRequestDataSchema from './messages/plan-request-data-schema.json' with {type: 'json'}
14+
import PlanResponseDataSchema from './messages/plan-response-data-schema.json' with {type: 'json'}
15+
import ValidateRequestDataSchema from './messages/validate-request-data-schema.json' with {type: 'json'}
16+
import ValidateResponseDataSchema from './messages/validate-response-data-schema.json' with {type: 'json'}
17+
import InitializeRequestDataSchema from './messages/initialize-request-data-schema.json' with {type: 'json'}
18+
import InitializeResponseDataSchema from './messages/initialize-response-data-schema.json' with {type: 'json'}
19+
import SudoRequestDataSchema from './messages/sudo-request-data-schema.json' with {type: 'json'};
20+
import SudoRequestResponseDataSchema from './messages/sudo-response-data-schema.json' with {type: 'json'};
2121

2222
export {
2323
ConfigFileSchema,

0 commit comments

Comments
 (0)