Welcome to the rnxJS Samples repository! This collection showcases the power and flexibility of rnxJS - The Bootstrap-Native Framework for Production Apps.
rnxJS is a lightweight (~10KB gzipped), zero-build framework that brings reactive programming to Bootstrap applications. Perfect for backend developers (Django, Rails, Laravel, Express) and internal tools.
- β Zero Build Required - No Webpack, no bundlers, just HTML and JS
- β 46+ Components - Production-ready Bootstrap & Material Design components
- β Reactive State - Proxy-based reactivity with automatic UI updates
- β
Two-Way Binding - Built-in
data-bindfor forms and elements - β Form Validation - Built-in validation rules
- β Backend Integration - Official packages for Django, Express, Rails, Laravel
rnxJS_samples/
βββ index.html # Landing page with all demos
βββ dashboard.html # Admin dashboard demo
βββ shop.html # E-commerce product catalog
βββ forms.html # Form validation demo
βββ datatable.html # Data table with sorting/filtering
βββ tasks.html # Task manager (todo app)
βββ chat.html # Chat interface
βββ settings.html # Settings panel
βββ styles.css # Shared custom styles
βββ django-demo/ # Django integration demo
β βββ README.md
βββ express-demo/ # Express.js integration demo
β βββ README.md
βββ README.md # This file
All standalone demos are copy-paste ready and require no build step. They load a pinned rnxJS build (2.3.1) from jsDelivr, so open them in a browser with an internet connection.
- Overview of all demos
- Quick start guide
- Resource links
- Real-time stat cards
- User management table
- Activity feed
- Search and filtering
Components Used: StatCard, DataTable, Input, Button, Card
- Product catalog with images
- Category and price filtering
- Shopping cart with sidebar
- Reactive cart totals
Components Used: Card, Badge, Modal, Search, Select, Button
- Multi-step form
- Built-in validation rules
- File upload
- Real-time error messages
Components Used: Input, Textarea, Select, Checkbox, Radio, Switch, FileUpload
- Sortable columns
- Search and filtering
- Pagination
- Row actions (edit/delete)
Components Used: DataTable, Search, Pagination, Dropdown
- Add/edit/delete tasks
- Status tracking (todo, in progress, done)
- Filtering by status
- Due date management
Components Used: List, Checkbox, FAB, Chips, DatePicker, Tabs
- Real-time message list
- Send/receive messages
- Toast notifications
- Auto-scroll to latest message
Components Used: List, Input, Toast, Button
- Theme switching (light/dark)
- Tabbed interface
- Slider controls
- Accordion sections
Components Used: Tabs, Switch, Slider, Select, Accordion, Sidebar
Complete Django project demonstrating @arnelirobles/django-rnx integration.
Features:
- Django template tags (
{% rnx_scripts %},{% rnx_state %},{% rnx_component %}) - Form integration with Django forms
- Reactive state from Django context
- Plugin usage (router, toast, storage)
Setup:
cd django-demo
pip install -r requirements.txt
python manage.py runserverSee django-demo/README.md for detailed instructions.
Complete Express.js project demonstrating @arnelirobles/express-rnx integration.
Features:
- EJS view helpers (
rnx.scripts(),rnx.state(),rnx.component()) - Reactive state from server data
- Component rendering in templates
- Middleware configuration
Setup:
cd express-demo
npm install
npm startSee express-demo/README.md for detailed instructions.
Open any .html file in your browser. No server and no build step. The page loads rnxJS 2.3.1 from jsDelivr, so you need to be online.
# macOS
open index.html
# Linux
xdg-open index.html
# Windows
start index.htmlFor a better development experience:
# Using Python
python -m http.server 8000
# Using Node.js (http-server)
npx http-server
# Using PHP
php -S localhost:8000Then visit http://localhost:8000
- Official Documentation: GitHub - BaryoDev/rnxjs
- npm Package: @arnelirobles/rnxjs
- CLI Tool: @arnelirobles/create-rnxjs-app
- Django Integration: @arnelirobles/django-rnx
- Express Integration: @arnelirobles/express-rnx
All demos use a shared styles.css file with modern styling including:
- Glassmorphism effects
- Gradient backgrounds
- Smooth animations
- Responsive design
- Custom scrollbars
Feel free to modify styles.css to match your brand!
<!DOCTYPE html>
<html>
<head>
<!-- Bootstrap CSS -->
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css" rel="stylesheet">
<!-- Bootstrap Icons -->
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.11.3/font/bootstrap-icons.min.css">
</head>
<body>
<Container>
<h1 data-bind="message"></h1>
<Input data-bind="message" placeholder="Type something..." />
<Button label="Click Me" variant="primary" onclick="alert(state.message)" />
</Container>
<!-- rnxJS Library -->
<script src="https://cdn.jsdelivr.net/npm/@arnelirobles/rnxjs@2.3.1/dist/rnx.global.js"></script>
<script>
const { createReactiveState, autoRegisterComponents, loadComponents } = rnx;
const state = createReactiveState({
message: 'Hello, rnxJS!'
});
autoRegisterComponents();
loadComponents(document.body, state);
</script>
</body>
</html>npm install @arnelirobles/rnxjsimport { createReactiveState, autoRegisterComponents, loadComponents } from '@arnelirobles/rnxjs';
import '@arnelirobles/rnxjs/css/bootstrap-m3-theme.css'; // Optional M3 theme
const state = createReactiveState({ count: 0 });
autoRegisterComponents();
loadComponents(document.body, state);npx @arnelirobles/create-rnxjs-app@latestFound a bug or have a suggestion? Please open an issue on the main rnxJS repository.
These samples are provided under the MIT License - feel free to use them in your projects!
The rnxJS library itself is licensed under MPL-2.0.
- Start Simple: Begin with
index.htmlto understand the basics - Explore Components: Check
dashboard.htmlfor component variety - Learn Reactivity:
shop.htmldemonstrates reactive cart management - Backend Integration: Try
django-demo/orexpress-demo/for full-stack apps - Customize: Modify
styles.cssto match your design system
| Feature | rnxJS | jQuery | Vue 3 | React 18 |
|---|---|---|---|---|
| Bundle Size | ~10KB | ~30KB | ~16KB | ~42KB |
| Zero Build | β Yes | β Yes | β Required | |
| Components | 46 | 0 | 0 | 0 |
| Two-Way Binding | β Built-in | β Manual | β v-model | β Manual |
| Form Validation | β Built-in | β Plugin | β Library | β Library |
| Learning Curve | 1 hour | 1 hour | 1 day | 1 week |
- GitHub Issues: BaryoDev/rnxjs/issues
- GitHub Discussions: BaryoDev/rnxjs/discussions
Built with β€οΈ by BaryoDev
Enjoy exploring rnxJS! π