open-index/open-npm huggingface dataset:
npm package: @jqhtml/core
Description: Core runtime library for JQHTML
Author: JQHTML Team
Latest version: 2.3.35

# @jqhtml/core

A jQuery-based component framework for people who think in systems, not pixels.

```html
<Define:User_Card class="card">
  <h3><%= this.data.name %></h3>
  <p><%= this.data.email %></p>
</Define:User_Card>
```

Components have a simple lifecycle: `on_load()` fetches data, `on_render()` sets up the DOM, `on_ready()` fires when everything's ready. No virtual DOM, no complex state management - just jQuery under the hood.

**vs React/Vue:** JQHTML is for when you want component structure without the SPA complexity. Great for server-rendered apps (Laravel, Rails, Django) where you need interactive islands, not a full frontend framework.

## Status

Alpha release. It works and I use it daily, but expect rough edges. Full documentation and framework plugins coming soon.

If you try it in a project, I'd love to hear about it.

---

**hansonxyz** · [hanson.xyz](https://hanson.xyz/) · [github](https://github.com/hansonxyz)
npm package: @jqhtml/parser
Description: JQHTML template parser - converts templates to JavaScript
Author: JQHTML Team
Latest version: 2.3.35

# @jqhtml/parser

Compiles `.jqhtml` templates into JavaScript for the JQHTML component framework.

```bash
npx jqhtml-compile compile components/*.jqhtml -o bundle.js --sourcemap
```

Templates look like HTML with embedded JavaScript:

```html
<Define:Product_Card class="card">
  <h3><%= this.data.name %></h3>
  <% if (this.data.on_sale) { %>
    <span class="badge">Sale!</span>
  <% } %>
</Define:Product_Card>
```

The parser handles the template syntax - `<Define:>` blocks, `<%= %>` expressions, control flow, slots, event bindings. Output is JavaScript that the `@jqhtml/core` runtime understands.

## Status

Alpha release. Works well enough that I use it daily, but documentation is sparse and you might hit edge cases. Webpack loader and proper docs coming soon.

Found a bug or built something cool? Drop me a line.

---

**hansonxyz** · [hanson.xyz](https://hanson.xyz/) · [github](https://github.com/hansonxyz)
npm package: @jqhtml/vite-plugin
Description: Vite plugin for jqhtml template compilation
Author: Brian Hanson
Latest version: 0.0.3

# @jqhtml/vite-plugin

Vite plugin for compiling `.jqhtml` templates to JavaScript.

## Installation

```bash
npm install @jqhtml/vite-plugin @jqhtml/core jquery
```

## Configuration

```javascript
// vite.config.js
import { defineConfig } from 'vite';
import jqhtml from '@jqhtml/vite-plugin';

export default defineConfig({
    plugins: [
        jqhtml(),
    ],
});
```

### Options

```javascript
jqhtml({
    include: ['**/*.jqhtml'],    // Glob patterns to include
    exclude: ['node_modules/**'], // Glob patterns to exclude
    sourcemap: true,              // Enable source maps (default: true in dev)
})
```

## Usage

### 1. Set up your entry point

```javascript
// main.js
import $ from 'jquery';
window.jQuery = window.$ = $;

import jqhtml, { boot, init_jquery_plugin } from '@jqhtml/core';
init_jquery_plugin($);

// Import and register components
import MyComponent from './components/MyComponent.jqhtml';
jqhtml.register(MyComponent);

// Boot when DOM is ready
$(document).ready(async () => {
    await boot();
});
```

### 2. Create components

```html
<!-- components/MyComponent.jqhtml -->
<Define:MyComponent tag="div" class="my-component">
    <h2><%= this.args.title %></h2>
    <p><%= this.args.message %></p>
</Define:MyComponent>
```

### 3. Use in HTML

```html
<div class="_Component_Init"
     data-component-init-name="MyComponent"
     data-component-args='{"title":"Hello","message":"World"}'>
</div>
```

The `boot()` function finds these placeholders and hydrates them into live components.

## Framework Integrations

- **Laravel**: Use [jqhtml/laravel](https://github.com/jqhtml/jqhtml-laravel) for Blade template support
- **WordPress**: Coming soon

## Documentation

For complete documentation including template syntax, lifecycle methods, and component patterns:

**https://jqhtml.org/**

## License

MIT - Copyright (c) hansonxyz