# @wiajs/base

> wia app base lib, included by index.html

Latest version **1.2.5** (published 2025-01-25) · ELv2 license · 0 weekly downloads

## Install

```sh
npm install @wiajs/base
pnpm add @wiajs/base
yarn add @wiajs/base
bun add @wiajs/base
```

## Health

**Score 35/100 (D)** — status: maintenance-mode.

Positive: has types; esm support; no vulnerabilities.

Warnings: low downloads.

Negative: stale; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.2.5 |
| Published | 2025-01-25 |
| First published | 2020-03-07 |
| Weekly downloads | 0 |
| License | ELv2 |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 0 |
| Unpacked size | 196 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 20 |
| Author | Sibyl Yu |
| Maintainers | sibylyu, walteryu |
| Keywords | wia, base |

## Links

- npm: https://www.npmjs.com/package/@wiajs/base
- Repository: https://github.com/wiajs/wia
- Homepage: https://www.wia.pub/base
- Issues: https://github.com/wiajs/base/issues
- npm.io page: https://npm.io/package/@wiajs/base

## Alternatives

- [flatbuffers](https://npm.io/package/flatbuffers.md) — 6.0M weekly downloads
- [jwt-simple](https://npm.io/package/jwt-simple.md) — 259.5K weekly downloads
- [@exodus/patch-broken-hermes-typed-arrays](https://npm.io/package/@exodus/patch-broken-hermes-typed-arrays.md) — 28.5K weekly downloads
- [@native-to-anchor/buffer-layout](https://npm.io/package/@native-to-anchor/buffer-layout.md) — 12.2K weekly downloads
- [binary-parser-encoder](https://npm.io/package/binary-parser-encoder.md) — 5.3K weekly downloads

## Recent versions

- 1.2.5 (latest) — 2025-01-25
- 1.2.3 — 2025-01-13
- 1.1.0 — 2023-10-08
- 1.0.9 — 2023-09-12
- 1.0.8 — 2023-08-06
- 1.0.7 — 2023-08-05
- 1.0.6 — 2023-07-20
- 1.0.5 — 2023-07-17
- 1.0.4 — 2023-07-16
- 1.0.3 — 2023-07-14
- 1.0.2 — 2023-07-14
- 1.0.1 — 2023-07-06
- 0.1.17 — 2021-11-14
- 0.1.16 — 2021-08-10
- 0.1.15 — 2021-08-02
- … 13 more at https://npm.io/package/@wiajs/base/versions

## README

English | [Chinese](./README.CN.md)

# base

## wia's base module

@wiajs/base - is the base modules of [wia](https://www.wia.pub). Base must included by index.html.

```html
<script src="index.js"></script>
```

See [wia base](https://www.wia.pub/doc/base.html) documentation for usage examples and available methods.

## Build

You will need Node.js installed on your system.

First, install all required dependencies

```bash
$ npm install
```

To build production (minified) version:

```bash
$ npm run build

> @wiajs/base@1.0.1 build
> cross-env NODE_ENV=production gulp build

env:production src:./src out:./dist
[09:05:38] Using gulpfile D:\prj\wiajs\wia\packages\base\gulpfile.js
[09:05:38] Starting 'build'...
[09:05:38] Starting 'clean'...
[09:05:38] Finished 'clean' after 45 ms
[09:05:38] Starting '<anonymous>'...
start build ...
dist\base.cmn.js 47.62kb
dist\base.js 39.49kb
dist\base.esm.js 47.61kb
[09:05:45] Finished '<anonymous>' after 7.41 s
[09:05:45] Finished 'build' after 7.47 s
dist\base.min.js 22.40kb (gzipped: 7.56kb)
build { spend: 7995 }
```

The resulting files are:

1. common: dist/base.cmn.js
2. esm: dist/base.esm.js
3. umd: dist/base.js
4. umd min: dist/base.min.js

To build development version:

```bash
$ npm run build-dev
```

The resulting files are:

1. dist/base.cmn.js
2. dist/base.cmn.js.map
3. dist/base.esm.js
4. dist/base.esm.js.map
5. dist/base.js
6. dist/base.js.map
7. dist/base.min.js

## License

[ELv2](https://www.elastic.co/cn/licensing/elastic-license)

Copyright (c) 2020-present Sibyl Yu

---
_Source: https://npm.io/package/@wiajs/base · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
