open-index/open-npm huggingface dataset:
npm package: @jswork/case-kit
Description: Convert strings between camel, snake, kebab, pascal, and other cases.
Latest version: 1.0.1

# case-kit
> Convert strings between camel, snake, kebab, pascal, and other cases.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
yarn add @jswork/case-kit
```

## usage
```js
import CaseKit from '@jswork/case-kit';

// Convert to camelCase
CaseKit.camelCase('change_format_to_this'); 
// Output: 'changeFormatToThis'

// Convert to snake_case
CaseKit.snakeCase('changeFormatToThis'); 
// Output: 'change_format_to_this'

// Convert to kebab-case
CaseKit.kebabCase('ChangeFormatToThis'); 
// Output: 'change-format-to-this'

// Convert to PascalCase
CaseKit.pascalCase('change_format_to_this'); 
// Output: 'ChangeFormatToThis'

// Convert to CONSTANT_CASE
CaseKit.constantCase('changeFormatToThis'); 
// Output: 'CHANGE_FORMAT_TO_THIS'

// Convert to dot.case
CaseKit.dotCase('changeFormatToThis'); 
// Output: 'change.format.to.this'

// Convert to path/case
CaseKit.pathCase('changeFormatToThis'); 
// Output: 'change/format/to/this'

// Convert to sentence case
CaseKit.sentenceCase('CHANGE_FORMAT_TO_THIS'); 
// Output: 'Change format to this'

// Convert to Title Case
CaseKit.titleCase('change_format_to_this'); 
// Output: 'Change Format To This'
```

## license
Code released under [the MIT license](https://github.com/afeiship/case-kit/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/case-kit
[version-url]: https://npmjs.org/package/@jswork/case-kit

[license-image]: https://img.shields.io/npm/l/@jswork/case-kit
[license-url]: https://github.com/afeiship/case-kit/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/case-kit
[size-url]: https://github.com/afeiship/case-kit/blob/master/dist/case-kit.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/case-kit
[download-url]: https://www.npmjs.com/package/@jswork/case-kit
npm package: @jswork/check-modules
Description: Check node modules or log to user.
Author: afei
Latest version: 1.0.2

<p align="center">
  <a href="https://github.com/afeiship/check-modules">
    <img width="880" src="https://tva1.sinaimg.cn/large/006tNbRwly1ga6lp3ot8vj30oy078jsg.jpg">
  </a>
</p>

# check-modules
> Check node modules or log to user.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]


## installation
```shell
npm install -S @jswork/check-modules
```

## usage
```js
var checkModules = require('check-modules');

var res = checkModules(['gulp','react','react-dom','@jswork/react-ant-tree']);

// true
// false with warning
```

## license
Code released under [the MIT license](https://github.com/afeiship/check-modules/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/check-modules
[version-url]: https://npmjs.org/package/@jswork/check-modules

[license-image]: https://img.shields.io/npm/l/@jswork/check-modules
[license-url]: https://github.com/afeiship/check-modules/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/check-modules
[size-url]: https://github.com/afeiship/check-modules/blob/master/dist/check-modules.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/check-modules
[download-url]: https://www.npmjs.com/package/@jswork/check-modules
npm package: @jswork/check-resource
Description: Check resource exists.
Latest version: 1.0.1

# check-resource
> Check resource exists.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
yarn add @jswork/check-resource
```

## usage
```js
import checkResource from '@jswork/check-resource';

async function example() {
  // Check a valid resource
  const validUrl = 'https://web-assets.alo7.com/assets/text/hello.txt'; // Replace with a known existing URL
  const validExists = await checkResource(validUrl);
  console.log(`Does ${validUrl} exist? ${validExists}`); // Expected output: Does ... exist? true

  // Check an invalid resource
  const invalidUrl = 'https://web-assets.alo7.com/assets/text/not-exists.txt'; // Replace with a known non-existing URL
  const invalidExists = await checkResource(invalidUrl);
  console.log(`Does ${invalidUrl} exist? ${invalidExists}`); // Expected output: Does ... exist? false
}

example();
```

## license
Code released under [the MIT license](https://github.com/afeiship/check-resource/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/check-resource
[version-url]: https://npmjs.org/package/@jswork/check-resource

[license-image]: https://img.shields.io/npm/l/@jswork/check-resource
[license-url]: https://github.com/afeiship/check-resource/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/check-resource
[size-url]: https://github.com/afeiship/check-resource/blob/master/dist/check-resource.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/check-resource
[download-url]: https://www.npmjs.com/package/@jswork/check-resource
npm package: @jswork/ci-kits
Description: Streamlined CI/CD tools.
Latest version: 1.0.4

# ci-kits
> Streamlined CI/CD tools.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/ci-kits
```

## usage
```js
import { envname } from '@jswork/ci-kits';

// getenv name:
const envName = envname(); // beta/dev
```

## license
Code released under [the MIT license](https://github.com/afeiship/ci-kits/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/ci-kits
[version-url]: https://npmjs.org/package/@jswork/ci-kits

[license-image]: https://img.shields.io/npm/l/@jswork/ci-kits
[license-url]: https://github.com/afeiship/ci-kits/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/ci-kits
[size-url]: https://github.com/afeiship/ci-kits/blob/master/dist/ci-kits.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/ci-kits
[download-url]: https://www.npmjs.com/package/@jswork/ci-kits
npm package: @jswork/class-imperative-handle
Description: React `useImperativeHandle` for class component.
Latest version: 1.0.1

# class-imperative-handle
> React `useImperativeHandle` for class component.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/class-imperative-handle
```

## usage
```js
import classImperativeHandle from '@jswork/class-imperative-handle';

class MyComponent extends Component {
  handleRef = (inRoot) => {
    const { forwardedRef } = this.props;
    classImperativeHandle(forwardedRef, inRoot);
    this.root = inRoot;
  };

  render() {
    return (
      <div
        ref={this.handleRef}
        {...this.props}
      />
    );
  }
}
```

## license
Code released under [the MIT license](https://github.com/afeiship/class-imperative-handle/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/class-imperative-handle
[version-url]: https://npmjs.org/package/@jswork/class-imperative-handle

[license-image]: https://img.shields.io/npm/l/@jswork/class-imperative-handle
[license-url]: https://github.com/afeiship/class-imperative-handle/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/class-imperative-handle
[size-url]: https://github.com/afeiship/class-imperative-handle/blob/master/dist/class-imperative-handle.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/class-imperative-handle
[download-url]: https://www.npmjs.com/package/@jswork/class-imperative-handle
npm package: @jswork/clipboard-image
Description: Read/write clipboard image.
Latest version: 1.0.1

# clipboard-image
> Read/write clipboard image.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/clipboard-image
```

## usage
```js
import ClipboardImage from '@jswork/clipboard-image';

// only testing on macos
const buf = ClipboardImage.read();

// <Buffer xxxx> OR null
```

## license
Code released under [the MIT license](https://github.com/afeiship/clipboard-image/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/clipboard-image
[version-url]: https://npmjs.org/package/@jswork/clipboard-image

[license-image]: https://img.shields.io/npm/l/@jswork/clipboard-image
[license-url]: https://github.com/afeiship/clipboard-image/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/clipboard-image
[size-url]: https://github.com/afeiship/clipboard-image/blob/master/dist/clipboard-image.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/clipboard-image
[download-url]: https://www.npmjs.com/package/@jswork/clipboard-image
npm package: @jswork/color-darken
Description: Darken for color.
Latest version: 1.0.1

# color-darken
> Darken for color.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/color-darken
```

## usage
```js
import colorDarken from '@jswork/color-darken';

// usage goes here.
```

## license
Code released under [the MIT license](https://github.com/afeiship/color-darken/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/color-darken
[version-url]: https://npmjs.org/package/@jswork/color-darken

[license-image]: https://img.shields.io/npm/l/@jswork/color-darken
[license-url]: https://github.com/afeiship/color-darken/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/color-darken
[size-url]: https://github.com/afeiship/color-darken/blob/master/dist/color-darken.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/color-darken
[download-url]: https://www.npmjs.com/package/@jswork/color-darken
npm package: @jswork/color-lighten
Description: Lighten for color.
Latest version: 1.0.1

# color-lighten
> Lighten for color.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/color-lighten
```

## usage
```js
import colorLighten from '@jswork/color-lighten';

// usage goes here.
```

## license
Code released under [the MIT license](https://github.com/afeiship/color-lighten/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/color-lighten
[version-url]: https://npmjs.org/package/@jswork/color-lighten

[license-image]: https://img.shields.io/npm/l/@jswork/color-lighten
[license-url]: https://github.com/afeiship/color-lighten/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/color-lighten
[size-url]: https://github.com/afeiship/color-lighten/blob/master/dist/color-lighten.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/color-lighten
[download-url]: https://www.npmjs.com/package/@jswork/color-lighten
npm package: @jswork/color-rgba
Description: Rgba for color.
Latest version: 1.0.1

# color-rgba
> Rgba for color.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/color-rgba
```

## usage
```js
import colorRgba from '@jswork/color-rgba';

// usage goes here.
```

## license
Code released under [the MIT license](https://github.com/afeiship/color-rgba/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/color-rgba
[version-url]: https://npmjs.org/package/@jswork/color-rgba

[license-image]: https://img.shields.io/npm/l/@jswork/color-rgba
[license-url]: https://github.com/afeiship/color-rgba/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/color-rgba
[size-url]: https://github.com/afeiship/color-rgba/blob/master/dist/color-rgba.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/color-rgba
[download-url]: https://www.npmjs.com/package/@jswork/color-rgba
npm package: @jswork/command-manager
Description: Core command manager.
Latest version: 1.2.1

# command-manager
> Core command manager.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/command-manager
```

## usage
```js
import commandManager from '@jswork/command-manager';

// usage goes here.
```

## types
```ts
/// <reference types="@jswork/command-manager/global.d.ts" />
```

## license
Code released under [the MIT license](https://github.com/afeiship/command-manager/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/command-manager
[version-url]: https://npmjs.org/package/@jswork/command-manager

[license-image]: https://img.shields.io/npm/l/@jswork/command-manager
[license-url]: https://github.com/afeiship/command-manager/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/command-manager
[size-url]: https://github.com/afeiship/command-manager/blob/master/dist/index.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/command-manager
[download-url]: https://www.npmjs.com/package/@jswork/command-manager
npm package: @jswork/concurrency-request
Description: An efficiently handles asynchronous data requests with customizable concurrency limit.
Latest version: 1.0.4

# concurrency-request
> An efficiently handles asynchronous data requests with customizable concurrency limit.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/concurrency-request
```

## usage
```js
import ConcurrencyRequest from '@jswork/concurrency-request';

const urls = [];
for (let i = 1; i <= 10; i++) {
  urls.push(`https://jsonplaceholder.typicode.com/todos/${i}`);
}

function request(opts, callback) {
  fetch(opts.data)
    .then((r) => r.json())
    .then((data) => {
      callback({ success: true, data });
    })
    .catch((data) => {
      callback({ success: false, data });
    });
}

ConcurrencyRequest.start(urls, { max: 3, request }).then((res) => {
  console.log(res);
});
```

## license
Code released under [the MIT license](https://github.com/afeiship/concurrency-request/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/concurrency-request
[version-url]: https://npmjs.org/package/@jswork/concurrency-request

[license-image]: https://img.shields.io/npm/l/@jswork/concurrency-request
[license-url]: https://github.com/afeiship/concurrency-request/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/concurrency-request
[size-url]: https://github.com/afeiship/concurrency-request/blob/master/dist/index.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/concurrency-request
[download-url]: https://www.npmjs.com/package/@jswork/concurrency-request
npm package: @jswork/config-query
Description: A flexible library for dynamic queries on configuration objects with customizable filters.
Latest version: 1.0.6

# config-query
> A flexible library for dynamic queries on configuration objects with customizable filters.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/config-query
```

## usage
```js
import ConfigQuery from '@jswork/config-query';

const configs = [
  {
    school_level: null,
    language: "zh-CN",
    key: "yes_or_no",
    value: [
      { label: "是", value: "yes" },
      { label: "否", value: "no" },
    ],
  },
  {
    school_level: null,
    language: "en-US",
    key: "yes_or_no",
    value: [
      { label: "Yes", value: "yes" },
      { label: "No", value: "no" },
    ],
  },
];

const query = new ConfigQuery(configs);

// select by key
const yes_no_items = query.select({ key: "yes_or_no" });
console.log(yes_no_items);


/* ------------------------------ output ------------------------------
 *  [
 *    {
 *      "school_level": null,
 *      "language": "zh-CN",
 *      "key": "yes_or_no",
 *      "value": [
 *        { "label": "是", "value": "yes" },
 *        { "label": "否", "value": "no" }
 *      ]
 *    },
 *    {
 *      "school_level": null,
 *      "language": "en-US",
 *      "key": "yes_or_no",
 *      "value": [
 *        { "label": "Yes", "value": "yes" },
 *        { "label": "No", "value": "no" }
 *      ]
 *    }
 *  ]
 */


// get by language
const en = query.find({ language: "en-US" });
console.log(en);

/* ------------------------------ output ------------------------------
 *   {
 *     "school_level": null,
 *     "language": "en-US",
 *     "key": "yes_or_no",
 *     "value": [
 *       { "label": "Yes", "value": "yes" },
 *       { "label": "No", "value": "no" }
 *     ]
 *   }
 */


// value filter
const yes = query.value({ key: "yes_or_no", "language": "zh-CN" });
console.log(yes);


/* ------------------------------ output ------------------------------
 *  [ 
 *    { "label": "是", "value": "yes" },
 *    { "label": "否", "value": "no" }
 *  ]
 */
```

## license
Code released under [the MIT license](https://github.com/afeiship/config-query/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/config-query
[version-url]: https://npmjs.org/package/@jswork/config-query

[license-image]: https://img.shields.io/npm/l/@jswork/config-query
[license-url]: https://github.com/afeiship/config-query/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/config-query
[size-url]: https://github.com/afeiship/config-query/blob/master/dist/index.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/config-query
[download-url]: https://www.npmjs.com/package/@jswork/config-query
npm package: @jswork/copy-selection-element
Description: Copy html from selection element.
Latest version: 1.0.1

# copy-selection-element
> Copy html from selection element.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/copy-selection-element
```

## usage
```js
import copySelectionElement from "@jswork/copy-selection-element";

const el = document.querySelector(".content");
const successful = copySelectionElement(el);

if (successful) {
  // do somthing...
}
```

## license
Code released under [the MIT license](https://github.com/afeiship/copy-selection-element/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/copy-selection-element
[version-url]: https://npmjs.org/package/@jswork/copy-selection-element

[license-image]: https://img.shields.io/npm/l/@jswork/copy-selection-element
[license-url]: https://github.com/afeiship/copy-selection-element/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/copy-selection-element
[size-url]: https://github.com/afeiship/copy-selection-element/blob/master/dist/index.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/copy-selection-element
[download-url]: https://www.npmjs.com/package/@jswork/copy-selection-element
npm package: @jswork/cra-envs
Description: An env-cmd helper for cra.
Latest version: 1.0.15

# cra-envs
> An env-cmd helper for cra.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install -D env-cmd
npm install -S @jswork/cra-envs
```

## usage
- https://js.work/works/bd65bc9da65c5

```js
// ---------- package.json
"scripts": {
  "start": "env-cmd -e local react-scripts start",
  "build:beta": "env-cmd -e beta react-scripts build",
  "build:prod": "env-cmd -e prod react-scripts build",
  "test": "react-scripts test",
  "eject": "react-scripts eject"
}
```

```js
// ---------- .env-cmdrc.js
const CraEnvs = require('@jswork/cra-envs');

module.exports = CraEnvs.set({
  "local": {
    "API_URL": "http://localhost:3000",
    "BUILD_ENV": 'local-api.github.com/users/afeiship',
  },
  "beta": {
    "API_URL": "http://beta.api.com",
    "BUILD_ENV": 'beta-api.github.com/users/afeiship',
  },
  "production": {
    "API_URL": "http://api.com",
    "BUILD_ENV": 'api.github.com/users/afeiship',
  },
});

// ---------- src/app.tsx
// get 'BUILD_ENV'
const buildEnv = CraEnvs.get('BUILD_ENV');
// get all
const envs = CraEnvs.get();
```

## license
Code released under [the MIT license](https://github.com/afeiship/cra-envs/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/cra-envs
[version-url]: https://npmjs.org/package/@jswork/cra-envs

[license-image]: https://img.shields.io/npm/l/@jswork/cra-envs
[license-url]: https://github.com/afeiship/cra-envs/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/cra-envs
[size-url]: https://github.com/afeiship/cra-envs/blob/master/dist/cra-envs.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/cra-envs
[download-url]: https://www.npmjs.com/package/@jswork/cra-envs
npm package: @jswork/cra-tailwind-init
Description: Tailwind init for cra.
Latest version: 1.0.7

# cra-tailwind-init
> Tailwind init for cra.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/cra-tailwind-init
```

## usage
```js
import craTailwindInit from '@jswork/cra-tailwind-init';

// usage goes here.
```

## license
Code released under [the MIT license](https://github.com/afeiship/cra-tailwind-init/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/cra-tailwind-init
[version-url]: https://npmjs.org/package/@jswork/cra-tailwind-init

[license-image]: https://img.shields.io/npm/l/@jswork/cra-tailwind-init
[license-url]: https://github.com/afeiship/cra-tailwind-init/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/cra-tailwind-init
[size-url]: https://github.com/afeiship/cra-tailwind-init/blob/master/dist/cra-tailwind-init.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/cra-tailwind-init
[download-url]: https://www.npmjs.com/package/@jswork/cra-tailwind-init
npm package: @jswork/cra-template-js4
Description: cra template for javascript + craco + react-script@4.0.3.
Latest version: 1.0.2

# cra-template

This is the official base template for [Create React App](https://github.com/facebook/create-react-app).

If you don't specify a template (for example, `--template typescript`), this template will be used by default.

For more information, please refer to:

- [Getting Started](https://create-react-app.dev/docs/getting-started) – How to create a new app.
- [User Guide](https://create-react-app.dev) – How to develop apps bootstrapped with Create React App.
npm package: @jswork/craco-init
Description: Craco init.
Latest version: 1.0.8

# craco-init
> Craco init.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/craco-init
```

## usage
```js
import cracoInit from '@jswork/craco-init';

// usage goes here.
```

## license
Code released under [the MIT license](https://github.com/afeiship/craco-init/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/craco-init
[version-url]: https://npmjs.org/package/@jswork/craco-init

[license-image]: https://img.shields.io/npm/l/@jswork/craco-init
[license-url]: https://github.com/afeiship/craco-init/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/craco-init
[size-url]: https://github.com/afeiship/craco-init/blob/master/dist/craco-init.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/craco-init
[download-url]: https://www.npmjs.com/package/@jswork/craco-init
npm package: @jswork/craco-plugin-alias
Description: Alias plugin for craco.
Latest version: 1.0.4

# craco-plugin-alias
> Alias plugin for craco.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/craco-plugin-alias
```

## usage
```js
import cracoPluginAlias from '@jswork/craco-plugin-alias';

// usage goes here.
```

## license
Code released under [the MIT license](https://github.com/afeiship/craco-plugin-alias/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/craco-plugin-alias
[version-url]: https://npmjs.org/package/@jswork/craco-plugin-alias

[license-image]: https://img.shields.io/npm/l/@jswork/craco-plugin-alias
[license-url]: https://github.com/afeiship/craco-plugin-alias/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/craco-plugin-alias
[size-url]: https://github.com/afeiship/craco-plugin-alias/blob/master/dist/craco-plugin-alias.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/craco-plugin-alias
[download-url]: https://www.npmjs.com/package/@jswork/craco-plugin-alias
npm package: @jswork/craco-plugin-banner
Description: Carco plugin for banner.
Latest version: 1.0.8

# craco-plugin-banner
> Carco plugin for banner.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/craco-plugin-banner
```

## usage
```js
import cracoPluginBanner from '@jswork/craco-plugin-banner';

// craco.config.js
modlue.exports = {
  plugins: [
    { 
      plugin: cracoPluginBanner, 
      options: {
        banner:[
          'NAME: editor-frontend',
          'VERSION: v1.1.5-alpha.6',
          'BUILD_TIME: 4/12/2019, 11:01:20 PM'
        ]
      } 
    }
  ],
};
```

## license
Code released under [the MIT license](https://github.com/afeiship/craco-plugin-banner/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/craco-plugin-banner
[version-url]: https://npmjs.org/package/@jswork/craco-plugin-banner

[license-image]: https://img.shields.io/npm/l/@jswork/craco-plugin-banner
[license-url]: https://github.com/afeiship/craco-plugin-banner/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/craco-plugin-banner
[size-url]: https://github.com/afeiship/craco-plugin-banner/blob/master/dist/craco-plugin-banner.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/craco-plugin-banner
[download-url]: https://www.npmjs.com/package/@jswork/craco-plugin-banner
npm package: @jswork/craco-plugin-bundle-analyzer
Description: Craco plugin for `webpack-bundle-analyzer`.
Latest version: 1.0.5

# craco-plugin-bundle-analyzer
> Craco plugin for `webpack-bundle-analyzer`.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/craco-plugin-bundle-analyzer
```

## usage
```js
import cracoPluginBundleAnalyzer from '@jswork/craco-plugin-bundle-analyzer';

// usage goes here.
```

## license
Code released under [the MIT license](https://github.com/afeiship/craco-plugin-bundle-analyzer/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/craco-plugin-bundle-analyzer
[version-url]: https://npmjs.org/package/@jswork/craco-plugin-bundle-analyzer

[license-image]: https://img.shields.io/npm/l/@jswork/craco-plugin-bundle-analyzer
[license-url]: https://github.com/afeiship/craco-plugin-bundle-analyzer/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/craco-plugin-bundle-analyzer
[size-url]: https://github.com/afeiship/craco-plugin-bundle-analyzer/blob/master/dist/craco-plugin-bundle-analyzer.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/craco-plugin-bundle-analyzer
[download-url]: https://www.npmjs.com/package/@jswork/craco-plugin-bundle-analyzer
npm package: @jswork/craco-plugin-debug
Description: Craco plugin for debug.
Latest version: 1.0.6

# craco-plugin-debug
> Craco plugin for debug.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/craco-plugin-debug
```

## usage
```js
import cracoPluginDebug from '@jswork/craco-plugin-debug';

// craco.config.js
module.exports = {
    plugins: [
        { plugin: cracoPluginDebug , options: { filename: 'debug.log'} }
    ]
}
```

## license
Code released under [the MIT license](https://github.com/afeiship/craco-plugin-debug/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/craco-plugin-debug
[version-url]: https://npmjs.org/package/@jswork/craco-plugin-debug

[license-image]: https://img.shields.io/npm/l/@jswork/craco-plugin-debug
[license-url]: https://github.com/afeiship/craco-plugin-debug/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/craco-plugin-debug
[size-url]: https://github.com/afeiship/craco-plugin-debug/blob/master/dist/craco-plugin-debug.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/craco-plugin-debug
[download-url]: https://www.npmjs.com/package/@jswork/craco-plugin-debug
npm package: @jswork/craco-plugin-dll-refs
Description: Craco plugin for webpack.DllReferencePlugin.
Latest version: 1.0.9

# craco-plugin-dll-refs
> Craco plugin for webpack.DllReferencePlugin.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/craco-plugin-dll-refs
```

## usage
```js
import cracoPluginDllRefs from '@jswork/craco-plugin-dll-refs';

// usage goes here.
```

## usage with hmr
```conf
# 组合1: HRM + disabled dll-refs
# 特点: 启动慢，但支持HMR，开发体验更好<默认为true,所以这个也不用写>
FAST_REFRESH = true
# craco.config.js<options: 默认可以不写>
{ plugin: dllRefs, options: {inject: false} }


## 组合2: refresh + enable dll-refs
# 特点: 启动快，但不支持HMR，对于表单应用体验有点差，但问题较少，占内存较大
FAST_REFRESH = false
# craco.config.js
{ plugin: dllRefs, options: { inject: true } }
```

## license
Code released under [the MIT license](https://github.com/afeiship/craco-plugin-dll-refs/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/craco-plugin-dll-refs
[version-url]: https://npmjs.org/package/@jswork/craco-plugin-dll-refs

[license-image]: https://img.shields.io/npm/l/@jswork/craco-plugin-dll-refs
[license-url]: https://github.com/afeiship/craco-plugin-dll-refs/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/craco-plugin-dll-refs
[size-url]: https://github.com/afeiship/craco-plugin-dll-refs/blob/master/dist/craco-plugin-dll-refs.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/craco-plugin-dll-refs
[download-url]: https://www.npmjs.com/package/@jswork/craco-plugin-dll-refs
npm package: @jswork/craco-plugin-dll-refs-sass
Description: Craco plugin for sass references.
Latest version: 1.0.3

# craco-plugin-dll-refs-sass
> Craco plugin for sass references.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/craco-plugin-dll-refs-sass
```

## usage
```js
import cracoPluginDllRefsSass from '@jswork/craco-plugin-dll-refs-sass';

// usage goes here.
```

## license
Code released under [the MIT license](https://github.com/afeiship/craco-plugin-dll-refs-sass/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/craco-plugin-dll-refs-sass
[version-url]: https://npmjs.org/package/@jswork/craco-plugin-dll-refs-sass

[license-image]: https://img.shields.io/npm/l/@jswork/craco-plugin-dll-refs-sass
[license-url]: https://github.com/afeiship/craco-plugin-dll-refs-sass/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/craco-plugin-dll-refs-sass
[size-url]: https://github.com/afeiship/craco-plugin-dll-refs-sass/blob/master/dist/craco-plugin-dll-refs-sass.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/craco-plugin-dll-refs-sass
[download-url]: https://www.npmjs.com/package/@jswork/craco-plugin-dll-refs-sass
npm package: @jswork/craco-plugin-environment
Description: Craco plugin for env.
Latest version: 1.0.6

# craco-plugin-environment
> Craco plugin for env.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/craco-plugin-environment
```

## usage
```js
import cracoPluginEnvironment from '@jswork/craco-plugin-environment';

// global.d.ts
declare global {
  const APP_VARS: any;
}

// eslintrc.js
"globals": {
  "APP_VARS": true
}

// craco.config.js
{
  plugin: cracoPluginEnvironment,
  options: {
    vars: {
      BUILD_DATETIME: new Date().toLocaleString('en-US', {
        hour12: false,
        timeZone: 'Asia/ShangHai',
      }),
      BUILD_VERSION: pkg.version,
    },
  },
}
```

## license
Code released under [the MIT license](https://github.com/afeiship/craco-plugin-environment/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/craco-plugin-environment
[version-url]: https://npmjs.org/package/@jswork/craco-plugin-environment

[license-image]: https://img.shields.io/npm/l/@jswork/craco-plugin-environment
[license-url]: https://github.com/afeiship/craco-plugin-environment/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/craco-plugin-environment
[size-url]: https://github.com/afeiship/craco-plugin-environment/blob/master/dist/craco-plugin-environment.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/craco-plugin-environment
[download-url]: https://www.npmjs.com/package/@jswork/craco-plugin-environment
npm package: @jswork/craco-plugin-offline
Description: Craco plugin for sw.
Latest version: 1.0.4

# craco-plugin-offline
> Craco plugin for sw.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/craco-plugin-offline
```

## usage
```js
import cracoPluginOffline from '@jswork/craco-plugin-offline';

// usage goes here.
```

## license
Code released under [the MIT license](https://github.com/afeiship/craco-plugin-offline/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/craco-plugin-offline
[version-url]: https://npmjs.org/package/@jswork/craco-plugin-offline

[license-image]: https://img.shields.io/npm/l/@jswork/craco-plugin-offline
[license-url]: https://github.com/afeiship/craco-plugin-offline/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/craco-plugin-offline
[size-url]: https://github.com/afeiship/craco-plugin-offline/blob/master/dist/craco-plugin-offline.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/craco-plugin-offline
[download-url]: https://www.npmjs.com/package/@jswork/craco-plugin-offline
npm package: @jswork/craco-plugin-spa-base
Description: Carco plugin for spa base.
Latest version: 1.0.8

# craco-plugin-spa-base
> Carco plugin for spa base.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/craco-plugin-spa-base
```

## usage
```js
import cracoPluginSpaBase from '@jswork/craco-plugin-spa-base';

// usage goes here.
```

## license
Code released under [the MIT license](https://github.com/afeiship/craco-plugin-spa-base/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/craco-plugin-spa-base
[version-url]: https://npmjs.org/package/@jswork/craco-plugin-spa-base

[license-image]: https://img.shields.io/npm/l/@jswork/craco-plugin-spa-base
[license-url]: https://github.com/afeiship/craco-plugin-spa-base/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/craco-plugin-spa-base
[size-url]: https://github.com/afeiship/craco-plugin-spa-base/blob/master/dist/craco-plugin-spa-base.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/craco-plugin-spa-base
[download-url]: https://www.npmjs.com/package/@jswork/craco-plugin-spa-base
npm package: @jswork/craco-plugin-speed-measure
Description: Craco plugin for `speed-measure-webpack-plugin`.
Latest version: 1.0.4

# craco-plugin-speed-measure
> Craco plugin for `speed-measure-webpack-plugin`.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/craco-plugin-speed-measure
```

## usage
```js
import cracoPluginSpeedMeasure from '@jswork/craco-plugin-speed-measure';

// usage goes here.
```

## license
Code released under [the MIT license](https://github.com/afeiship/craco-plugin-speed-measure/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/craco-plugin-speed-measure
[version-url]: https://npmjs.org/package/@jswork/craco-plugin-speed-measure

[license-image]: https://img.shields.io/npm/l/@jswork/craco-plugin-speed-measure
[license-url]: https://github.com/afeiship/craco-plugin-speed-measure/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/craco-plugin-speed-measure
[size-url]: https://github.com/afeiship/craco-plugin-speed-measure/blob/master/dist/craco-plugin-speed-measure.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/craco-plugin-speed-measure
[download-url]: https://www.npmjs.com/package/@jswork/craco-plugin-speed-measure
npm package: @jswork/craco-plugin-styled-components
Description: Craco plugin for `styled-components`.
Latest version: 1.0.3

# craco-plugin-styled-components
> Craco plugin for `styled-components`.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/craco-plugin-styled-components
```

## usage
```js
import cracoPluginStyledComponents from '@jswork/craco-plugin-styled-components';

// usage goes here.
```

## license
Code released under [the MIT license](https://github.com/afeiship/craco-plugin-styled-components/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/craco-plugin-styled-components
[version-url]: https://npmjs.org/package/@jswork/craco-plugin-styled-components

[license-image]: https://img.shields.io/npm/l/@jswork/craco-plugin-styled-components
[license-url]: https://github.com/afeiship/craco-plugin-styled-components/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/craco-plugin-styled-components
[size-url]: https://github.com/afeiship/craco-plugin-styled-components/blob/master/dist/craco-plugin-styled-components.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/craco-plugin-styled-components
[download-url]: https://www.npmjs.com/package/@jswork/craco-plugin-styled-components
npm package: @jswork/craco-plugin-styled-extension
Description: Some extensions for styled-components in cra.
Latest version: 1.0.8

# craco-plugin-styled-extension
> Some extensions for styled-components in cra.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
1. installed packages
```shell
npm i styled-components
npm i @jswork/color-rgba @jswork/color-lighten @jswork/color-darken
npm install @jswork/craco-plugin-styled-extension
```
2. .eslintrc
```js
  "globals": {
    "styled": true,
    "rgba": true,
  }
```
3. src/global.d.ts
```ts
import { StyledInterface } from 'styled-components';

declare global {
  const rgba: any;
  const styled: StyledInterface;
}
```

## usage
```js
import cracoPluginStyledExtension from '@jswork/craco-plugin-styled-extension';

// usage goes here.
```

```tsx
export const MyFooter = styled.footer`
  font-size: 14px;
  color: ${rgba('#fff', 0.8)};
  position: absolute;
  bottom: 24px;
  width: 100%;
  text-align: center;
`;
```

## license
Code released under [the MIT license](https://github.com/afeiship/craco-plugin-styled-extension/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/craco-plugin-styled-extension
[version-url]: https://npmjs.org/package/@jswork/craco-plugin-styled-extension

[license-image]: https://img.shields.io/npm/l/@jswork/craco-plugin-styled-extension
[license-url]: https://github.com/afeiship/craco-plugin-styled-extension/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/craco-plugin-styled-extension
[size-url]: https://github.com/afeiship/craco-plugin-styled-extension/blob/master/dist/craco-plugin-styled-extension.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/craco-plugin-styled-extension
[download-url]: https://www.npmjs.com/package/@jswork/craco-plugin-styled-extension
npm package: @jswork/create-proxy
Description: Create proxy with callback.
Latest version: 1.0.4

# create-proxy
> Create proxy with callback.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/create-proxy
```

## usage
```js
import createProxy from '@jswork/create-proxy';

const person = {
  name: 'John Doe',
  age: 42,
  nationality: 'American',
};

const state = createProxy(person, (target, key, newValue)=>{
  const oldValue = target[key];
  console.log(newValue, oldValue, key, target);
});
```

## license
Code released under [the MIT license](https://github.com/afeiship/create-proxy/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/create-proxy
[version-url]: https://npmjs.org/package/@jswork/create-proxy

[license-image]: https://img.shields.io/npm/l/@jswork/create-proxy
[license-url]: https://github.com/afeiship/create-proxy/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/create-proxy
[size-url]: https://github.com/afeiship/create-proxy/blob/master/dist/create-proxy.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/create-proxy
[download-url]: https://www.npmjs.com/package/@jswork/create-proxy
npm package: @jswork/create-valtio-state
Description: Create valtio state.
Latest version: 1.0.1

# create-valtio-state
> Create valtio state.

## installation
```sh
yarn add @jswork/create-valtio-state
```

## usage
```js
import createState from '@jswork/create-valtio-state';

// 示例 1：使用类
class Counter {
  public count = 1;

  get doubled() {
    return this.count * 2;
  }

  set doubled(newValue: number) {
    this.count = newValue / 2;
  }
}

const stateFromClass = createState(Counter);

// 示例 2：使用普通对象
const stateFromObject = createState({
  count: 1,
  get doubled() {
    return this.count * 2;
  },
  set doubled(newValue: number) {
    this.count = newValue / 2;
  }
});

export { stateFromClass, stateFromObject };
```

## react
```tsx
import { HTMLAttributes, FC, useEffect } from 'react';
import cx from 'classnames';
import { subscribe, useSnapshot } from 'valtio';

type IProps = HTMLAttributes<HTMLDivElement>;

import { stateFromClass as state } from '@/stores/counter';

const Anonymous: FC<IProps> = (props) => {
  const { className, ...rest } = props;
  const snap = useSnapshot(state);

  useEffect(() => {
    return subscribe(state, () => {
      console.log('State changed:', state);
    });
  }, []);

  return (
    <div className={cx('y-4 relative', className)} {...rest}>
      <div className="bg-gray-100 p-4">Count: {snap.count}</div>
      <div className="bg-gray-100 p-4">Double: {snap.doubled}</div>
      <nav className="actions x-5 fcc">
        <button onClick={() => (state.count = 0)}>Reset</button>
        <button onClick={() => state.count++}>Increment</button>
        <button onClick={() => state.count--}>Decrement</button>
      </nav>
    </div>
  );
};

export default Anonymous;
```
npm package: @jswork/data-arary
Description: Data array with some new methods.
Latest version: 1.0.3

# data-arary
> Data array with some new methods.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/data-arary
```

## usage
```js
import dataArary from '@jswork/data-arary';

// usage goes here.
```

## types
```ts
/// <reference types="@jswork/data-arary/global.d.ts" />
```

## license
Code released under [the MIT license](https://github.com/afeiship/data-arary/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/data-arary
[version-url]: https://npmjs.org/package/@jswork/data-arary

[license-image]: https://img.shields.io/npm/l/@jswork/data-arary
[license-url]: https://github.com/afeiship/data-arary/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/data-arary
[size-url]: https://github.com/afeiship/data-arary/blob/master/dist/index.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/data-arary
[download-url]: https://www.npmjs.com/package/@jswork/data-arary
npm package: @jswork/data-pagination
Description: Raw data(items) pagination.
Latest version: 1.0.4

# data-pagination
> Raw data(items) pagination.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```shell
npm install @jswork/data-pagination
```

## usage
```js
import DataPagination from '@jswork/data-pagination';

const dp = new DataPagination([1, 2, 3, 4, 5, 6, 7, 8, 9, 10]);

// to first page
dp.first();

// to last page
dp.last();

// to next page
dp.next();

// to prev page
dp.prev();

// to page 2
dp.goto(2);
```

## license
Code released under [the MIT license](https://github.com/afeiship/data-pagination/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/data-pagination
[version-url]: https://npmjs.org/package/@jswork/data-pagination

[license-image]: https://img.shields.io/npm/l/@jswork/data-pagination
[license-url]: https://github.com/afeiship/data-pagination/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/data-pagination
[size-url]: https://github.com/afeiship/data-pagination/blob/master/dist/index.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/data-pagination
[download-url]: https://www.npmjs.com/package/@jswork/data-pagination