Skip to content

Commit cc37f11

Browse files
docs: media.
1 parent e43e827 commit cc37f11

4 files changed

Lines changed: 146 additions & 46 deletions

File tree

README.md

Lines changed: 22 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -1,60 +1,38 @@
1-
# @knighted/develop
1+
# <img src="src/logo.svg" alt="@knighted/develop logo" width="36" height="36" style="vertical-align: middle;" /> <span style="vertical-align: middle;"><code>@knighted/develop</code></span>
22

3-
Compiler-as-a-Service (at the edge of your browser) with `@knighted/jsx` and `@knighted/css`.
3+
CDN-first browser IDE for building UI components with [`@knighted/jsx`](https://github.com/knightedcodemonkey/jsx) and [`@knighted/css`](https://github.com/knightedcodemonkey/css).
44

5-
> ⚠️ Early project status: this package is pre-`1.0.0` and still actively evolving.
5+
![Animated flow showing editing, diagnostics, jump-to-source, and fix loop](docs/media/develop-ide-flow.gif)
66

77
## What it is
88

9-
`@knighted/develop` is a lightweight dev app that lets you:
9+
`@knighted/develop` is a browser-native IDE that demonstrates modern component
10+
authoring without a local bundler-first inner loop.
1011

11-
- write component code in the browser
12-
- switch render mode between DOM and React
13-
- switch style mode between native CSS, CSS Modules, Less, and Sass
14-
- preview results immediately
15-
16-
## Local development
17-
18-
```bash
19-
npm install
20-
npm run dev
21-
```
22-
23-
Then open the URL printed by the dev server (it should open `src/index.html`).
24-
25-
## End-to-end tests
12+
The app is designed to showcase two libraries:
2613

27-
Install Playwright browsers once before your first local run:
14+
- [`@knighted/jsx`](https://github.com/knightedcodemonkey/jsx) for DOM-first and React-mode JSX authoring
15+
- [`@knighted/css`](https://github.com/knightedcodemonkey/css) for in-browser CSS compilation workflows
2816

29-
```bash
30-
npx playwright install
31-
```
17+
Dependencies are delivered over CDN ESM with on-demand loading by mode, so the
18+
browser acts as the runtime host for render, lint, and typecheck flows.
3219

33-
If your environment needs system dependencies too (for example Linux CI-like containers), use:
20+
## Core capabilities
3421

35-
```bash
36-
npx playwright install --with-deps
37-
```
22+
`@knighted/develop` lets you:
3823

39-
Run local Playwright tests (Chromium):
40-
41-
```bash
42-
npm run test:e2e
43-
```
44-
45-
Run locally with headed browser:
46-
47-
```bash
48-
npm run test:e2e:headed
49-
```
50-
51-
CI runs Playwright on Chromium and WebKit.
24+
- write component code in the browser
25+
- switch render mode between DOM and React
26+
- switch style mode between native CSS, CSS Modules, Less, and Sass
27+
- run in-browser lint and type diagnostics
28+
- open diagnostics in a shared drawer and jump to source locations
29+
- toggle ShadowRoot preview isolation while iterating
30+
- switch layout and theme while preserving fast feedback loops
5231

53-
## Notes
32+
## Try it
5433

55-
- This is currently a development playground, not a stable product.
56-
- Expect breaking changes while APIs and UX are still being shaped.
57-
- Documentation will expand closer to `1.0.0`.
34+
- Live IDE: https://knightedcodemonkey.github.io/develop/
35+
- Source repository: https://github.com/knightedcodemonkey/develop
5836

5937
## License
6038

docs/contributing.md

Lines changed: 120 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,120 @@
1+
# Contributing
2+
3+
Thanks for contributing to `@knighted/develop`.
4+
5+
This project is a CDN-first browser IDE for showcasing `@knighted/jsx` and
6+
`@knighted/css`, so local workflows should preserve browser execution behavior
7+
and avoid bundler-only assumptions in `src/` runtime code.
8+
9+
## Project docs
10+
11+
- Type checking notes: `docs/type-checking.md`
12+
- Build and deploy notes: `docs/build-and-deploy.md`
13+
- CodeMirror integration notes: `docs/code-mirror.md`
14+
- Roadmap: `docs/next-steps.md`
15+
- Article draft: `docs/article.md`
16+
17+
## Prerequisites
18+
19+
- Node.js `>= 22.22.1`
20+
- npm
21+
22+
## Install
23+
24+
```bash
25+
npm install
26+
```
27+
28+
## Local development
29+
30+
Start the local app:
31+
32+
```bash
33+
npm run dev
34+
```
35+
36+
The local server opens `src/index.html`.
37+
38+
## Build commands
39+
40+
Build prep + CSS + import map generation:
41+
42+
```bash
43+
npm run build
44+
```
45+
46+
Build with explicit primary CDN modes:
47+
48+
```bash
49+
npm run build:esm
50+
npm run build:jspm
51+
npm run build:importmap-mode
52+
```
53+
54+
Preview generated dist output:
55+
56+
```bash
57+
npm run preview
58+
```
59+
60+
## Validation commands
61+
62+
Lint source and Playwright files:
63+
64+
```bash
65+
npm run lint
66+
```
67+
68+
Type check TS tooling files:
69+
70+
```bash
71+
npm run check-types
72+
```
73+
74+
## Playwright end-to-end tests
75+
76+
Install browser binaries once:
77+
78+
```bash
79+
npx playwright install
80+
```
81+
82+
If your environment also needs system deps (for example CI-like Linux
83+
containers):
84+
85+
```bash
86+
npx playwright install --with-deps
87+
```
88+
89+
Run preview-mode E2E suite:
90+
91+
```bash
92+
npm run test:e2e
93+
```
94+
95+
Run dev-mode E2E suite:
96+
97+
```bash
98+
npm run test:e2e:dev
99+
```
100+
101+
Run preview-mode suite headed:
102+
103+
```bash
104+
npm run test:e2e:headed
105+
```
106+
107+
## Contributor checklist
108+
109+
Before opening a PR:
110+
111+
1. Run `npm run lint`.
112+
2. Run `npm run build:esm` for runtime/build changes.
113+
3. Run relevant Playwright tests for UI/runtime changes.
114+
4. Update docs when user-facing behavior or workflows change.
115+
116+
## Scope guidance
117+
118+
- Keep changes focused to `@knighted/develop`.
119+
- Preserve CDN-first loading and fallback behavior.
120+
- Avoid editing generated output unless explicitly required.

docs/media/develop-ide-flow.gif

1.14 MB
Loading

src/index.html

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -399,8 +399,10 @@ <h3>Styles</h3>
399399

400400
<footer class="app-footer">
401401
<div>
402-
Uses @knighted/jsx runtime with browser WASM parser from CDN and
403-
@knighted/css/browser for in-browser CSS, CSS Modules, Less, and Sass.
402+
Powered by
403+
<a href="https://github.com/knightedcodemonkey/jsx">@knighted/jsx</a>,
404+
<a href="https://github.com/knightedcodemonkey/css">@knighted/css</a>, and
405+
CDN-delivered runtimes and compilers.
404406
</div>
405407
</footer>
406408

0 commit comments

Comments
 (0)