# @heyoo/packs-js-template

> heyoo's packs javascript template

Latest version **1.0.0** (published 2021-09-16) · MIT license · 0 weekly downloads

## Install

```sh
npm install @heyoo/packs-js-template
pnpm add @heyoo/packs-js-template
yarn add @heyoo/packs-js-template
bun add @heyoo/packs-js-template
```

## Health

**Score 20/100 (F)** — status: abandoned.

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2021-09-16 |
| First published | 2021-09-16 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM |
| Node | ^12.20.0 \|\| ^14.13.1 \|\| >=16.0.0 |
| Dependencies | 0 |
| Unpacked size | 2.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Haolin |
| Maintainers | aircan |

## Links

- npm: https://www.npmjs.com/package/@heyoo/packs-js-template
- Repository: https://github.com/hey-yoo/heyoo-template
- Homepage: https://github.com/hey-yoo/heyoo-template/tree/packs-js-template#readme
- Issues: https://github.com/hey-yoo/heyoo-template/issues
- npm.io page: https://npm.io/package/@heyoo/packs-js-template

## Recent versions

- 1.0.0 (latest) — 2021-09-16

## README

# @heyoo/packs-js-template

This project is the [heyoo](https://github.com/hey-yoo/heyoo) Command line tool's packs template with javascript.

Before go on, you must install [heyoo](https://github.com/hey-yoo/heyoo) in global.

## Usage

in the project you want to use a heyoo packs, create a heyoo config file(`hey.config.js` or `hey.config.json`):

```javascript
// hey.config.js
export default {
  packs: '@heyoo/packs-js-template'
}
```

then install:

```shell
pnpm add @heyoo/packs-js-template
# or
npm i @heyoo/packs-js-template
# or
yarn add @heyoo/packs-js-template
```

exec the exports script:

```shell
hey run foo
# or
hey run bar
```

## Develop packs template

```shell
hey create packs
# choose packs-js-template and follow the other prompts

# the packsName is what you input by prompts
cd ./packsName

hey link
```

build package code:

```shell
<packageManager> run build
```

watch directory ./src, when update will rebuild:

```shell
<packageManager> run watch
```
packageManager can be one of `pnpm`, `npm`, `yarn`.

### Notice

* package.json must have `exports` attribute, it must look like:

```json5
{
  "type": "module",
  "exports": {
    // you can know more on [Package entry points](https://nodejs.org/api/packages.html#packages_package_entry_points)
    "./foo": "./bin/foo.js",
    "./bar": "./bin/bar.js"
  }
}
```

* exports targets must export default a function.

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