├── .github ├── FUNDING.yml └── workflows │ ├── ci.yml │ └── release.yml ├── .gitignore ├── .vscode └── settings.json ├── CONTRIBUTING.md ├── LICENSE ├── README.md ├── docs └── p.md ├── eslint.config.mjs ├── package.json ├── pnpm-lock.yaml ├── pnpm-workspace.yaml ├── src ├── __snapshots__ │ └── string.test.ts.snap ├── array.test.ts ├── array.ts ├── base.ts ├── equal.ts ├── function.test.ts ├── function.ts ├── guards.ts ├── index.ts ├── is.test.ts ├── is.ts ├── math.test.ts ├── math.ts ├── object.test.ts ├── object.ts ├── p.test.ts ├── p.ts ├── promise.test.ts ├── promise.ts ├── string.test.ts ├── string.ts ├── time.ts ├── types.ts └── vendor.ts └── tsconfig.json /.github/FUNDING.yml: -------------------------------------------------------------------------------- 1 | github: [antfu] 2 | -------------------------------------------------------------------------------- /.github/workflows/ci.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/.github/workflows/ci.yml -------------------------------------------------------------------------------- /.github/workflows/release.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/.github/workflows/release.yml -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/.gitignore -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/.vscode/settings.json -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | Please refer to https://github.com/antfu/contribute 2 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/README.md -------------------------------------------------------------------------------- /docs/p.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/docs/p.md -------------------------------------------------------------------------------- /eslint.config.mjs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/eslint.config.mjs -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/package.json -------------------------------------------------------------------------------- /pnpm-lock.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/pnpm-lock.yaml -------------------------------------------------------------------------------- /pnpm-workspace.yaml: -------------------------------------------------------------------------------- 1 | onlyBuiltDependencies: 2 | - esbuild 3 | -------------------------------------------------------------------------------- /src/__snapshots__/string.test.ts.snap: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/__snapshots__/string.test.ts.snap -------------------------------------------------------------------------------- /src/array.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/array.test.ts -------------------------------------------------------------------------------- /src/array.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/array.ts -------------------------------------------------------------------------------- /src/base.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/base.ts -------------------------------------------------------------------------------- /src/equal.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/equal.ts -------------------------------------------------------------------------------- /src/function.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/function.test.ts -------------------------------------------------------------------------------- /src/function.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/function.ts -------------------------------------------------------------------------------- /src/guards.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/guards.ts -------------------------------------------------------------------------------- /src/index.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/index.ts -------------------------------------------------------------------------------- /src/is.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/is.test.ts -------------------------------------------------------------------------------- /src/is.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/is.ts -------------------------------------------------------------------------------- /src/math.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/math.test.ts -------------------------------------------------------------------------------- /src/math.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/math.ts -------------------------------------------------------------------------------- /src/object.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/object.test.ts -------------------------------------------------------------------------------- /src/object.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/object.ts -------------------------------------------------------------------------------- /src/p.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/p.test.ts -------------------------------------------------------------------------------- /src/p.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/p.ts -------------------------------------------------------------------------------- /src/promise.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/promise.test.ts -------------------------------------------------------------------------------- /src/promise.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/promise.ts -------------------------------------------------------------------------------- /src/string.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/string.test.ts -------------------------------------------------------------------------------- /src/string.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/string.ts -------------------------------------------------------------------------------- /src/time.ts: -------------------------------------------------------------------------------- 1 | export const timestamp = () => +Date.now() 2 | -------------------------------------------------------------------------------- /src/types.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/types.ts -------------------------------------------------------------------------------- /src/vendor.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/src/vendor.ts -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/antfu/utils/HEAD/tsconfig.json --------------------------------------------------------------------------------