@myxo-victor/chexjs 6.0.0 → 6.0.2
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/README.md +106 -0
- package/package.json +1 -1
- package/ChexJs/README.md +0 -121
- /package/{ChexJs/.htaccess → .htaccess} +0 -0
- /package/{ChexJs/Chex.js → Chex.js} +0 -0
- /package/{ChexJs/Chex.php → Chex.php} +0 -0
- /package/{ChexJs/Chex_notify.php → Chex_notify.php} +0 -0
- /package/{ChexJs/LICENSE → LICENSE} +0 -0
- /package/{ChexJs/api → api}/read.txt +0 -0
- /package/{ChexJs/app → app}/api/api.txt +0 -0
- /package/{ChexJs/app → app}/components/main.js +0 -0
- /package/{ChexJs/app → app}/index.css +0 -0
- /package/{ChexJs/app → app}/index.html +0 -0
- /package/{ChexJs/app → app}/logic/app.js +0 -0
- /package/{ChexJs/components → components}/demo.js +0 -0
- /package/{ChexJs/components → components}/main.js +0 -0
- /package/{ChexJs/images → images}/logo.png +0 -0
- /package/{ChexJs/index.css → index.css} +0 -0
- /package/{ChexJs/index.html → index.html} +0 -0
- /package/{ChexJs/libs → libs}/modal.js +0 -0
- /package/{ChexJs/libs → libs}/orbit.js +0 -0
- /package/{ChexJs/libs → libs}/racket.js +0 -0
- /package/{ChexJs/libs → libs}/rinx.js +0 -0
- /package/{ChexJs/libs → libs}/scrollEcho.js +0 -0
- /package/{ChexJs/libs → libs}/skeleton.js +0 -0
- /package/{ChexJs/libs → libs}/smooth.js +0 -0
- /package/{ChexJs/logic → logic}/app.js +0 -0
- /package/{ChexJs/notification_handler.txt → notification_handler.txt} +0 -0
- /package/{ChexJs/sw.js → sw.js} +0 -0
package/README.md
ADDED
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
# ChexJs
|
|
2
|
+
|
|
3
|
+
[](https://www.npmjs.com/package/@myxo-victor/chexjs)
|
|
4
|
+
[](#license)
|
|
5
|
+
|
|
6
|
+
**ChexJs** is a lightweight, high-performance JavaScript UI engine for building reactive, component-driven interfaces. It runs directly in the browser with zero build steps, no compilers, and no `node_modules` overhead.
|
|
7
|
+
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
## Installation
|
|
11
|
+
|
|
12
|
+
Install via npm:
|
|
13
|
+
|
|
14
|
+
```bash
|
|
15
|
+
npm install @myxo-victor/chexjs
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
---
|
|
19
|
+
|
|
20
|
+
## Quick Start
|
|
21
|
+
|
|
22
|
+
Import and write components using Chex's tag helpers:
|
|
23
|
+
|
|
24
|
+
```js
|
|
25
|
+
import Chex from '@myxo-victor/chexjs';
|
|
26
|
+
|
|
27
|
+
const { div, h1, button } = Chex;
|
|
28
|
+
const app = document.getElementById('app');
|
|
29
|
+
const count = Chex.signal(0);
|
|
30
|
+
|
|
31
|
+
const Counter = () => div({ class: 'counter' }, [
|
|
32
|
+
h1(`Count: ${count.value}`),
|
|
33
|
+
button({ onClick: () => (count.value += 1) }, 'Increment')
|
|
34
|
+
]);
|
|
35
|
+
|
|
36
|
+
Chex.render(app, Counter);
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
---
|
|
40
|
+
|
|
41
|
+
## Fast Element API
|
|
42
|
+
|
|
43
|
+
Chex tag helpers are flexible. You can provide props as the first argument, or omit them entirely to pass children directly:
|
|
44
|
+
|
|
45
|
+
```js
|
|
46
|
+
// With props
|
|
47
|
+
div({ class: 'hero' }, [
|
|
48
|
+
h1({}, 'Title'),
|
|
49
|
+
button({ onClick: save }, 'Save')
|
|
50
|
+
]);
|
|
51
|
+
|
|
52
|
+
// No empty props object required
|
|
53
|
+
div([
|
|
54
|
+
h1('Title'),
|
|
55
|
+
button('Save')
|
|
56
|
+
]);
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
---
|
|
60
|
+
|
|
61
|
+
## Core Features
|
|
62
|
+
|
|
63
|
+
- **Reactive State** — Built-in signals and effects (`Chex.signal`, `Chex.effect`)
|
|
64
|
+
- **VDOM Patching** — Efficient DOM updates via `Chex.render`
|
|
65
|
+
- **Zero-Dependency Routing** — Hash- or history-based routing with `Chex.createRouter`
|
|
66
|
+
- **Integrated Backend** — Built-in PHP database client (`Chex.db`) and API helpers
|
|
67
|
+
- **Standalone Helpers** — Additional engines for modals, skeleton loaders, sliders (`orbit`), and scroll animations (`rinx`, `scrollEcho`)
|
|
68
|
+
|
|
69
|
+
---
|
|
70
|
+
|
|
71
|
+
## Backend Database Engine
|
|
72
|
+
|
|
73
|
+
The optional `Chex.php` provides a secure PDO bridge for your frontend:
|
|
74
|
+
|
|
75
|
+
```js
|
|
76
|
+
const server = Chex.db.connect({
|
|
77
|
+
endpoint: '/path/to/Chex.php',
|
|
78
|
+
apiKey: 'YOUR_SECURE_API_KEY',
|
|
79
|
+
table: 'users'
|
|
80
|
+
});
|
|
81
|
+
|
|
82
|
+
await server.create({ email: 'demo@example.com' });
|
|
83
|
+
const users = await server.read({ select: ['id', 'email'], limit: 10 });
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
---
|
|
87
|
+
|
|
88
|
+
## Standalone Libraries
|
|
89
|
+
|
|
90
|
+
All included UI libraries are dependency-free:
|
|
91
|
+
|
|
92
|
+
| Library | Global | Purpose |
|
|
93
|
+
|---|---|---|
|
|
94
|
+
| `scrollEcho.js` | `ScrollEcho` | Scroll-triggered reveals |
|
|
95
|
+
| `racket.js` | `racket` | Image carousel |
|
|
96
|
+
| `orbit.js` | `orbit` | Swipe-friendly sliders |
|
|
97
|
+
| `rinx.js` | `rinx` | Scroll-card layouts |
|
|
98
|
+
| `smooth.js` | `smooth` | Continuous tickers |
|
|
99
|
+
| `modal.js` | `modal` | Accessible modal engine |
|
|
100
|
+
| `skeleton.js` | `skeleton` | Shimmer loaders |
|
|
101
|
+
|
|
102
|
+
---
|
|
103
|
+
|
|
104
|
+
## License
|
|
105
|
+
|
|
106
|
+
MIT License. Copyright (c) 2026 Aximon. Created by **Myxo Victor**.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@myxo-victor/chexjs",
|
|
3
|
-
"version": "6.0.
|
|
3
|
+
"version": "6.0.2",
|
|
4
4
|
"description": "A zero-build UI framework with reactive signals, VDOM diffing, routing, state, and a built-in PHP backend bridge — just a script tag, no compiler.",
|
|
5
5
|
"main": "Chex.js",
|
|
6
6
|
"keywords": ["ui", "framework", "vdom", "signals", "Chex", "chexjs"],
|
package/ChexJs/README.md
DELETED
|
@@ -1,121 +0,0 @@
|
|
|
1
|
-
# Chex 6.0.0
|
|
2
|
-
|
|
3
|
-
Chex is a lightweight JavaScript UI engine for fast, reactive, component-driven interfaces. It runs directly in the browser with no compiler or build step.
|
|
4
|
-
|
|
5
|
-
## Quick start
|
|
6
|
-
|
|
7
|
-
Include the engine, then write components with the tag helpers you need:
|
|
8
|
-
|
|
9
|
-
```html
|
|
10
|
-
<script src="./Chex.js"></script>
|
|
11
|
-
<script src="./components/main.js"></script>
|
|
12
|
-
```
|
|
13
|
-
|
|
14
|
-
```js
|
|
15
|
-
const { div, h1, button } = Chex;
|
|
16
|
-
const app = document.getElementById('app');
|
|
17
|
-
const count = Chex.signal(0);
|
|
18
|
-
|
|
19
|
-
const Counter = () => div({ class: 'counter' }, [
|
|
20
|
-
h1(`Count: ${count.value}`),
|
|
21
|
-
button({ onClick: () => (count.value += 1) }, 'Increment')
|
|
22
|
-
]);
|
|
23
|
-
|
|
24
|
-
Chex.render(app, Counter);
|
|
25
|
-
```
|
|
26
|
-
|
|
27
|
-
## Fast element API
|
|
28
|
-
|
|
29
|
-
Chex tag helpers accept props when you have them, and accept children directly when you do not:
|
|
30
|
-
|
|
31
|
-
```js
|
|
32
|
-
const { div, h1, button } = Chex;
|
|
33
|
-
|
|
34
|
-
// With props
|
|
35
|
-
div({ class: 'hero' }, [
|
|
36
|
-
h1({}, 'Title'),
|
|
37
|
-
button({ onClick: save }, 'Save')
|
|
38
|
-
]);
|
|
39
|
-
|
|
40
|
-
// No empty props object required
|
|
41
|
-
div([
|
|
42
|
-
h1('Title'),
|
|
43
|
-
button('Save')
|
|
44
|
-
]);
|
|
45
|
-
```
|
|
46
|
-
|
|
47
|
-
You can also use `Chex.div(...)`, `Chex.h1(...)`, and any standard HTML tag directly.
|
|
48
|
-
|
|
49
|
-
## Core features
|
|
50
|
-
|
|
51
|
-
- Fast VNode rendering and DOM patching with `Chex.render(...)`
|
|
52
|
-
- Concise tag helpers and custom-tag support
|
|
53
|
-
- Signals and effects: `Chex.signal(...)`, `Chex.effect(...)`
|
|
54
|
-
- Hash or history routing with `Chex.createRouter(...)`
|
|
55
|
-
- Fetch and cached query helpers through `Chex.api`
|
|
56
|
-
- Secure PHP database client through `Chex.db`
|
|
57
|
-
- Notifications, service-worker registration, and animation helpers
|
|
58
|
-
- Reusable UI components: Button, Input, AppBar, SideBar, BottomNav, and Card
|
|
59
|
-
|
|
60
|
-
## Backend database engine
|
|
61
|
-
|
|
62
|
-
`Chex.php` is the optional secure PHP/PDO endpoint used by `Chex.db.connect(...)`.
|
|
63
|
-
|
|
64
|
-
```js
|
|
65
|
-
const server = Chex.db.connect({
|
|
66
|
-
endpoint: '/Chex.php',
|
|
67
|
-
apiKey: 'YOUR_SECURE_API_KEY',
|
|
68
|
-
table: 'users'
|
|
69
|
-
});
|
|
70
|
-
|
|
71
|
-
await server.create({ email: 'demo@example.com' });
|
|
72
|
-
const users = await server.read({ select: ['id', 'email'], limit: 10 });
|
|
73
|
-
```
|
|
74
|
-
|
|
75
|
-
Open `Chex.php` to set database credentials, allowed origins, allowed tables, and the API key. The client sends the key in the `X-Chex-Key` header.
|
|
76
|
-
|
|
77
|
-
`Chex_notify.php` receives browser notification registrations. Pair it with `Chex.notification.ask('/Chex_notify.php')` when notifications are enabled.
|
|
78
|
-
|
|
79
|
-
## Included libraries
|
|
80
|
-
|
|
81
|
-
All libraries are standalone and dependency-free. Load them after `Chex.js` when needed.
|
|
82
|
-
|
|
83
|
-
| File | Global | Purpose |
|
|
84
|
-
| --- | --- | --- |
|
|
85
|
-
| `scrollEcho.js` | `ScrollEcho` | Scroll-triggered text and element reveals. |
|
|
86
|
-
| `racket.js` | `racket` | Responsive multi-panel image carousel. |
|
|
87
|
-
| `orbit.js` | `orbit` | Swipe-friendly banner and slider helper. |
|
|
88
|
-
| `rinx.js` | `rinx` | Horizontal and vertical scroll-card layouts. |
|
|
89
|
-
| `smooth.js` | `smooth` | Continuous ticker and infinite carousel. |
|
|
90
|
-
| `modal.js` | `modal` | Self-styling, zero-dependency accessible modal engine. |
|
|
91
|
-
| `skeleton.js` | `skeleton` | DOM-to-skeleton shimmer loader that reduces layout shift. |
|
|
92
|
-
|
|
93
|
-
Example:
|
|
94
|
-
|
|
95
|
-
```html
|
|
96
|
-
<script src="./Chex.js"></script>
|
|
97
|
-
<script src="./libs/modal.js"></script>
|
|
98
|
-
<script src="./libs/skeleton.js"></script>
|
|
99
|
-
```
|
|
100
|
-
|
|
101
|
-
## Project structure
|
|
102
|
-
|
|
103
|
-
```text
|
|
104
|
-
ChexJs/
|
|
105
|
-
Chex.js Core engine
|
|
106
|
-
Chex.php Optional PHP/PDO backend
|
|
107
|
-
Chex_notify.php Notification registration endpoint
|
|
108
|
-
components/ Page components and views
|
|
109
|
-
libs/ Standalone visual and UI helpers
|
|
110
|
-
index.html Welcome page launcher
|
|
111
|
-
index.css Welcome page styles
|
|
112
|
-
sw.js Service worker
|
|
113
|
-
```
|
|
114
|
-
|
|
115
|
-
## Documentation
|
|
116
|
-
|
|
117
|
-
Open `docs/index.html` through a local web server for the full API, component, backend, library, and example guides.
|
|
118
|
-
|
|
119
|
-
## License
|
|
120
|
-
|
|
121
|
-
MIT License. Copyright (c) 2026 Aximon. Created by Myxo Victor.
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/{ChexJs/sw.js → sw.js}
RENAMED
|
File without changes
|