New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details
Socket
Book a DemoSign in
Socket

kr-corekit

Package Overview
Dependencies
Maintainers
2
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

kr-corekit

A lightweight and modern utility toolkit for JavaScript and TypeScript. kr-corekit provides essential functions for strings, arrays, objects, and more, designed for simplicity and productivity.

latest
Source
npmnpm
Version
1.0.0
Version published
Weekly downloads
32
-17.95%
Maintainers
2
Weekly downloads
 
Created
Source

kr-corekit

Language: English | 한국어 | 简体中文 | 日本語

A utility toolkit for JavaScript and TypeScript built with a clear, practical API design.

Highlights

  • 130+ utility functions across string, array, object, async, promise, date, math, lang and more
  • Tree-shake friendly module exports
  • TypeScript-first with generated .d.ts files
  • ESM/CJS bundle output

Installation

npm install kr-corekit
# or
pnpm add kr-corekit
# or
yarn add kr-corekit

Quick Start

import {
  stringUtil,
  arrayUtil,
  objectUtil,
  asyncUtil,
  promiseUtil,
  dateUtil,
  mathUtil,
  langUtil,
} from "kr-corekit";

const id = stringUtil.camelCase("user profile id"); // userProfileId
const rows = arrayUtil.chunk([1, 2, 3, 4, 5], 2); // [[1,2], [3,4], [5]]
const city = objectUtil.get({ user: { profile: { city: "Seoul" } } }, "user.profile.city");

const mapped = await asyncUtil.mapAsync([1, 2, 3], async (v) => v * 2);
const safe = await promiseUtil.withTimeout(fetch("/api/health"), 1000);

const tomorrow = dateUtil.addDays(new Date(), 1);
const average = mathUtil.mean([10, 20, 30]);
const enabled = langUtil.toBoolean("yes");

Modules

  • stringUtil: case conversion, HTML escape/unescape, truncate, slugify
  • arrayUtil: chunk, flatten, uniq/uniqBy, groupBy, sortBy, set ops, sampling
  • collectionUtil: map/filter/reduce/find/every/some/includes over arrays/objects
  • objectUtil: get/set/has/merge/defaults/pick/omit/deepClone/deepFreeze
  • numberUtil: clamp, inRange, random, ceil/floor/round, sum/subtract/multiply
  • mathUtil: mean/median/min/max/sumBy/minBy/maxBy
  • dateUtil: add/sub days/hours, start/end of day, formatDate, date comparisons
  • langUtil: toBoolean/toNumber/toString/defaultTo/castArray/isEqual
  • asyncUtil: pLimit, mapAsync, filterAsync, eachAsync, series, parallel
  • promiseUtil: defer, withTimeout, retryWithDelay, settle, toResult
  • plus existing: commonUtil, functionUtil, validationUtil, formatUtil, typeUtil, cookieUtil, deviceUtil, searchQueryUtil

Tree-Shaking Import

import { camelCase } from "kr-corekit/stringUtil";
import { chunk } from "kr-corekit/arrayUtil";
import { get } from "kr-corekit/objectUtil";
import { mapAsync } from "kr-corekit/asyncUtil";
import { withTimeout } from "kr-corekit/promiseUtil";

Full API Examples

Benchmark

npm run benchmark

This runs a local micro-benchmark script at benchmark/index.mjs after build.

Latest local sample (2026-02-25):

array.chunk       ~1,065,050 ops/s
object.get        ~2,681,055 ops/s
string.camelCase  ~1,902,407 ops/s
async.mapAsync    ~1,514,005 ops/s

Notes

  • Full API list is available via module entry files under package/*/index.ts and generated types under dist/types/*/index.d.ts.
  • If you want function-level docs/examples expanded further, keep language files in sync when updating.

License

MIT

Keywords

javascript

FAQs

Package last updated on 26 Feb 2026

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