@easy-cms/next 0.13.0 → 0.14.0

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.
Files changed (2) hide show
  1. package/dist/config.js +7 -1
  2. package/package.json +5 -5
package/dist/config.js CHANGED
@@ -2,7 +2,7 @@
2
2
  import { existsSync } from "fs";
3
3
  import { createRequire } from "module";
4
4
  import { dirname, isAbsolute, join, relative, resolve } from "path";
5
- import { CONFIG_FILE_NAMES, importConfig } from "@easy-cms/core";
5
+ import { applyPlugins, CONFIG_FILE_NAMES, importConfig, resolveAdminModule } from "@easy-cms/core";
6
6
  var SERVER_EXTERNAL_PACKAGES = [
7
7
  "@easy-cms/core",
8
8
  "@easy-cms/admin",
@@ -51,6 +51,12 @@ async function tracedFiles(root, configPath) {
51
51
  try {
52
52
  const config = await importConfig(file);
53
53
  for (const path of config?.db?.bundle?.traceInclude ?? []) files.push(toGlob(path));
54
+ const withPlugins = config ? await applyPlugins(config).catch(() => config) : void 0;
55
+ for (const specifier of withPlugins?.admin?.modules ?? []) {
56
+ const module = resolveAdminModule(specifier, root);
57
+ if (module) files.push(toGlob(module));
58
+ else console.warn(`[easy-cms] Admin module "${specifier}" not found from ${root}.`);
59
+ }
54
60
  } catch (error) {
55
61
  console.warn(`[easy-cms] Could not read ${file} at build time: ${error.message}`);
56
62
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@easy-cms/next",
3
- "version": "0.13.0",
3
+ "version": "0.14.0",
4
4
  "description": "Next.js adapter for Easy CMS",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -26,19 +26,19 @@
26
26
  "node": ">=22.12"
27
27
  },
28
28
  "dependencies": {
29
- "@easy-cms/admin": "^0.13.0"
29
+ "@easy-cms/admin": "^0.14.0"
30
30
  },
31
31
  "peerDependencies": {
32
32
  "next": ">=15.0.0",
33
33
  "react": ">=19.0.0",
34
- "@easy-cms/core": "^0.13.0"
34
+ "@easy-cms/core": "^0.14.0"
35
35
  },
36
36
  "devDependencies": {
37
37
  "@types/react": "^19.2.0",
38
38
  "next": "^16.3.6",
39
39
  "react": "^19.2.0",
40
- "@easy-cms/core": "^0.13.0",
41
- "@easy-cms/db-sqlite": "^0.13.0"
40
+ "@easy-cms/core": "^0.14.0",
41
+ "@easy-cms/db-sqlite": "^0.14.0"
42
42
  },
43
43
  "publishConfig": {
44
44
  "access": "public"