https://github.com/lh0x00/helper-fn
some functions help you save time processing, easy to use!
https://github.com/lh0x00/helper-fn
array function helper library object string tool
Last synced: about 1 year ago
JSON representation
some functions help you save time processing, easy to use!
- Host: GitHub
- URL: https://github.com/lh0x00/helper-fn
- Owner: lh0x00
- License: mit
- Created: 2018-07-20T15:23:08.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2019-02-18T18:19:46.000Z (over 7 years ago)
- Last Synced: 2025-02-15T00:32:42.641Z (over 1 year ago)
- Topics: array, function, helper, library, object, string, tool
- Language: JavaScript
- Size: 57.6 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: readme.md
- License: license
Awesome Lists containing this project
README
# helper-fn
[![npm version][npm-version-image]][npm-url]
[![npm downloads][npm-downloads-image]][npm-url]
[![github issues][github-issues-image]][github-issues-url]
[![build status][travis-image]][npm-url]
[![greenkeeper badge][greenkeeper-image]](https://greenkeeper.io/)
some functions help you save time processing, easy to use!
## install
```bash
# use npm
$ npm install helper-fn
# or yarn
$ yarn add helper-fn
```
## usage
```javascript
// default import
import { sliceObjectByKeys, memoize } from 'helper-fn'
// another way to reduce size
import sliceObjectByKeys from 'helper-fn/dist/sliceObjectByKeys'
import memoize from 'helper-fn/dist/memoize'
```
## functions
### sliceObjectByKeys
clone object from another object by keys, [read more](https://github.com/lamhieu-vk/helper-fn/blob/master/examples/sliceObjectByKeys.md)
```javascript
import { sliceObjectByKeys } from 'helper-fn' //use default import
import sliceObjectByKeys from 'helper-fn/dist/sliceObjectByKeys' // or reduce size
```
### memoize
function to memoization remembers the latest invocation, [read more](https://github.com/lamhieu-vk/helper-fn/blob/master/examples/memoize.md)
```javascript
import { memoize } from 'helper-fn' //use default import
import memoize from 'helper-fn/dist/memoize' // or reduce size
```
### capitalizeFirstLetter
capitalize first letter [read more](https://github.com/lamhieu-vk/helper-fn/blob/master/examples/capitalizeFirstLetter.md)
```javascript
import { capitalizeFirstLetter } from 'helper-fn' //use default import
import capitalizeFirstLetter from 'helper-fn/dist/capitalizeFirstLetter' // or reduce size
```
### excludeObjectByKeys
clone object from another object and exclude by keys, [read more](https://github.com/lamhieu-vk/helper-fn/blob/master/examples/excludeObjectByKeys.md)
```javascript
import { excludeObjectByKeys } from 'helper-fn' //use default import
import excludeObjectByKeys from 'helper-fn/dist/excludeObjectByKeys' // or reduce size
```
### regexStringParser
parse string with special characters to regex format [read more](https://github.com/lamhieu-vk/helper-fn/blob/master/examples/regexStringParser.md)
```javascript
import { regexStringParser } from 'helper-fn' //use default import
import regexStringParser from 'helper-fn/dist/regexStringParser' // or reduce size
```
[npm-url]: https://npmjs.org/package/helper-fn
[npm-version-image]: https://badge.fury.io/js/helper-fn.svg
[npm-downloads-image]: https://img.shields.io/npm/dm/helper-fn.svg
[github-issues-image]: https://img.shields.io/github/issues/lamhieu-vk/helper-fn.svg
[github-issues-url]: https://github.com/lamhieu-vk/helper-fn/issues
[travis-image]: https://travis-ci.com/lamhieu-vk/helper-fn.svg?branch=master
[greenkeeper-image]: https://badges.greenkeeper.io/lamhieu-vk/helper-fn.svg