@kubb/ast 5.0.0-beta.82 → 5.0.0-beta.84

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.
Files changed (2) hide show
  1. package/README.md +11 -8
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -28,13 +28,16 @@ Defines the node tree, visitor pattern, factory functions, and type guards used
28
28
 
29
29
  ## Imports
30
30
 
31
- | Path | Contents |
32
- | ------------------------------- | ---------------------------------------------------------------------------------------- |
33
- | `@kubb/ast` | Runtime: node definitions, guards, visitor, macro engine, constants |
34
- | `ast.factory` (via `@kubb/ast`) | Node constructors (`createSchema`, `createFile`, and friends), the `ts.factory` analogue |
35
- | `@kubb/ast/macros` | Built-in macro presets: `macroDiscriminatorEnum`, `macroSimplifyUnion`, `macroEnumName` |
36
- | `@kubb/ast/types` | Types only: all node interfaces, type aliases, visitor types |
37
- | `@kubb/ast/utils` | Spec-agnostic string and identifier helpers, ref helpers |
31
+ | Path | Contents |
32
+ | ------------------------------- | ----------------------------------------------------------------------------------------------------------------- |
33
+ | `@kubb/ast` | Runtime: node definitions, guards, visitor, macro engine, string and ref helpers, constants |
34
+ | `ast.factory` (via `@kubb/ast`) | Node constructors (`createSchema`, `createFile`, and friends), the `ts.factory` analogue |
35
+ | `@kubb/ast/types` | Types only: all node interfaces, type aliases, visitor types |
36
+ | `kubb/kit` | Re-exports the `ast` and `factory` namespaces, the way most Kubb code reaches the AST without a direct dependency |
37
+
38
+ `@kubb/ast` is an internal library. Inside the Kubb ecosystem the whole surface travels on the `ast` namespace from `kubb/kit`, so plugins and generators reach it there instead of depending on this package directly. The examples below import from `@kubb/ast` for clarity; through `kubb/kit` the same calls read as `ast.walk`, `ast.factory.createSchema`, and so on.
39
+
40
+ The macro presets (`macroDiscriminatorEnum`, `macroSimplifyUnion`, `macroEnumName`) and the string, identifier, and ref helpers live on the root `@kubb/ast` export. They no longer ship as separate `@kubb/ast/macros` and `@kubb/ast/utils` subpaths.
38
41
 
39
42
  ## Node tree
40
43
 
@@ -132,7 +135,7 @@ function process(node: Node) {
132
135
  ### Refs
133
136
 
134
137
  ```ts
135
- import { extractRefName } from '@kubb/ast/utils'
138
+ import { extractRefName } from '@kubb/ast'
136
139
 
137
140
  extractRefName('#/components/schemas/Pet') // 'Pet'
138
141
  ```
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kubb/ast",
3
- "version": "5.0.0-beta.82",
3
+ "version": "5.0.0-beta.84",
4
4
  "description": "Spec-agnostic AST layer for Kubb. Defines the node tree, visitor pattern, factory functions, and type guards used across all code generation plugins.",
5
5
  "keywords": [
6
6
  "ast",