mirror of
https://github.com/kennethnym/jrx.git
synced 2026-03-20 03:41:18 +00:00
Add example: Bun HTTP server showcasing jrx JSX-to-JSON rendering
Bun React app with HMR that demonstrates jrx's render() pipeline. Shows JSX source, live UI via @json-render/react, and JSON output side by side. - example/specs/simple.tsx: flat Stack > Text + Button - example/specs/full.tsx: nested layout with state, events, visibility conditions, and watchers - Uses defineCatalog + defineRegistry from @json-render/react - Fix package.json exports to match actual tsup output (.js/.cjs instead of .mjs/.js) Co-authored-by: Ona <no-reply@ona.com>
This commit is contained in:
16
package.json
16
package.json
@@ -4,24 +4,24 @@
|
||||
"license": "MIT",
|
||||
"description": "JSX factory for json-render. Write JSX, get Spec JSON.",
|
||||
"type": "module",
|
||||
"main": "./dist/index.js",
|
||||
"module": "./dist/index.mjs",
|
||||
"main": "./dist/index.cjs",
|
||||
"module": "./dist/index.js",
|
||||
"types": "./dist/index.d.ts",
|
||||
"exports": {
|
||||
".": {
|
||||
"types": "./dist/index.d.ts",
|
||||
"import": "./dist/index.mjs",
|
||||
"require": "./dist/index.js"
|
||||
"import": "./dist/index.js",
|
||||
"require": "./dist/index.cjs"
|
||||
},
|
||||
"./jsx-runtime": {
|
||||
"types": "./dist/jsx-runtime.d.ts",
|
||||
"import": "./dist/jsx-runtime.mjs",
|
||||
"require": "./dist/jsx-runtime.js"
|
||||
"import": "./dist/jsx-runtime.js",
|
||||
"require": "./dist/jsx-runtime.cjs"
|
||||
},
|
||||
"./jsx-dev-runtime": {
|
||||
"types": "./dist/jsx-dev-runtime.d.ts",
|
||||
"import": "./dist/jsx-dev-runtime.mjs",
|
||||
"require": "./dist/jsx-dev-runtime.js"
|
||||
"import": "./dist/jsx-dev-runtime.js",
|
||||
"require": "./dist/jsx-dev-runtime.cjs"
|
||||
}
|
||||
},
|
||||
"files": [
|
||||
|
||||
Reference in New Issue
Block a user