@reliverse/dler 1.7.28 โ 1.7.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +44 -20
- package/bin/libs/cfg/cfg-impl/cfg-consts.d.ts +2 -0
- package/bin/libs/cfg/cfg-impl/cfg-consts.js +7 -1
- package/bin/libs/cfg/cfg-impl/cfg-types.d.ts +14 -1
- package/bin/libs/cfg/cfg-impl/rse-config/rse-impl/rse-define.d.ts +3 -3
- package/bin/libs/sdk/sdk-impl/config/default.js +4 -1
- package/bin/libs/sdk/sdk-impl/config/info.js +1 -1
- package/bin/libs/sdk/sdk-impl/config/init.js +9 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,25 +1,46 @@
|
|
|
1
|
-
# dler (prev. relidler) โข
|
|
1
|
+
# ๐๏ธ dler (prev. relidler) โข build/publish/improve ts/js libs/cli/apps
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
[sponsor](https://github.com/sponsors/blefnk) โ [discord](https://discord.gg/pb8ukbwpsj) โ [github](https://github.com/reliverse/dler) โ [npm](https://npmjs.com/@reliverse/dler)
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
> @reliverse/dler (`/หdiห.lษr/`, dealer) is a flexible, unified, and fully automated bundler for typescript/javascript projects that doubles as an npm/jsr publishing tool. beyond bundling, dler serves as a comprehensive codemod toolkit for modern typescript/javascript development.
|
|
6
6
|
|
|
7
7
|
## features
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
-
|
|
12
|
-
-
|
|
13
|
-
-
|
|
14
|
-
-
|
|
15
|
-
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
-
|
|
20
|
-
-
|
|
21
|
-
-
|
|
22
|
-
-
|
|
9
|
+
### ๐ core power
|
|
10
|
+
|
|
11
|
+
- **drop-in replacement** for `unjs/unbuild` โ seamless migration with enhanced capabilities
|
|
12
|
+
- **automated publishing** to npm/jsr registries with intelligent workflow management
|
|
13
|
+
- **reliable builds** with comprehensive typescript/javascript support and error handling
|
|
14
|
+
- **smart versioning** with automatic version bumps and semantic release integration
|
|
15
|
+
- **zero configuration** eliminates `package.json` maintenance headaches forever
|
|
16
|
+
|
|
17
|
+
### โก developer experience
|
|
18
|
+
|
|
19
|
+
- **performance optimized** for speed with modern build pipelines and caching
|
|
20
|
+
- **18 built-in commands** โ comprehensive [dler commands](#dler-commands) for every workflow
|
|
21
|
+
- **path resolution magic** converts typescript aliases to relative imports automatically
|
|
22
|
+
- **highly configurable** via dedicated configuration files with sensible defaults
|
|
23
|
+
- **dual interface** โ cli for everyday use, sdk for advanced programmatic control
|
|
24
|
+
|
|
25
|
+
### ๐ง advanced capabilities
|
|
26
|
+
|
|
27
|
+
- **clean distribution builds** automatically removes internal logs and debug code
|
|
28
|
+
- **monorepo ready** with experimental `libs` feature for multi-library projects
|
|
29
|
+
- **magic spells** โ extensible plugin system for custom build transformations
|
|
30
|
+
- **codemod toolkit** โ powerful code transformation utilities built-in
|
|
31
|
+
|
|
32
|
+
### ๐ฏ perfect for
|
|
33
|
+
|
|
34
|
+
dler excels at managing both build and publish workflows, making it ideal for:
|
|
35
|
+
|
|
36
|
+
- cli tool creators and maintainers
|
|
37
|
+
- project bootstrappers (like [rse](https://github.com/reliverse/rse))
|
|
38
|
+
- library authors seeking streamlined workflows
|
|
39
|
+
- teams wanting consistent build processes
|
|
40
|
+
|
|
41
|
+
### ๐ coming soon
|
|
42
|
+
|
|
43
|
+
**full monorepo system** with advanced dependency management and cross-package optimization.
|
|
23
44
|
|
|
24
45
|
### supported bundlers
|
|
25
46
|
|
|
@@ -40,7 +61,7 @@
|
|
|
40
61
|
|
|
41
62
|
## getting started
|
|
42
63
|
|
|
43
|
-
ensure git, node.js, and bun/pnpm/yarn/npm are installed. then:
|
|
64
|
+
ensure git, node.js, and bun/pnpm/yarn/npm (**[bun](https://bun.sh/get) is highly recommended**) are installed. then:
|
|
44
65
|
|
|
45
66
|
### playground
|
|
46
67
|
|
|
@@ -75,6 +96,9 @@ bun dev # bun src/cli.ts --dev
|
|
|
75
96
|
bun i -g update --latest
|
|
76
97
|
```
|
|
77
98
|
|
|
99
|
+
- **when installed globally**: use `dler` anywhere.
|
|
100
|
+
- **when installed as dev dep**: use with package manager name prefix, e.g. `bun dler`, inside your project directory.
|
|
101
|
+
|
|
78
102
|
2. **prepare your project**:
|
|
79
103
|
|
|
80
104
|
a. **configure `.gitignore`**:
|
|
@@ -117,7 +141,7 @@ bun dev # bun src/cli.ts --dev
|
|
|
117
141
|
dler [build|pub] # if installed globally
|
|
118
142
|
```
|
|
119
143
|
|
|
120
|
-
##
|
|
144
|
+
## dler commands
|
|
121
145
|
|
|
122
146
|
dler ships with a flexible command system (prev. plugins) and **18 built-in commands** (from [reliverse addons](https://reliverse.org/addons) collection).
|
|
123
147
|
|
|
@@ -828,7 +852,7 @@ special thanks to the project that inspired `@reliverse/dler`:
|
|
|
828
852
|
|
|
829
853
|
### notes
|
|
830
854
|
|
|
831
|
-
`<src | dist-npm | dist-jsr>/libs/<lib-name>/<files live here>` === `dist-libs/<lib-name>/<jsr | npm>/bin/<files live here>`
|
|
855
|
+
- `<src | dist-npm | dist-jsr>/libs/<lib-name>/<files live here>` === `dist-libs/<lib-name>/<jsr | npm>/bin/<files live here>`
|
|
832
856
|
|
|
833
857
|
## support
|
|
834
858
|
|
|
@@ -69,7 +69,13 @@ export const DEFAULT_CONFIG_DLER = {
|
|
|
69
69
|
"dist-jsr": [],
|
|
70
70
|
"dist-npm": [],
|
|
71
71
|
"dist-libs": {}
|
|
72
|
-
}
|
|
72
|
+
},
|
|
73
|
+
// Files with these extensions will be built
|
|
74
|
+
// Any other files will be copied as-is to dist
|
|
75
|
+
buildPreExtensions: ["ts", "js"],
|
|
76
|
+
// If you need to exclude some ts/js files from being built,
|
|
77
|
+
// you can store them in the dirs with buildTemplatesDir name
|
|
78
|
+
buildTemplatesDir: "templates"
|
|
73
79
|
};
|
|
74
80
|
export const defineConfigDler = (userConfig = {}) => {
|
|
75
81
|
return { ...DEFAULT_CONFIG_DLER, ...userConfig };
|
|
@@ -315,7 +315,7 @@ export interface DlerConfig {
|
|
|
315
315
|
runBeforeBuild: ("tsc" | "eslint" | "biome" | "knip" | "dler-check")[];
|
|
316
316
|
/**
|
|
317
317
|
* List of tools to run after the build process completes.
|
|
318
|
-
*
|
|
318
|
+
* Available options: "dler-check"
|
|
319
319
|
* Each tool will only run if it's installed in the system.
|
|
320
320
|
*
|
|
321
321
|
* @default []
|
|
@@ -476,6 +476,19 @@ export interface DlerConfig {
|
|
|
476
476
|
npm: string[];
|
|
477
477
|
}>;
|
|
478
478
|
};
|
|
479
|
+
/**
|
|
480
|
+
* File extensions that should be copied to temporary build directories during pre-build.
|
|
481
|
+
* These files will be processed by the bundlers.
|
|
482
|
+
* All other files will be copied as-is to final dist directories during post-build.
|
|
483
|
+
* @default ["ts", "js"]
|
|
484
|
+
*/
|
|
485
|
+
buildPreExtensions: string[];
|
|
486
|
+
/**
|
|
487
|
+
* Directory name for templates that should be excluded from pre-build processing.
|
|
488
|
+
* Files in this directory will be copied as-is during post-build.
|
|
489
|
+
* @default "templates"
|
|
490
|
+
*/
|
|
491
|
+
buildTemplatesDir: string;
|
|
479
492
|
}
|
|
480
493
|
export type BumpMode = "patch" | "minor" | "major" | "auto" | "manual";
|
|
481
494
|
/**
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import type { RseConfig } from "./rse-types";
|
|
2
2
|
export declare const defineConfigRse: (userConfig?: Partial<RseConfig>) => {
|
|
3
|
-
version?: string | undefined;
|
|
4
3
|
$schema?: "./schema.json" | "https://reliverse.org/schema.json" | undefined;
|
|
5
4
|
projectName?: string | undefined;
|
|
6
5
|
projectAuthor?: string | undefined;
|
|
7
6
|
projectDescription?: string | undefined;
|
|
7
|
+
version?: string | undefined;
|
|
8
8
|
projectLicense?: string | undefined;
|
|
9
9
|
projectRepository?: string | undefined;
|
|
10
10
|
projectDomain?: string | undefined;
|
|
11
11
|
projectGitService?: "none" | "github" | "gitlab" | "bitbucket" | undefined;
|
|
12
12
|
projectDeployService?: "none" | "vercel" | "netlify" | "railway" | "deno" | undefined;
|
|
13
13
|
projectPackageManager?: "npm" | "bun" | "yarn" | "pnpm" | undefined;
|
|
14
|
-
projectState?: "
|
|
14
|
+
projectState?: "creating" | "created" | undefined;
|
|
15
15
|
projectCategory?: "browser" | "cli" | "unknown" | "website" | "vscode" | "library" | "mobile" | undefined;
|
|
16
16
|
projectSubcategory?: "unknown" | "e-commerce" | "tool" | undefined;
|
|
17
17
|
projectFramework?: "rempts" | "npm-jsr" | "unknown" | "vscode" | "nextjs" | "vite" | "svelte" | "remix" | "astro" | "nuxt" | "solid" | "qwik" | "vue" | "wxt" | "lynx" | "react-native" | "expo" | "capacitor" | "ionic" | "electron" | "tauri" | "neutralino" | "citty" | "commander" | "cac" | "meow" | "yargs" | "webextension" | "browser-extension" | undefined;
|
|
@@ -33,7 +33,6 @@ export declare const defineConfigRse: (userConfig?: Partial<RseConfig>) => {
|
|
|
33
33
|
themes?: string[] | undefined;
|
|
34
34
|
} | undefined;
|
|
35
35
|
preferredLibraries?: {
|
|
36
|
-
search?: "unknown" | "algolia" | undefined;
|
|
37
36
|
i18n?: "unknown" | "next-intl" | undefined;
|
|
38
37
|
analytics?: "unknown" | "vercel" | undefined;
|
|
39
38
|
authentication?: "unknown" | "better-auth" | "clerk" | "next-auth" | "supabase-auth" | "auth0" | undefined;
|
|
@@ -52,6 +51,7 @@ export declare const defineConfigRse: (userConfig?: Partial<RseConfig>) => {
|
|
|
52
51
|
logging?: "unknown" | "axiom" | undefined;
|
|
53
52
|
forms?: "unknown" | "react-hook-form" | undefined;
|
|
54
53
|
notifications?: "unknown" | "sonner" | undefined;
|
|
54
|
+
search?: "unknown" | "algolia" | undefined;
|
|
55
55
|
uploads?: "unknown" | "uploadthing" | undefined;
|
|
56
56
|
validation?: "unknown" | "zod" | "typebox" | "valibot" | undefined;
|
|
57
57
|
documentation?: "unknown" | "starlight" | "nextra" | undefined;
|
|
@@ -68,8 +68,11 @@ export const DEFAULT_CONFIG_DLER = {
|
|
|
68
68
|
"dist-npm": [],
|
|
69
69
|
"dist-libs": {}
|
|
70
70
|
},
|
|
71
|
-
//
|
|
71
|
+
// Files with these extensions will be built
|
|
72
|
+
// Any other files will be copied as-is to dist
|
|
72
73
|
buildPreExtensions: ["ts", "js"],
|
|
74
|
+
// If you need to exclude some ts/js files from being built,
|
|
75
|
+
// you can store them in the dirs with buildTemplatesDir name
|
|
73
76
|
buildTemplatesDir: "templates"
|
|
74
77
|
};
|
|
75
78
|
export const defineConfigDler = (userConfig = {}) => {
|
|
@@ -218,12 +218,21 @@ function generateConfig(isDev, pkgDescription) {
|
|
|
218
218
|
' // - dist-jsr,dist-libs/jsr: ["jsr.json"]',
|
|
219
219
|
" publishArtifacts: " + getPublishArtifacts(isDev) + ",",
|
|
220
220
|
"",
|
|
221
|
+
" // Files with these extensions will be built",
|
|
222
|
+
" // Any other files will be copied as-is to dist",
|
|
223
|
+
' buildPreExtensions: ["ts", "js"],',
|
|
224
|
+
" // If you need to exclude some ts/js files from being built,",
|
|
225
|
+
" // you can store them in the dirs with buildTemplatesDir name",
|
|
226
|
+
' buildTemplatesDir: "templates",',
|
|
227
|
+
"",
|
|
221
228
|
" // Dependency filtering",
|
|
222
229
|
" // Global is always applied",
|
|
223
230
|
" filterDepsPatterns: " + getFilterDepsPatterns(isDev) + ",",
|
|
224
231
|
"",
|
|
225
232
|
" // Code quality tools",
|
|
233
|
+
" // Available: tsc, eslint, biome, knip, dler-check",
|
|
226
234
|
" runBeforeBuild: [],",
|
|
235
|
+
" // Available: dler-check",
|
|
227
236
|
" runAfterBuild: [],",
|
|
228
237
|
"",
|
|
229
238
|
" // Build hooks",
|