@d1g1tal/tsbuild 1.0.0 → 1.0.1

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 CHANGED
@@ -1,5 +1,13 @@
1
1
  # tsbuild
2
2
 
3
+ [![npm version](https://img.shields.io/npm/v/%40d1g1tal/tsbuild?color=blue)](https://www.npmjs.com/package/@d1g1tal/tsbuild)
4
+ [![npm downloads](https://img.shields.io/npm/dm/%40d1g1tal/tsbuild)](https://www.npmjs.com/package/@d1g1tal/tsbuild)
5
+ [![CI](https://github.com/D1g1talEntr0py/tsbuild/actions/workflows/ci.yml/badge.svg)](https://github.com/D1g1talEntr0py/tsbuild/actions/workflows/ci.yml)
6
+ [![codecov](https://codecov.io/gh/D1g1talEntr0py/tsbuild/graph/badge.svg)](https://codecov.io/gh/D1g1talEntr0py/tsbuild)
7
+ [![License: MIT](https://img.shields.io/github/license/D1g1talEntr0py/tsbuild)](https://github.com/D1g1talEntr0py/tsbuild/blob/main/LICENSE)
8
+ [![Node.js](https://img.shields.io/node/v/%40d1g1tal/tsbuild)](https://nodejs.org)
9
+ [![TypeScript](https://img.shields.io/badge/TypeScript-5.9-blue?logo=typescript&logoColor=white)](https://www.typescriptlang.org/)
10
+
3
11
  A self-hosting TypeScript build tool that combines the best of three worlds: **TypeScript's type system**, **esbuild's speed**, and **SWC's decorator metadata support**. tsbuild is designed for modern ESM-only projects targeting Node.js 20.16.0+.
4
12
 
5
13
  > **⚠️ Note:** This is an experimental project for personal use. For production use, consider [tsup](https://tsup.egoist.dev/) instead, which is mature, battle-tested, and widely adopted. Or check out the new [tsdown](https://tsdown.dev/) by [void(0)](https://voidzero.dev/).
@@ -29,11 +37,29 @@ This separation of concerns ensures TypeScript handles correctness, esbuild hand
29
37
 
30
38
  ## Installation
31
39
 
40
+ ### Global Installation (Recommended for CLI usage)
41
+
42
+ Installing globally makes the `tsbuild` command available in your terminal across all projects:
43
+
44
+ ```bash
45
+ # pnpm
46
+ pnpm add -g @d1g1tal/tsbuild
47
+
48
+ # npm
49
+ npm install -g @d1g1tal/tsbuild
50
+ ```
51
+
52
+ With a global install, your projects can use `tsbuild` in `package.json` scripts without adding it as a dependency.
53
+
54
+ ### Local Installation (Per-project)
55
+
56
+ Install as a dev dependency for per-project version pinning (recommended for CI/CD environments):
57
+
32
58
  ```bash
33
- # pnpm - no SWC dependency (optional for decorator metadata)
59
+ # pnpm - no SWC dependency (Optional. For legacy decorator metadata. Native ESM decorators are supported without SWC)
34
60
  pnpm add -D @d1g1tal/tsbuild --no-optional
35
61
 
36
- # pnpm - with SWC dependency (for decorator metadata)
62
+ # pnpm - with SWC dependency (For legacy decorator metadata)
37
63
  pnpm add -D @d1g1tal/tsbuild
38
64
 
39
65
  # npm
@@ -43,6 +69,8 @@ npm install -D @d1g1tal/tsbuild
43
69
  yarn add -D @d1g1tal/tsbuild
44
70
  ```
45
71
 
72
+ > **Note:** When installed only as a local dev dependency, the `tsbuild` command is not available directly in your terminal. Use it through `package.json` scripts (e.g., `pnpm build`) or invoke it explicitly with `pnpm exec tsbuild` / `npx tsbuild`.
73
+
46
74
  ### Requirements
47
75
 
48
76
  - **Node.js**: >=20.16.0
@@ -1869,7 +1869,7 @@ var _TypeScriptProject = class _TypeScriptProject {
1869
1869
  return Files.empty(this.buildConfiguration.outDir);
1870
1870
  }
1871
1871
  async build() {
1872
- Logger.header(`\u{1F680} tsbuild v${"1.0.0"}${this.configuration.compilerOptions.incremental ? " [incremental]" : ""}`);
1872
+ Logger.header(`\u{1F680} tsbuild v${"1.0.1"}${this.configuration.compilerOptions.incremental ? " [incremental]" : ""}`);
1873
1873
  try {
1874
1874
  const processes = [];
1875
1875
  const filesWereEmitted = await this.typeCheck();
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { Plugin, TsconfigRaw } from "esbuild";
2
- import { FileSystemEvent, WatchrOptions } from "watchr";
2
+ import { FileSystemEvent, WatchrOptions } from "@d1g1tal/watchr";
3
3
  import { CompilerOptions, Diagnostic, ProjectReference, ScriptTarget } from "typescript";
4
4
  import { PerformanceEntry, PerformanceMeasureOptions } from "node:perf_hooks";
5
5
 
package/dist/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  TypeScriptProject
3
- } from "./QDB5Y2PO.js";
3
+ } from "./74AUVQXS.js";
4
4
  import "./44KSX2XO.js";
5
5
  export {
6
6
  TypeScriptProject
package/dist/tsbuild.js CHANGED
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  BuildError,
4
4
  TypeScriptProject
5
- } from "./QDB5Y2PO.js";
5
+ } from "./74AUVQXS.js";
6
6
  import "./44KSX2XO.js";
7
7
 
8
8
  // src/tsbuild.ts
@@ -30,7 +30,7 @@ if (help) {
30
30
  process.exit(0);
31
31
  }
32
32
  if (version) {
33
- console.log("1.0.0");
33
+ console.log("1.0.1");
34
34
  process.exit(0);
35
35
  }
36
36
  var typeScriptOptions = {
package/package.json CHANGED
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "name": "@d1g1tal/tsbuild",
3
- "version": "1.0.0",
3
+ "version": "1.0.1",
4
+ "packageManager": "pnpm@10.29.3",
4
5
  "description": "A fast, ESM-only TypeScript build tool combining the TypeScript API for type checking and declaration generation, esbuild for bundling, and SWC for decorator metadata.",
5
6
  "type": "module",
6
7
  "exports": {
@@ -16,6 +17,16 @@
16
17
  "bin": {
17
18
  "tsbuild": "./dist/tsbuild.js"
18
19
  },
20
+ "scripts": {
21
+ "prepare": "git config core.hooksPath .githooks",
22
+ "build": "tsx ./src/tsbuild.ts",
23
+ "build:watch": "tsx ./src/tsbuild.ts --watch",
24
+ "type-check": "tsx ./src/tsbuild.ts --noEmit",
25
+ "lint": "eslint ./src",
26
+ "test": "vitest run",
27
+ "test:coverage": "vitest run --coverage",
28
+ "prepublishOnly": "pnpm lint && pnpm build"
29
+ },
19
30
  "keywords": [
20
31
  "typescript",
21
32
  "build",
@@ -34,6 +45,10 @@
34
45
  "type": "git",
35
46
  "url": "git+https://github.com/D1g1talEntr0py/tsbuild.git"
36
47
  },
48
+ "publishConfig": {
49
+ "registry": "https://registry.npmjs.org",
50
+ "access": "public"
51
+ },
37
52
  "bugs": {
38
53
  "url": "https://github.com/D1g1talEntr0py/tsbuild/issues"
39
54
  },
@@ -45,29 +60,21 @@
45
60
  },
46
61
  "devDependencies": {
47
62
  "@eslint/js": "^10.0.1",
48
- "@types/node": "^25.2.3",
49
- "@typescript-eslint/eslint-plugin": "^8.55.0",
50
- "@typescript-eslint/parser": "^8.55.0",
63
+ "@types/node": "^25.3.0",
64
+ "@typescript-eslint/eslint-plugin": "^8.56.1",
65
+ "@typescript-eslint/parser": "^8.56.1",
51
66
  "@vitest/coverage-v8": "4.0.18",
52
- "eslint": "^10.0.0",
53
- "eslint-plugin-jsdoc": "^62.5.5",
67
+ "eslint": "^10.0.1",
68
+ "eslint-plugin-jsdoc": "^62.7.0",
54
69
  "fs-monkey": "^1.1.0",
55
70
  "memfs": "^4.56.10",
56
71
  "tsx": "^4.21.0",
57
72
  "typescript": "5.9.3",
58
- "typescript-eslint": "^8.55.0",
73
+ "typescript-eslint": "^8.56.1",
59
74
  "vitest": "^4.0.18"
60
75
  },
61
76
  "optionalDependencies": {
62
- "@swc/core": "^1.15.11",
77
+ "@swc/core": "^1.15.13",
63
78
  "@swc/types": "^0.1.25"
64
- },
65
- "scripts": {
66
- "build": "tsx ./src/tsbuild.ts",
67
- "build:watch": "tsx ./src/tsbuild.ts --watch",
68
- "type-check": "tsx ./src/tsbuild.ts --noEmit",
69
- "lint": "eslint ./src",
70
- "test": "vitest run",
71
- "test:coverage": "vitest run --coverage"
72
79
  }
73
- }
80
+ }