An open API service indexing awesome lists of open source software.

https://github.com/arazjs/core

Araz.js is a mini framework that provides a simple and intuitive API for building web applications. It is inspired by popular frameworks like React and Vue.js, but with a focus on simplicity and ease of use.
https://github.com/arazjs/core

framework javascript typescript

Last synced: 3 months ago
JSON representation

Araz.js is a mini framework that provides a simple and intuitive API for building web applications. It is inspired by popular frameworks like React and Vue.js, but with a focus on simplicity and ease of use.

Awesome Lists containing this project

README

          

# Araz.js

Araz.js is a mini framework that provides a simple and intuitive API for building web applications. It is inspired by popular frameworks like React and Vue.js, but with a focus on simplicity and ease of use.

## Installation

To install Araz.js, simply run the following command in your terminal:

```
npm install araz
```

## Usage

Araz.js is a component-based framework, which means that your application is built by composing reusable components. Each component is a self-contained unit that has its own state and logic.

To create a component, you can use the `el()` function. This function takes an object with three properties: `$tag`, `$attrs`, and `$children`.

* `$tag` is the HTML tag name of the component.
* `$attrs` is an object containing the attributes of the component.
* `$children` is an array of child components.

For example, the following code creates a simple button component:

```
const button = el(
'button',
{
type: 'button',
class: 'btn btn-primary',
},
'Click me',
);
```

Once you have created a component, you can mount it to the DOM using the `mount()` function. This function takes two arguments: the component to be mounted, and the target element in the DOM.

For example, the following code mounts the button component to the `` element:

```
mount({
$node: button,
$target: document.body,
});
```

Araz.js includes a simple router that allows

Generated by [BlackboxAI](https://www.useblackbox.ai)