@korajs/devtools 0.0.0-canary-20261008174129

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 (46) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +49 -0
  3. package/dist/chunk-LQFL4TWM.js +999 -0
  4. package/dist/chunk-LQFL4TWM.js.map +1 -0
  5. package/dist/embed-overlay-Dwys5PYM.d.cts +170 -0
  6. package/dist/embed-overlay-Dwys5PYM.d.ts +170 -0
  7. package/dist/extension/background.cjs +65 -0
  8. package/dist/extension/background.cjs.map +1 -0
  9. package/dist/extension/background.d.cts +2 -0
  10. package/dist/extension/background.d.ts +2 -0
  11. package/dist/extension/background.js +63 -0
  12. package/dist/extension/background.js.map +1 -0
  13. package/dist/extension/content-script.cjs +18 -0
  14. package/dist/extension/content-script.cjs.map +1 -0
  15. package/dist/extension/content-script.d.cts +2 -0
  16. package/dist/extension/content-script.d.ts +2 -0
  17. package/dist/extension/content-script.js +16 -0
  18. package/dist/extension/content-script.js.map +1 -0
  19. package/dist/extension/devtools-page.html +45 -0
  20. package/dist/extension/devtools.cjs +8 -0
  21. package/dist/extension/devtools.cjs.map +1 -0
  22. package/dist/extension/devtools.d.cts +2 -0
  23. package/dist/extension/devtools.d.ts +2 -0
  24. package/dist/extension/devtools.html +599 -0
  25. package/dist/extension/devtools.js +6 -0
  26. package/dist/extension/devtools.js.map +1 -0
  27. package/dist/extension/manifest.json +20 -0
  28. package/dist/extension/panel.cjs +1311 -0
  29. package/dist/extension/panel.cjs.map +1 -0
  30. package/dist/extension/panel.d.cts +2 -0
  31. package/dist/extension/panel.d.ts +2 -0
  32. package/dist/extension/panel.js +1309 -0
  33. package/dist/extension/panel.js.map +1 -0
  34. package/dist/index.cjs +1353 -0
  35. package/dist/index.cjs.map +1 -0
  36. package/dist/index.d.cts +107 -0
  37. package/dist/index.d.ts +107 -0
  38. package/dist/index.js +326 -0
  39. package/dist/index.js.map +1 -0
  40. package/dist/overlay.cjs +1027 -0
  41. package/dist/overlay.cjs.map +1 -0
  42. package/dist/overlay.d.cts +2 -0
  43. package/dist/overlay.d.ts +2 -0
  44. package/dist/overlay.js +7 -0
  45. package/dist/overlay.js.map +1 -0
  46. package/package.json +55 -0
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Dr. Obed Ehoneah
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,49 @@
1
+ # @korajs/devtools
2
+
3
+ Browser DevTools extension for Kora.js. Inspect operations, trace conflict resolution decisions, monitor sync status, and debug your offline-first app in real time.
4
+
5
+ ## Install
6
+
7
+ `korajs` already depends on `@korajs/devtools`; apps only turn it on. Install it directly to use
8
+ the building blocks (`Instrumenter`, `EventBuffer`, the panel renderer) in your own tooling:
9
+
10
+ ```bash
11
+ pnpm add -D @korajs/devtools@beta
12
+ ```
13
+
14
+ ## Enable
15
+
16
+ <!-- docs-check: standalone -->
17
+ ```typescript
18
+ import { createApp, defineSchema, t } from 'korajs'
19
+
20
+ const schema = defineSchema({ version: 1, collections: { todos: { fields: { title: t.string() } } } })
21
+
22
+ const app = createApp({
23
+ schema,
24
+ devtools: import.meta.env.DEV,
25
+ })
26
+ ```
27
+
28
+ With `devtools: true`, Kora records instrumentation events and:
29
+
30
+ - mounts an in-page overlay, toggled with `Ctrl+Shift+K` (`Cmd+Shift+K` on macOS);
31
+ - forwards events to the browser extension. The extension is not published to a store yet: build
32
+ it with `pnpm --filter @korajs/devtools build` in the Kora repository and load
33
+ `packages/devtools/dist/extension` as an unpacked extension in a Chromium browser.
34
+
35
+ ## Panels
36
+
37
+ - **Timeline**: recorded events in order, color-coded by type.
38
+ - **Conflicts**: every merge conflict with its strategy, tier, inputs and result.
39
+ - **Operations**: operations created on this device and applied from sync, with payload, node,
40
+ sequence number and causal dependencies.
41
+ - **Network**: connection state and quality, operations sent and received, last sync, and a
42
+ version vector derived from the recorded operations.
43
+
44
+ The panels show events recorded since the page loaded. The complete event catalog is in the
45
+ [DevTools API reference](https://korajs.dev/api/devtools#events).
46
+
47
+ ## License
48
+
49
+ MIT