create-theokit 1.0.12 → 1.0.13

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-theokit",
3
- "version": "1.0.12",
3
+ "version": "1.0.13",
4
4
  "type": "module",
5
5
  "description": "Scaffold a new TheoKit project",
6
6
  "license": "Apache-2.0",
@@ -21,13 +21,16 @@ paths:
21
21
  The published package is `@theokit/ui` (NOT `@usetheo/ui` — that was the old name).
22
22
 
23
23
  ```bash
24
- # Install from npm
24
+ # Install from npm (preferred)
25
25
  npm install @theokit/ui
26
26
 
27
- # Or link from source (development)
28
- npm link ../theo-ui # if you have the source repo
27
+ # Or from local tarball (when using source repo)
28
+ cd ../theo-ui && npm pack # produces theokit-ui-X.Y.Z.tgz
29
+ cd ../my-app && npm install ../theo-ui/theokit-ui-X.Y.Z.tgz
29
30
  ```
30
31
 
32
+ **WARNING: NEVER use `npm link ../theo-ui` or `file:../theo-ui`.** The symlink exposes the sibling's nested `node_modules/react` (typically a different version), causing dual-React: "React Element from an older version" errors, broken hooks (`useState` null), and silent render failures. `resolve.dedupe` in Vite does NOT fix this — the pnpm structure physically has two React copies. Use tarball (`npm pack` → `npm install .tgz`) instead.
33
+
31
34
  ## Provider Setup (required before using any component)
32
35
 
33
36
  ```typescript
@@ -153,5 +156,6 @@ const myTheme = defineTheme({
153
156
  - NEVER build a custom markdown renderer — `ChatMessageContent` handles it (including streaming partial fences)
154
157
  - NEVER build a custom code highlighter — `CodeBlock` uses shiki (lazy-loaded)
155
158
  - NEVER import from `@usetheo/ui` — that's the deprecated package name; use `@theokit/ui`
159
+ - NEVER use `npm link` or `file:../theo-ui` to install — causes dual-React (use tarball or npm registry)
156
160
  - NEVER install ALL peer deps — only install the peers for components you actually use
157
161
  - NEVER use components without wrapping in `TheoUIProvider` + `ThemeProvider` first