nextjs-cms 0.5.15 → 0.5.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"loader.d.ts","sourceRoot":"","sources":["../../../src/core/config/loader.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"loader.d.ts","sourceRoot":"","sources":["../../../src/core/config/loader.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,gBAAgB,QAAO,OAwCnC,CAAA"}
|
|
@@ -1,10 +1,8 @@
|
|
|
1
1
|
import { existsSync } from 'fs';
|
|
2
2
|
import { resolve, join } from 'path';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
return req(id);
|
|
7
|
-
};
|
|
3
|
+
import { createRequire } from 'module';
|
|
4
|
+
// Create a require function that works in ES modules
|
|
5
|
+
const safeRequire = createRequire(import.meta.url);
|
|
8
6
|
export const loadConfigModule = () => {
|
|
9
7
|
const cwd = process.cwd();
|
|
10
8
|
const candidates = [
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SectionFactory.d.ts","sourceRoot":"","sources":["../../../src/core/factories/SectionFactory.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,eAAe,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAA;AACtF,OAAO,KAAK,EAAE,qBAAqB,EAAE,qBAAqB,EAAE,mBAAmB,EAAE,MAAM,sBAAsB,CAAA;AAC7G,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;
|
|
1
|
+
{"version":3,"file":"SectionFactory.d.ts","sourceRoot":"","sources":["../../../src/core/factories/SectionFactory.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,eAAe,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAA;AACtF,OAAO,KAAK,EAAE,qBAAqB,EAAE,qBAAqB,EAAE,mBAAmB,EA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G;WACU,UAAU,CAAC,EACpB,IAAI,EACJ,IAAI,GACP,EAAE;QACC,IAAI,EAAE,MAAM,CAAA;QACZ,IAAI,CAAC,EAAE,YAAY,GAAG,YAAY,EAAE,CAAA;KACvC,GAAG,OAAO,CAAC,gBAAgB,GAAG,IAAI,CAAC;IAKpC;;;;;;OAMG;WACU,kBAAkB,CAAC,EAC5B,IAAI,EACJ,IAAI,EACJ,KAAK,GACR,EAAE;QACC,IAAI,EAAE,MAAM,CAAA;QACZ,IAAI,CAAC,EAAE,YAAY,GAAG,YAAY,EAAE,CAAA;QACpC,KAAK,EAAE;YACH,EAAE,EAAE,MAAM,CAAA;YACV,YAAY,CAAC,EAAE,GAAG,GAAG,GAAG,GAAG,GAAG,CAAA;SACjC,CAAA;KACJ,GAAG,OAAO,CAAC,gBAAgB,GAAG,IAAI,CAAC;IAKpC;;;;;;;;;;OAUG;IACH,MAAM,CAAC,MAAM,CAAC,MAAM,EAAE;QAClB,KAAK,EAAE,MAAM,eAAe,GAAG,aAAa,GAAG,eAAe,CAAA;QAC9D,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;KACrB,GAAG,eAAe,GAAG,aAAa,GAAG,eAAe;IAYrD;;;;;;;;;OASG;mBACkB,GAAG;IA6FxB;;;;OAIG;mBACkB,eAAe;IAuHpC,OAAO,CAAC,MAAM,CAAC,YAAY;IA+D3B,OAAO,CAAC,MAAM,CAAC,IAAI;CAatB"}
|
|
@@ -5,15 +5,14 @@ import chalk from 'chalk';
|
|
|
5
5
|
import { eq } from 'drizzle-orm';
|
|
6
6
|
import chokidar from 'chokidar';
|
|
7
7
|
import fs from 'fs';
|
|
8
|
+
import { createRequire } from 'module';
|
|
8
9
|
import { db } from '../../db/client.js';
|
|
9
10
|
import { AdminPrivilegesTable } from '../../db/schema.js';
|
|
10
11
|
import { getCMSConfig } from '../config/index.js';
|
|
11
12
|
const cmsConfig = getCMSConfig();
|
|
12
13
|
const hotMarkerFile = resolve(process.cwd(), 'next-cms-sectioninfo.js');
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
return req(id);
|
|
16
|
-
};
|
|
14
|
+
// Create a require function that works in ES modules
|
|
15
|
+
const safeRequire = createRequire(import.meta.url);
|
|
17
16
|
/**
|
|
18
17
|
* Register esbuild-register only once per process.
|
|
19
18
|
* Node's require cache ensures each TS module is evaluated once.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "nextjs-cms",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.17",
|
|
4
4
|
"main": "./dist/index.js",
|
|
5
5
|
"types": "./dist/index.d.ts",
|
|
6
6
|
"type": "module",
|
|
@@ -112,7 +112,7 @@
|
|
|
112
112
|
"axios": "^1.8.4",
|
|
113
113
|
"bcrypt": "^6.0.0",
|
|
114
114
|
"chalk": "^5.4.1",
|
|
115
|
-
"chokidar": "
|
|
115
|
+
"chokidar": "3.6.0",
|
|
116
116
|
"commander": "^14.0.2",
|
|
117
117
|
"devalue": "^5.1.1",
|
|
118
118
|
"dotenv": "^16.4.7",
|