diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 79bf6b0..86c66ba 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -22,7 +22,7 @@ pnpm pack --dry-run 1. Branch from `main` and keep the change focused. 2. Preserve documented compiler, module, target, and emit behavior unless the change is intentionally breaking. 3. Add or update compiler fixtures for preset changes. -4. Update `README.md`, `CHANGELOG.md`, `llms.txt`, and `llms-full.txt` with public behavior. +4. Update `README.md`, `CHANGELOG.md`, and `llms.txt` with public behavior. 5. Run `pnpm check` and inspect the package tarball. Do not bump versions, create tags, publish to npm, or trigger a stable release unless a maintainer explicitly requests it. diff --git a/README.md b/README.md index 7d28848..894f69d 100644 --- a/README.md +++ b/README.md @@ -2,6 +2,9 @@ Shared TypeScript configurations for Node.js, libraries, React, and Next.js. Version 2 targets the native TypeScript 7 compiler while retaining a tested TypeScript 6 migration path. +Use these independently in any project; no vllnt monorepo or runtime dependency +is required. Extend a preset, then supply project-specific paths and ambient types. + ## Install For TypeScript 7 projects: @@ -149,6 +152,21 @@ The checks compile every preset with TypeScript 6 and 7, verify declaration emit - **Minor:** additive presets or backward-compatible options. - **Patch:** fixes, documentation, tests, or CI changes without consumer-visible behavior changes. +## Documentation and support + +- [LLM index](llms.txt) · [Changelog](CHANGELOG.md) +- [Contributing](CONTRIBUTING.md) · [Issues](https://github.com/vllnt/typescript/issues) +- [Security policy and private reporting](SECURITY.md) + +npm `latest` is stable `2.0.0` at this audit. `@canary` selects moving prereleases; +pin and test them before adoption. The compatibility matrix above describes +this version's tested integrations, not a requirement to use every framework. + +## Author + +Built by [bntvllnt](https://github.com/bntvllnt) · [bntvllnt.com](https://bntvllnt.com). +Part of [@vllnt](https://github.com/vllnt). [Sponsor the work](https://github.com/sponsors/bntvllnt). + ## License -MIT +[MIT](LICENSE) diff --git a/llms-full.txt b/llms-full.txt deleted file mode 100644 index 9bbb3ce..0000000 --- a/llms-full.txt +++ /dev/null @@ -1,70 +0,0 @@ -# @vllnt/typescript full reference - -`@vllnt/typescript` publishes strict JSON compiler presets for Node.js 22+, npm libraries, React, and Next.js. Version 2 supports TypeScript `>=6.0.2 <8` and is validated with the TypeScript 6 compatibility package and native TypeScript 7.0.2. - -## Installation - -TypeScript 7-only projects install: - -```sh -pnpm add --save-dev @vllnt/typescript@^2 typescript@^7 -``` - -Tools that still import the legacy compiler API use the official side-by-side arrangement: - -```json -{ - "devDependencies": { - "@typescript/native": "npm:typescript@^7.0.2", - "@vllnt/typescript": "^2.0.0", - "typescript": "npm:@typescript/typescript6@^6.0.2" - } -} -``` - -This exposes native TypeScript 7 as `tsc`, TypeScript 6 as `tsc6`, and TypeScript 6's JavaScript API through the `typescript` package name. - -## Presets - -| Preset | Use case | Module resolution | Target | Emit | -| --- | --- | --- | --- | --- | -| `base.json` | Shared foundation | Inherited | Inherited | Inherited | -| `nodejs.json` | Node.js applications | NodeNext | ES2024 | JavaScript, declarations, maps | -| `node-library.json` | Publishable npm packages | NodeNext | ES2024 | JavaScript, declarations and maps | -| `react.json` | Bundled React applications | Bundler | ES2022 | JavaScript, declarations, maps | -| `nextjs.json` | Next.js applications | Bundler | ES2022 | None | - -## Shared compiler contract - -All specialized presets inherit: - -- `strict: true` -- `isolatedModules: true` -- `noUncheckedIndexedAccess: true` -- `noUncheckedSideEffectImports: true` -- `forceConsistentCasingInFileNames: true` -- `skipLibCheck: true` -- `esModuleInterop: true` -- `resolveJsonModule: true` -- `stableTypeOrdering: true` -- `libReplacement: false` -- `types: []` - -Ambient types are opt-in. Consumers should add entries such as `node`, `react`, or `vitest/globals` to `types`. Emitting projects must set `rootDir` explicitly. - -## Migration from version 1 - -Version 2 drops TypeScript 5. Consumers must remove `baseUrl`, avoid legacy module formats and resolution, use explicit `rootDir` and `types`, and run Next.js 16.3 or newer for native TypeScript 7 builds. Keep the TypeScript 6 compatibility API installed while tools such as `typescript-eslint` need it. - -## Package validation - -The repository compiles every preset with TypeScript 6 and 7, verifies strictness and declaration emit, installs the generated tarball into an isolated consumer, enforces its exact file surface, and builds real React/Vite and Next.js fixtures. The package has no runtime dependencies; TypeScript is a peer dependency. - -## Resources - -- Main documentation: `README.md` -- Release history: `CHANGELOG.md` -- Contributions: `CONTRIBUTING.md` -- Security policy: `SECURITY.md` -- Repository: https://github.com/vllnt/typescript -- License: MIT diff --git a/llms.txt b/llms.txt index 83251f7..3836455 100644 --- a/llms.txt +++ b/llms.txt @@ -6,9 +6,12 @@ - Repository: https://github.com/vllnt/typescript - Documentation: https://github.com/vllnt/typescript#readme - Changelog: https://github.com/vllnt/typescript/blob/main/CHANGELOG.md -- Full reference: https://github.com/vllnt/typescript/blob/main/llms-full.txt - License: MIT +Install independently in any project; no vllnt monorepo is required. npm latest +is stable 2.0.0 at this audit; canary is a moving prerelease channel. Pin and test +prereleases. See [Contributing](CONTRIBUTING.md) and the [Security policy](SECURITY.md). + ## Compatibility - Node.js consumers: 22 or newer diff --git a/package.json b/package.json index 32095d6..1ecf626 100644 --- a/package.json +++ b/package.json @@ -36,8 +36,7 @@ "node-library.json", "react.json", "CHANGELOG.md", - "llms.txt", - "llms-full.txt" + "llms.txt" ], "exports": { "./base.json": "./base.json", diff --git a/tests/configs.test.mjs b/tests/configs.test.mjs index dc073cf..04b041e 100644 --- a/tests/configs.test.mjs +++ b/tests/configs.test.mjs @@ -26,7 +26,6 @@ const expectedPackageFiles = [ "base.json", "CHANGELOG.md", "LICENSE", - "llms-full.txt", "llms.txt", "nextjs.json", "node-library.json",