Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@ijx/utils

Package Overview
Dependencies
Maintainers
0
Versions
21
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ijx/utils

Utilidades varias

  • 1.1.6
  • latest
  • npm
  • Socket score

Version published
Maintainers
0
Created
Source

Utils

Generic functions library

Installation

Use the package manager npm to install utils.

npm install @ijx/utils

Usage

import "@ijx/utils"

List of prototypes

  • Array
    • filter2(func)
    • deleteElement(element)
    • concat2(...arrays)
    • mapAsync(func)
    • hasDuplicates()
  • Object
    • getKeyByValue(value)
    • clone()
    • assign(obj)
    • defObject(fuente)
    • forEach(fn, thisArg)
    • filter(fn, thisArg)
    • map(fn, thisArg)
    • getName()
    • getMethods()
  • String
    • camelToSnakeCase()
    • camelCase(sep="_", type=true)
    • rellenar(size, character=' ')
    • delExt()
    • getExt()
    • zeroPad(n = 2)
    • suspensivos(max, chars="...")
  • Number
    • zeroPad(n = 2)
  • Date
    • format(format="d/m/Y")

List of functions

  • NOOP()
  • isInteger(num: any)
  • isFloat(num: any)
  • isClass(entity: any)
  • isNullable(data: any)
  • isType(data: any, type: string)
  • isTypeNotNull(data: any, type: string)
  • isTypeStringNotEmpty(data: any)
  • wait(time=1)
  • thread(func: function)
  • echo(cad: any)
  • getDate(...t)
  • basename(path: string, sep="/")
  • dirname(path: string, sep="/")
  • makeid(length=5)
  • decToHex(num: number)
  • base64_encode(data: any)
  • base64_decode(data: any)
  • decimalAdjust(value: number, exp=0, type="round")
  • secondsToDhms(seconds: number)
  • stringifyNoCircular(obj: object, space=null)
  • replaceSqlValues(sqlQuery: string, data: (string | number | null)[])
  • isJson(text: string)
  • escapeHtml(str: string)
  • unescapeHtml(str: string)
  • readArgs(validArgs: object, initChar="-", defaultBool=false)

List of functions with dependencies

  • createDirs(src: string)
  • readable(src: string)
  • writable(src: string)
  • readableAndWritable(src: string)
  • existsAsync(src: string)
  • getRelative(metaurl, ...file)
  • getImportPath(metaurl)
  • pathToImport(metaurl, ruta)
  • exec(command: string)

Keywords

FAQs

Package last updated on 04 Nov 2024

Did you know?

Socket

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc