
Security News
Axios Supply Chain Attack Reaches OpenAI macOS Signing Pipeline, Forces Certificate Rotation
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.
js-utils-pro
Advanced tools
Add some useful utils to your project. No more 'ctrl C V'
isFns
is, isDef, isUnDef, isObject, isDate, isNull, isNumber, isString, isFunction, isPromise, isBoolean, isRegExp, isArray, isEmpty, isServer, isClient, isWindow, isElement, isImageDom, isTextarea, isMobile, isiOS, isAndroid, isWechat, isLine, isIOSWechat, isFacebook, isWhatsapp, isTwitter, isMac, isWin.
See use code at js-utils/isFunctions.test.ts at main · laoer536/js-utils (github.com) && js-utils/isFunctions.client.test.ts at main · laoer536/js-utils (github.com)
dataFns
deepCloneByStringfy,deepClone,jsonToObject,getRandomNumber,getRandomOneInArr,getRandomArr,getMapkeyedObj,getLengthArr.
See use code at js-utils/data.test.ts at main · laoer536/js-utils (github.com)
stringFns
snakeCase,camelCase,kebabCase,pascalCase,splitByCase,lowerFirst,upperFirst.
See use code at js-utils/string.test.ts at main · laoer536/js-utils (github.com)
domFns(It should use in client)
getUrlSearchParams,intersectionObserverElement,downloadFile,playAudio,fastCopy.
See use code at js-utils/dom.test.ts at main · laoer536/js-utils (github.com)
Other(Waiting for exploration)
npm
npm install js-utils-pro -D
pnpm
pnpm install js-utils-pro -D
yarn
yarn add js-utils-pro -D
In code, you can
//way1
import {isFns} from 'js-utils-pro'
import {dataFns} from 'js-utils-pro'
isFns.isEmpty([]) //true
isFns.isNumber(222222) // true
const target = { name: 'laoer536', obj: { age: 1111, sex: 1 } }
const deepTarget = dataFns.deepClone(target)
//...
//Those methods are covered by test. They are safe and available.
//way2:
//when version >= 0.0.13 You also can
import {isEmpty,isNumber} from 'js-utils-pro/is'
import {deepClone} from 'js-utils-pro/data'
isEmpty([]) //true
isNumber(222222) // true
const target = { name: 'laoer536', obj: { age: 1111, sex: 1 } }
const deepTarget = deepClone(target)
//...
//Which way do we use? It's up to you. The 'way1' is categorized for easy memory and use. But I prefer to use 'way2', because it use 'import on demand' to get minimize size.
If you discover some bugs when you use, please send some issues or 'pr', thanks a lot. I will continue to maintain this library.
laoer536/js-utils: Add some useful utils to your project. No more 'ctrl C V' (github.com)
FAQs
Add some useful utils to your project. No more 'ctrl C V'.
We found that js-utils-pro demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.

Security News
Open source is under attack because of how much value it creates. It has been the foundation of every major software innovation for the last three decades. This is not the time to walk away from it.

Security News
Socket CEO Feross Aboukhadijeh breaks down how North Korea hijacked Axios and what it means for the future of software supply chain security.