Installation
How to install UtilsJS version 3.
Getting Started
Welcome to the UtilsJS (v3) installation guide, follow the steps below to quickly set up the package and enable autocomplete support in your editor.
Before installing, please ensure your environment meets the requirements, if you haven’t checked them yet, you can find the prerequisites here:
Installation Guide
You can install UtilsJS using your preferred package manager, below are example commands for different package managers.
Verify Installation
After installing, test the package with a quick import:
Autocomplete Hint
Improve TypeScript editor import suggestions for @rzl-zone/utils-js, so all functions, types, and modules appear instantly when triggering autocomplete —
press Ctrl+Space (Windows/Linux), ⌘+Space (macOS), or your editor’s autocomplete shortcut.
This works across modern TypeScript-supported editors (e.g., VSCode, WebStorm, Vim extensions, NeoVim LSP, Cursor) without requiring triple-slash references —
the package is fully indexed automatically through your editor’s TypeScript language service.
Install @rzl-zone/utils-js.
- Make sure the package is installed, see Installation Guide.
Create a types folder.
-
Inside your project root, make a folder called
types:jsconfig.json(for JavaScript projects)tsconfig.json
Add the global reference file.
-
Add to
types/index.d.tswith this content:types/index.d.ts -
This tells TypeScript to include the types from
@rzl-zone/utils-jsglobally. -
You can add more references here if needed, for example:
types/index.d.ts
Update tsconfig.json.
-
Make sure add
typesfolder to"include", so TypeScript automatically picks up your types folder:tsconfig.json -
The
typesfolder comes first, so your references override or add to the default@typespackages
Update jsconfig.json (for JavaScript projects).
-
If you also work with JS, do the same:
jsconfig.json Tip
For JS projects, consider adding
"checkJs": true, for better IntelliSense.
Restart your editor/IDE.
- This forces your TypeScript language service to re-index the package.
- After restart, all functions, types, and modules from
@rzl-zone/utils-jswill appear instantly in autocomplete.
Troubleshooting
If you encounter issues such as missing types, IntelliSense errors, or unexpected behavior:
General Fixes
- Clear your package manager cache
- Reinstall node_modules
- Ensure your environment supports ESM or CJS
TypeScript Users (VSCode / IDE)
- After installing or updating the package:
- Open the Command Palette
- Select
“TypeScript: Restart TS Server” - If using tsconfig.json, ensure moduleResolution is set properly
JavaScript Users
- Reload your editor/IDE to refresh auto-completions
- Ensure your bundler (Vite, Next.js, Webpack, etc.) has restarted
UtilsJS includes both ESM and CJS builds for maximum compatibility across modern tooling.
