fact-kit-facts 0.6.1 → 0.6.2-alpha.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.
Files changed (2) hide show
  1. package/dist/index.json +47 -2
  2. package/package.json +1 -1
package/dist/index.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "entry": ".",
5
5
  "component": "fact-kit-facts.npm",
6
6
  "describes": {
7
- "fact-kit-js": "0.11.0"
7
+ "fact-kit-js": "0.11.1-alpha.1"
8
8
  },
9
9
  "publish": {
10
10
  "target": "npm",
@@ -4603,6 +4603,51 @@
4603
4603
  ]
4604
4604
  }
4605
4605
  }
4606
+ },
4607
+ {
4608
+ "since": "0.11.1-alpha.1",
4609
+ "content": {
4610
+ "value": {
4611
+ "requires": {
4612
+ "peerDependency": "typescript",
4613
+ "range": ">=7.1.0-beta",
4614
+ "optional": true,
4615
+ "install": "pnpm add -D typescript@7.1.0-beta"
4616
+ },
4617
+ "exports": [
4618
+ {
4619
+ "name": "readStringTuples",
4620
+ "signature": "readStringTuples(source: string) => Promise<Record<string, string[]>>",
4621
+ "summary": "The string literal tuples exported by a TypeScript source, by name: `export declare const X: readonly [...]` and `export const X = [...] as const`. Parses only, so imports do not have to resolve."
4622
+ },
4623
+ {
4624
+ "name": "readStringTuplesFromFile",
4625
+ "signature": "readStringTuplesFromFile(path: string) => Promise<Record<string, string[]>>",
4626
+ "summary": "Reads the file and returns `readStringTuples` of it."
4627
+ },
4628
+ {
4629
+ "name": "interfaceToJsonSchema",
4630
+ "signature": "interfaceToJsonSchema({ path, type, tsconfig?, additionalProperties?, descriptions? }) => Promise<JsonSchema>",
4631
+ "summary": "An interface or type alias as a JSON Schema 2020-12 document. A named interface or alias becomes a `$defs` entry, and a generic instantiation such as `Record<string, unknown>` is written in place. A type that refers to itself is a `$defs` entry that every place it appears references with `$ref`, an instantiation such as `Tree<string>` included. An instantiation is named as TypeScript prints it, such as `Tree<string>`, and a root type that refers to itself is also written out at the top. A generic type that makes a new instantiation at each level, such as `next?: Nest<Box<T>>` inside `Nest<T>`, throws an error that names it. A method is left out, and a property whose type is a function becomes `{ \"$comment\": \"<signature>\" }` with the signature as TypeScript prints it, such as `(n: number) => string`. Union members and enum values keep the order of the source, `0 | number` keeps both members, and a tuple becomes `prefixItems`. JSDoc becomes `description`, and `descriptions: false` removes every `description`. Type errors in the input are not reported. An error thrown while converting is not replaced by an error from closing the compiler process."
4632
+ },
4633
+ {
4634
+ "name": "readJsonSchemaFile",
4635
+ "signature": "readJsonSchemaFile(path: string) => Promise<JsonSchema>",
4636
+ "summary": "Reads a JSON Schema file. Does not need TypeScript."
4637
+ }
4638
+ ],
4639
+ "optionalPeers": [
4640
+ {
4641
+ "peerDependency": "prettier",
4642
+ "range": ">=3.0.0",
4643
+ "install": "pnpm add -D prettier@3",
4644
+ "usedBy": [
4645
+ "writeFormatted"
4646
+ ]
4647
+ }
4648
+ ]
4649
+ }
4650
+ }
4606
4651
  }
4607
4652
  ],
4608
4653
  "tool": "fact-kit",
@@ -4631,7 +4676,7 @@
4631
4676
  {
4632
4677
  "name": "interfaceToJsonSchema",
4633
4678
  "signature": "interfaceToJsonSchema({ path, type, tsconfig?, additionalProperties?, descriptions? }) => Promise<JsonSchema>",
4634
- "summary": "An interface or type alias as a JSON Schema 2020-12 document. Referenced types become `$defs`. Union members and enum values keep the order of the source, `0 | number` keeps both members, and a tuple becomes `prefixItems`. JSDoc becomes `description`, and `descriptions: false` removes every `description`. Type errors in the input are not reported."
4679
+ "summary": "An interface or type alias as a JSON Schema 2020-12 document. A named interface or alias becomes a `$defs` entry, and a generic instantiation such as `Record<string, unknown>` is written in place. A type that refers to itself is a `$defs` entry that every place it appears references with `$ref`, an instantiation such as `Tree<string>` included. An instantiation is named as TypeScript prints it, such as `Tree<string>`, and a root type that refers to itself is also written out at the top. A generic type that makes a new instantiation at each level, such as `next?: Nest<Box<T>>` inside `Nest<T>`, throws an error that names it. A method is left out, and a property whose type is a function becomes `{ \"$comment\": \"<signature>\" }` with the signature as TypeScript prints it, such as `(n: number) => string`. Union members and enum values keep the order of the source, `0 | number` keeps both members, and a tuple becomes `prefixItems`. JSDoc becomes `description`, and `descriptions: false` removes every `description`. Type errors in the input are not reported. An error thrown while converting is not replaced by an error from closing the compiler process."
4635
4680
  },
4636
4681
  {
4637
4682
  "name": "readJsonSchemaFile",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fact-kit-facts",
3
- "version": "0.6.1",
3
+ "version": "0.6.2-alpha.1",
4
4
  "description": "Facts about fact-kit: the spec of its index format, commands and API",
5
5
  "license": "MIT",
6
6
  "type": "module",