Skip to content

Creator-SN/common-utils

Repository files navigation

Commom Utils

The Util reduces code size and helps to code quickly.

Configuration Local NPM

.npmrc

@creator-sn:registry=https://npm.pkg.github.com

Installation

  1. NPM Github
yarn add @creator-sn/common-utils # npm install @creator-sn/common-utils

Usage

import { DomUtil, CookieUtil, NotificationUtil, SystemUtil, RandomUtil, DateUtil } from '@creator-sn/common-utils';

RandomUtil

// generate password
RandomUtil.password();

// generate uuid
RandomUtil.uuid();

DOMUtil

// download a file
DOMUtil.download(new File([new Blob()], 'test.txt'));

Development

  1. Serve
yarn dev
  1. Test
yarn test