@theholocron/astro-config 8.2.3 → 8.2.4

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/README.md +15 -0
  2. package/package.json +4 -5
package/README.md CHANGED
@@ -8,6 +8,21 @@ An [Astro configuration](https://docs.astro.build/en/reference/configuration-ref
8
8
  pnpm add -D @theholocron/astro-config
9
9
  ```
10
10
 
11
+ `defineConfig()` always wires in the `@astrojs/react` integration (needed by
12
+ `@theholocron/docs-theme` consumers that render React components in their
13
+ docs), so `@astrojs/react`, `react`, and `react-dom` are declared as
14
+ `peerDependencies` — install them alongside this package:
15
+
16
+ ```bash
17
+ pnpm add -D @astrojs/react react react-dom
18
+ ```
19
+
20
+ Without them, `pnpm install` still succeeds (with an unmet-peer warning), but
21
+ `astro build`/`astro dev` fails at build time trying to resolve
22
+ `@astrojs/react/server.js` — Vite resolves that import from the consuming
23
+ project's own `node_modules`, not from this package's, so the peer can't be
24
+ satisfied transitively.
25
+
11
26
  ## Usage
12
27
 
13
28
  Pass `starlight` and `docsTheme` from your own imports alongside the docs config. This keeps Astro's module loader in control of those framework imports:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@theholocron/astro-config",
3
- "version": "8.2.3",
3
+ "version": "8.2.4",
4
4
  "description": "Astro configuration factory for theholocron docs sites.",
5
5
  "keywords": [
6
6
  "astro",
@@ -30,10 +30,8 @@
30
30
  "files": [
31
31
  "dist/"
32
32
  ],
33
- "dependencies": {
34
- "@astrojs/react": "^6.0.0"
35
- },
36
33
  "devDependencies": {
34
+ "@astrojs/react": "^6.0.0",
37
35
  "@astrojs/starlight": "^0.41.7",
38
36
  "@theholocron/docs-theme": "^1.3.5",
39
37
  "@vitest/coverage-v8": "^4.1.10",
@@ -43,9 +41,10 @@
43
41
  "tsdown": "^0.22.14",
44
42
  "typescript": "^5.9.3",
45
43
  "vitest": "^4.1.10",
46
- "@theholocron/tsconfig": "8.2.3"
44
+ "@theholocron/tsconfig": "8.2.4"
47
45
  },
48
46
  "peerDependencies": {
47
+ "@astrojs/react": ">=6.0.0",
49
48
  "astro": ">=5.0.0",
50
49
  "react": ">=18.0.0",
51
50
  "react-dom": ">=18.0.0"