Ecosyste.ms: Awesome

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

Awesome Lists | Featured Topics | Projects

https://github.com/vuquangpham/boilw

Creating Javascript library on the fly 💫
https://github.com/vuquangpham/boilw

boil-collections boilerplate javascript webpack

Last synced: about 1 month ago
JSON representation

Creating Javascript library on the fly 💫

Awesome Lists containing this project

README

        

# Boilw Template

> Creating Javascript library on the fly 💫

## Getting started

### Options

| Name | Default | Description |
| -------------------- | ---------- | ------------------------------- |
| `id` | `unique` | id for clarifying each instance |
| --- | -- | -- |
| `events(self) => {}` | `function` | |

### Methods of Grab

| Name | Parameter | Description |
| --------- | ---------- | -------------------- |
| `create` | `object` | create the instance |
| `get` | `id` | get the instance |
| `destroy` | `instance` | destroy the instance |

### Methods of instance

| Name | Parameters | |
| --------- | ------------------ | ---------------- |
| `on` | `(name, callback)` | trigger events |
| `destroy` | `()` | destroy instance |

## Deployment

Run `./dev` in live server

```shell
npm run dev
```

Build files from `./src` to `./dist` for production

```shell
npm run prod
```

Build files from `./src` and `./dev` to `./dist` for production

```shell
npm run build
```