@reliverse/dler (formerly relidler; /ΛdiΛ.lΙr/, dealer) is both a unified package manager for typescript/javascript projects and a flexible framework for creating, building, and publishing js/ts libraries to npm and jsr.
dler is your package managerβs best friend β it extends bun, deno (π), pnpm, yarn, and npm with powerful and modern features.
at its core, dler is a flexible and fully automated bundler that also doubles as an npm/jsr publishing tool. beyond bundling, dler provides a rich codemod toolkit designed for modern typescript/javascript development.
features
drop-in unjs/unbuild support with extended capabilities like publishing
automated publishing to npm and jsr with smart workflow orchestration
reliable builds with robust typescript/javascript support and error handling
smart versioning with semantic release and automatic version bumping
zero-config setup β forget about package.json maintenance
built-in bun environment when used as a standalone cli app
performance-optimized using fast build pipelines and aggressive caching
17 built-in commands β see dler commands for everything it can do
path alias resolution β automatically rewrites tsconfig aliases to relative imports
configurable by design β dedicated config files with sane defaults
dual interface β use via cli or import as sdk for programmatic use
monorepo support with experimental libs mode for multi-library setups
magic spells β plugin system for custom build logic and extensions
codemod toolkit β powerful code transformation utilities out of the box
full monorepo system with optimized cross-package dependency handling
esp. designed for cli tool creators, project bootstrappers (like rse)
perfect for anyone who wants their package manager to have sweet powers
getting started
before using dler, make sure you have git, node.js, and a supported package manager installed β bun is highly recommended for the best experience.
0. try the playground
π‘ tip
curious to see dler in action before integrating it into your project?
clone the repo and try e.g. bun dler build to build dler using... dler itself!
git clone https://github.com/reliverse/dler.git
cd dler
bun i
bun dler build # runs dler from source (cli entry: src/cli.ts)
1. install dler
it is recommended to install dler both globally and as a dev dependency:
global install β bun add -g @reliverse/dler β lets you use dler anywhere, like a system-level cli.
dev dependency β bun add -D @reliverse/dler β pins the version per project, so all contributors use the same version.
instead of global install, you can alternatively install dler as a standalone binary: bunx @reliverse/dler
usage depends on how dler is installed:
dler β if installed globally (or as standalone binary)
buildPreExtensions: support additional file types like ["ts", "js", "vue", "tsx", "jsx"]
buildTemplatesDir: exclude a directory from being built; it will be copied as-is (e.g. src/foo/templates β dist-*/bin/foo/templates)
3. run and enjoy
bun dler [build|pub|--help] # if local
dler [build|pub|--help] # if global
π‘ run dler for an interactive menu, or dler --help for full command list.
4. upgrade your dev tools
keeping your tools fresh is always a good practice.
the command below upgrades not just dler, but also your local setup β including git, node.js, bun, npm, yarn, pnpm, and more.
just run:
bun dler upgrade
β οΈ donβt confuse this with dler update, which upgrades your project dependencies and global packages, not your system tools.
π note: both upgrade and update will update dler itself β globally and in your dependencies or devDependencies if run inside a project with a package.json β depends on how dler is installed.
dler commands
dler ships with a flexible command system (prev. plugins) and 17 built-in commands (from reliverse addons collection).
feel free to create your own commands. commands can be implemented as built-in directly in src/app/<command>/impl/* and then imported from src/app/<command>/cmd.ts; or implemented in your own library and then imported from src/app/<command>/cmd.ts.
if you run just dler β it will display a list of commands which you can launch interactively.
creates standalone executables for different platforms using bun's --compile feature.
# build for default targets (linux x64, windows x64, macos arm64)
bun dler build binary
# build for all supported platforms
bun dler build binary --targets=all
# build for specific platforms
bun dler build binary --targets=bun-linux-x64,bun-windows-x64
# build with optimization
bun dler build binary --bytecode --minify --sourcemap
# windows-specific options
bun dler build binary --windows-icon=icon.ico --windows-hide-console
# debugging options
bun dler build binary --no-compile --external=c12,terminal-kit,problematic-package
# list all available targets
bun dler build binary --targets=list
--directory: directory to check (src, dist-npm, dist-jsr, dist-libs/npm, dist-libs/jsr, or all)
--checks: comma-separated list of checks to run (missing-deps, file-extensions, path-extensions, dler-config-health, self-include, tsconfig-health, package-json-health)
pro tip:
the command will prompt you only for the arguments you haven't provided. for example, if you specify --directory but not --checks, it will only prompt you to select which checks to run.
how deps check works:
finds missing dependencies in your project by scanning your code for imports and comparing them to your package.json. This command is particularly useful for maintaining clean dependency lists and preventing runtime errors.
what it does:
traverses all .js, .jsx, .ts, and .tsx files in your project (by default, in the current directory)
detects all used packages, including scoped ones (@org/dep-name)
supports both es modules (import ... from "dep") and commonjs (require("dep"))
normalizes deep imports like dep/some/file to just dep
ignores local/relative imports (./foo, ../bar)
skips node_modules, .git, and common build folders
compares all used packages to those listed in your package.json
shows you which dependencies are missing (not listed)
can also show all used dependencies (listed and missing)
optionally includes node.js built-in modules in the report
outputs results in a readable format or as json
exits with error code 1 if missing dependencies are found
detects packages that are only in devDependencies but used in production code
identifies packages listed in both dependencies and devDependencies
usage examples:
# basic usage - scan current directory
dler deps
# scan a specific directory
dler deps --directory ./my-project
# show all dependencies (both listed and missing)
dler deps --all
# ignore specific patterns
dler deps --ignore "test/**,example/**"# output in json format
dler deps --json
# include node.js built-in modules
dler deps --include-builtins
# combine options
dler deps --all --directory ./src --include-builtins
missing dependencies are shown only once, even if used in multiple files.
deep imports like dep/some/file or @org/dep/some/thing are always resolved to their root package.
warning types:
Missing Dependencies: Packages that are imported but not listed in package.json
Dev-only Dependencies: Packages that are only in devDependencies but imported in production code
Duplicate Dependencies: Packages listed in both dependencies and devDependencies
5. conv
not yet documented.
6. fs
# simple example:
bun dler fs --mode copy --s "src/**/*.ts" --d "dist"
bun dler fs --mode rm --target "node_modules"
bun dler fs --mode rename --source"index.ts" --destination "index.ts.bak"# advanced example:
bun dler fs --mode copy --s ".temp/packages/*/lib/**/*" --d "src/libs/sdk/sdk-impl/rules/external"
bun dler fs --mode rm --target "**/node_modules"
7. init
not yet documented.
8. inject
not yet documented.
9. libs
builds and publishes specific subdirectories of your main project as standalone packages.
usage example:
using dler to package src/libs/sdk:
Migrates from fs.readdir and fs.readdirSync to globby
Handles both synchronous and asynchronous readdir operations
Supports fs.promises.readdir migration
Adds globby import if not present
Updates package.json with globby dependency
Preserves target directory paths
Maintains async/await usage
usage examples:
# Preview changes without applying them
dler migrate --lib readdir-glob --dryRun
# Apply changes
dler migrate --lib readdir-glob
# Migrate specific project
dler migrate --lib readdir-glob --project ./my-app
module resolution targets:
nodenext: adds .js extensions to imports and updates tsconfig
bundler: removes extensions from imports and updates tsconfig
usage examples:
# Migrate from node:path and/or pathe to pathkit
dler migrate --lib path-pathkit
# Migrate from node:fs and/or fs-extra to relifso
dler migrate --lib fs-relifso
# Migrate to nodenext module resolution
dler migrate --lib nodenext-bundler --target nodenext
# Migrate to bundler module resolution
dler migrate --lib nodenext-bundler --target bundler
# Preview changes without applying them
dler migrate --lib nodenext-bundler --target nodenext --dryRun
what it does:
updates import statements in your code
modifies tsconfig.json settings
updates package.json type field
provides a dry run option to preview changes
handles both relative and alias imports
supports both .ts and .tsx files
console-relinka:
@reliverse/relinka's best friend. Converts between different logging formats (console, consola method/object, and relinka's function/method/object styles).
Supports conversion between any combination of formats
Supports both consola method and object styles
next steps after migration:
for path-pathkit:
run 'bun install' to install @reliverse/pathkit
test your application
consider using advanced pathkit features
for fs-relifso:
run 'bun install' to install @reliverse/relifso
test your application
review any file system operations that might need manual updates
for nodenext-bundler:
test your application
ensure your build tools support the new module resolution
review any warnings in the migration output
for anything-bun:
run 'bun install' to install dependencies with Bun
test your application thoroughly
review async/await usage in converted file operations
update any custom database queries to use Bun.sql syntax
review and update any custom middleware in Express apps
for readdir-glob:
run 'bun install' to install globby
test your application
review any file system operations that might need manual updates
consider using globby's advanced features like pattern matching and recursive searching
12. rempts
@reliverse/rempts's best friend. learn more in its docs.
bun dler rempts
bun dler rempts --init cmd1 cmd2
13. x
dler x β your package manager β refined.
bun dler x ...
14. magic
programmatic usage:
functionmain() {
// may be useful when your cli is a project bootstrapper tool like @reliverse/rse// so you can apply spells to each bootstrapped by you cli project's fileawaitapplyMagicSpells(["my-target-dir"]);
}
awaitmain();
or, call it from dler config's hook:
{
hooksAfterBuild: [
async () => {
// useful when you want to apply spells right after dler's buildawaitapplyMagicSpells(["dist-jsr", "dist-npm", "dist-libs"]);
}
],
}
or, use dler magic:
dler magic --targets "my-target-dir"
available spell types:
replace-line β injects contents from one file into another
replace-range β replaces a range of lines with content from another file
rename-file β renames the current file
remove-comment β removes a specific comment from code
remove-line β removes a specific line from code
remove-file β deletes the current file
transform-content β applies a transformation to the file content
transform-line β applies a transformation to a specific line
copy-file β copies the current file to a new location
move-file β moves the current file to a new location
insert-at β inserts content at a specific position in the file
insert-before β inserts content before a specific line
insert-after β inserts content after a specific line
await dler.spell({ spells: ["rename-file"], files: [] });
await dler.spell({}) // all spells, all filesspells: ["all"] // means all spellsspells: [] // also means all spellsfiles: [] // means all files
Contributors: Please check the docs/cmds/SPELLS.md file for more technical details.
15. split
splits your code/text file into multiple files.
bun dler split ...
16. pack
packs a directory of templates into TypeScript modules. This command is useful for creating reusable template packages that can be distributed and used by other projects.
key features:
Converts directory structure into TypeScript modules
Handles binary files with automatic hashing and storage
Preserves JSON comments and formatting
Supports custom whitelabeling
Generates type-safe template definitions
Creates an aggregator module for easy imports
Tracks file metadata (update time and content hash)
Supports selective file updates
Handles file conflicts gracefully
Preserves JSON type information for package.json and tsconfig.json
--dir: Directory containing templates to process (required)
--output: Output directory for generated modules (default: "my-templates")
--whitelabel: Custom prefix to use instead of 'DLER' (default: "DLER")
--cdn: Remote CDN for binary assets upload (not yet implemented)
--force: Force overwrite existing files (default: false)
--update: Update existing templates and add new ones (default: true)
--files: Comma-separated list of specific files to update
--lastUpdate: Override lastUpdate timestamp
output structure:
output/
βββ impl/
β βββ binaries/ # binary files stored with hash-based names (dler reads/writes this dir when --cdn is not used)
β β βββ [hashed-files]
β βββ template1.ts
β βββ template2.ts
βββ types.ts
βββ mod.ts
--unpack:
creates file structure from packed templates. This command is the counterpart to pack and is used to extract and restore template files from a packed template package.
key features:
Restores complete directory structure from packed templates
recursive lookup for deps in multiple package.json files (e.g. monorepo; or case when you have C:/foo/bar1/package.json and C:/foo/bar2/package.json and using dler update in C:/foo).
workspaces and catalogs
dler has full workspaces and catalogs support for the package management commands. Catalog logic is similar to Bun across all package management commands.
Catalog Features:
1. Install Dependencies as Catalogs
# Add to default catalog
dler install react react-dom --as-catalog default
# Add to named catalog
dler install jest testing-library --as-catalog testing
dler install webpack babel --as-catalog build --catalog-name build
# With workspace filtering
dler install lodash --as-catalog default --filter "pkg-*"
2. Remove Dependencies from Catalogs
# Remove from default catalog
dler remove react react-dom --from-catalog default
# Remove from named catalog
dler remove jest --from-catalog testing
dler remove webpack --from-catalog build --catalog-name build
3. List Catalogs
# List all catalogs and their dependencies
dler catalog list
dler catalog ls
4. Update Catalogs
# Update all catalog dependencies to latest versions
dler update --update-catalogs
Technical Implementation:
Smart Version Management
Dler automatically fetches latest versions from npm registry
# Add dependencies to specific workspaces as catalogs
dler install lodash --as-catalog default --filter "pkg-*" --filter "!pkg-c"# Remove dependencies from catalogs in filtered workspaces
dler remove typescript --from-catalog default --filter "pkg-*"# Update catalogs and then install
dler update --update-catalogs
dler install
Benefits:
Consistency: Ensures all packages use the same version of critical dependencies
Maintenance: Update a dependency version in one place instead of across multiple package.json files
Clarity: Makes it obvious which dependencies are standardized across your monorepo
Simplicity: No need for complex version resolution strategies or external tools
Workspace Integration: Seamlessly works with workspace filtering
Cross-Package Manager: Works with Bun (full support) and provides helpful messages for others
contributors
helper scripts
libs:pack: Creates two templates, cfg and sdk, based on dist-libs directory structure (using dler pack command).
libs:unpack: Creates a project structure using all templates from the cfg and sdk templates (using dler unpack command).
libs:example: Since libs:unpack's serves as a dist-libs mock, then libs:example helps easily test dler's features like resolveAllCrossLibs().
notes
<src | dist-npm | dist-jsr>/libs/<lib-name>/<files live here> === dist-libs/<lib-name>/<jsr | npm>/bin/<files live here>
todo
dist-*-> dist/dist-*
implement stable regular build and publish
implement stable library build and publish
achieve full drop-in replacement for unbuild
support auto migration from build.config.ts
support configuration via .config/rse.{ts,jsonc} π€
make config file fully optional with sensible defaults
use dler remdn (@reliverse/remdn) to generate npm/jsr specific readme and a single docs dir for a whole project (only readmes will be published, docs are only stored in project's source cpde and can be deployed to user's website)
allow plugins to extend dler's defineconfig (hooksBeforeBuild and hooksAfterBuild are now available, plugin's options can be passed directly to plugin's params, e.g. hooksBeforeBuild: [ async () => { await myCoolPlugin({ /* plugin's options */ }); } ],)
at the moment any bundler like mkdist can be called using bun, but bun's own bundler is not yet fully supported
support all well-known package managers (currently only bun is fully supported)
dler <command> [...flags] [...args] usage should support both bun and dler own commands and flags
fully support deno and jsr
todo: commands
run ./my-script.ts Execute a file with Bun
lint Run a package.json script
test Run unit tests with Bun
x nuxi Execute a package binary (CLI), installing if needed (dler x)
repl Start a REPL session with Bun
exec Run a shell script directly with Bun
install Install dependencies for a package.json (dler i)
add elysia Add a dependency to package.json (dler a)
remove backbone Remove a dependency from package.json (dler rm)
audit Check installed packages for vulnerabilities
outdated Display latest versions of outdated dependencies
link [] Register or link a local npm package
unlink Unregister a local npm package
publish Publish a package(s) to the npm/jsr registry
patch Prepare a package for patching
pm Additional package management utilities
info hono Display package metadata from the registry
build ./a.ts ./b.jsx Bundle TypeScript & JavaScript into a single file
init Start an empty project from a built-in template
create next-app Create a new project from a template (bun c)
upgrade Upgrade to latest version both of dler and your package manager.
--help Print help text for command.
todo: flag
--watch Automatically restart the process on file change
--hot Enable auto reload in the Bun runtime, test runner, or bundler
--no-clear-screen Disable clearing the terminal screen on reload when --hot or --watch is enabled
--smol Use less memory, but run garbage collection more often
-r, --preload= Import a module before other modules are loaded
--require= Alias of --preload, for Node.js compatibility
--import= Alias of --preload, for Node.js compatibility
--inspect= Activate Bun's debugger
--inspect-wait= Activate Bun's debugger, wait for a connection before executing
--inspect-brk= Activate Bun's debugger, set breakpoint on first line of code and wait
--if-present Exit without an error if the entrypoint does not exist
--no-install Disable auto install in the Bun runtime
--install= Configure auto-install behavior. One of "auto" (default, auto-installs when no node_modules), "fallback" (missing packages only), "force" (always).
-i Auto-install dependencies during execution. Equivalent to --install=fallback.
-e, --eval= Evaluate argument as a script
-p, --print= Evaluate argument as a script and print the result
--prefer-offline Skip staleness checks for packages in the Bun runtime and resolve from disk
--prefer-latest Use the latest matching versions of packages in the Bun runtime, always checking npm
--port= Set the default port for Bun.serve
--conditions= Pass custom conditions to resolve
--fetch-preconnect= Preconnect to a URL while code is loading
--max-http-header-size= Set the maximum size of HTTP headers in bytes. Default is 16KiB
--dns-result-order= Set the default order of DNS lookup results. Valid orders: verbatim (default), ipv4first, ipv6first
--expose-gc Expose gc() on the global object. Has no effect on Bun.gc().
--no-deprecation Suppress all reporting of the custom deprecation.
--throw-deprecation Determine whether or not deprecation warnings result in errors.
--title= Set the process title
--zero-fill-buffers Boolean to force Buffer.allocUnsafe(size) to be zero-filled.
--redis-preconnect Preconnect to $REDIS_URL at startup
--sql-preconnect Preconnect to PostgreSQL at startup
--no-addons Throw an error if process.dlopen is called, and disable export condition "node-addons"
--unhandled-rejections= One of "strict", "throw", "warn", "none", or "warn-with-error-code"
--console-depth= Set the default depth for console.log object inspection (default: 2)
--silent Don't print the script command
--elide-lines= Number of lines of script output shown when using --filter (default: 10). Set to 0 to show all lines.
-v, --version Print version and exit
--revision Print version with revision and exit
-F, --filter= Run a script in all workspace packages matching the pattern
-b, --bun Force a script or package to use Bun's runtime instead of Node.js (via symlinking node)
--shell= Control the shell used for package.json scripts. Supports either 'bun' or 'system'
--env-file= Load environment variables from the specified file(s)
--cwd= Absolute path to resolve files & entry points from. This just changes the process' cwd.
-c, --config= Specify path to Bun config file. Default $cwd/bunfig.toml
-h, --help Display this menu and exit
related
special thanks to the project that inspired @reliverse/dler:
The npm package @reliverse/cfg receives a total of 259 weekly downloads. As such, @reliverse/cfg popularity was classified as not popular.
We found that @reliverse/cfg demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago.Β It has 1 open source maintainer collaborating on the project.
Package last updated on 13 Aug 2025
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.
Socket found a Rust typosquat (finch-rust) that loads sha-rust to steal credentials, using impersonation and an unpinned dependency to auto-deliver updates.
A pair of typosquatted Go packages posing as Googleβs UUID library quietly turn helper functions into encrypted exfiltration channels to a paste site, putting developer and CI data at risk.