@power-plant/graphql-input 0.0.8 → 0.0.12

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
@@ -33,7 +33,7 @@ The Power Plant monorepo is a collection of packages that are designed to work t
33
33
 
34
34
  <h3 align="center">💻 Visit <a href="https://stormsoftware.com" target="_blank">stormsoftware.com</a> to stay up to date with this developer</h3><br />
35
35
 
36
- [![Version](https://img.shields.io/badge/version-0.0.7-1fb2a6.svg?style=for-the-badge&color=1fb2a6)](https://docs.stormsoftware.com/projects/power-plant)&nbsp;[![Commitizen friendly](https://img.shields.io/badge/commitizen-friendly-brightgreen.svg?style=for-the-badge&logo=commitlint&color=1fb2a6)](http://commitizen.github.io/cz-cli/)&nbsp;![semantic-release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg?style=for-the-badge&color=1fb2a6)&nbsp;![GitHub Workflow Status (with event)](https://img.shields.io/github/actions/workflow/status/storm-software/power-plant/release.yml?style=for-the-badge&logo=github-actions&color=1fb2a6)
36
+ [![Version](https://img.shields.io/badge/version-0.0.10-1fb2a6.svg?style=for-the-badge&color=1fb2a6)](https://docs.stormsoftware.com/projects/power-plant)&nbsp;[![Commitizen friendly](https://img.shields.io/badge/commitizen-friendly-brightgreen.svg?style=for-the-badge&logo=commitlint&color=1fb2a6)](http://commitizen.github.io/cz-cli/)&nbsp;![semantic-release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg?style=for-the-badge&color=1fb2a6)&nbsp;![GitHub Workflow Status (with event)](https://img.shields.io/github/actions/workflow/status/storm-software/power-plant/release.yml?style=for-the-badge&logo=github-actions&color=1fb2a6)
37
37
 
38
38
  <!-- prettier-ignore-start -->
39
39
  <!-- markdownlint-disable -->
package/dist/index.cjs CHANGED
@@ -1 +1 @@
1
- Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require("./utilities.cjs"),t=require("./loaders.cjs"),n=require("./input.cjs");let r=require("@stryke/resolve/type-checks"),i=require("@stryke/type-checks/is-string"),a=require("@stryke/type-checks/is-url");var o=(0,require("@power-plant/core").defineInput)({meta:{name:`graphql-input`,description:`An input extension that reads the specification from a GraphQL schema document using loaders defined in GraphQL-Tools packages.`,readFrom:(e,t)=>`Reads the GraphQL schema from ${(0,i.isString)(t.inputPath)?`"${t.inputPath}"`:(0,a.isURL)(t.inputPath)?`the remote source at "${t.inputPath.toString()}"`:(0,r.isFileReference)(t.inputPath)?`the file at "${t.inputPath.file}"`:`a specified schema source`}.`,version:`1.0`,tags:[`graphql`],links:[{href:`https://the-guild.dev/graphql/tools`,description:`GraphQL Tools`},{href:`https://github.com/ardatan/graphql-tools`,description:`GraphQL Tools - repository`},{href:`https://the-guild.dev/graphql/tools/docs/schema-loading`,description:`GraphQL Tools - Schema Loading`},{href:`https://the-guild.dev/graphql/tools/docs/documents-loading`,description:`GraphQL specification - Documents Loading`}]},input:n.input});exports.createSchemaLoaders=t.createSchemaLoaders,exports.default=o,exports.toSchemaPointer=e.toSchemaPointer;
1
+ const e=require("./input.cjs");var t=(0,require("@power-plant/core").defineInput)({meta:{name:`graphql-input`,description:`An input extension that reads the specification from a GraphQL schema document using loaders defined in GraphQL-Tools packages.`,usage:`Reads the GraphQL schema from a file path, remote URL, or schema loader source configured via inputPath.`,version:`1.0`,tags:[`graphql`],links:[{href:`https://the-guild.dev/graphql/tools`,description:`GraphQL Tools`},{href:`https://github.com/ardatan/graphql-tools`,description:`GraphQL Tools - repository`},{href:`https://the-guild.dev/graphql/tools/docs/schema-loading`,description:`GraphQL Tools - Schema Loading`},{href:`https://the-guild.dev/graphql/tools/docs/documents-loading`,description:`GraphQL specification - Documents Loading`}]},input:e.input});module.exports=t;
package/dist/index.d.cts CHANGED
@@ -1,8 +1,5 @@
1
1
  import { Options } from "./types.cjs";
2
- import { createSchemaLoaders } from "./loaders.cjs";
3
- import { toSchemaPointer } from "./utilities.cjs";
4
2
  //#region src/index.d.ts
5
3
  declare const _default: import("@power-plant/core").InputConfigObject<import("graphql").GraphQLSchema, Options>;
6
- //#endregion
7
- export { type Options, createSchemaLoaders, _default as default, toSchemaPointer };
4
+ export = _default;
8
5
  //# sourceMappingURL=index.d.cts.map
package/dist/index.d.mts CHANGED
@@ -1,8 +1,6 @@
1
1
  import { Options } from "./types.mjs";
2
- import { createSchemaLoaders } from "./loaders.mjs";
3
- import { toSchemaPointer } from "./utilities.mjs";
4
2
  //#region src/index.d.ts
5
3
  declare const _default: import("@power-plant/core").InputConfigObject<import("graphql").GraphQLSchema, Options>;
6
4
  //#endregion
7
- export { type Options, createSchemaLoaders, _default as default, toSchemaPointer };
5
+ export { _default as default };
8
6
  //# sourceMappingURL=index.d.mts.map
package/dist/index.mjs CHANGED
@@ -1,2 +1,2 @@
1
- import{toSchemaPointer as e}from"./utilities.mjs";import{createSchemaLoaders as t}from"./loaders.mjs";import{input as n}from"./input.mjs";import{isFileReference as r}from"@stryke/resolve/type-checks";import{isString as i}from"@stryke/type-checks/is-string";import{isURL as a}from"@stryke/type-checks/is-url";import{defineInput as o}from"@power-plant/core";var s=o({meta:{name:`graphql-input`,description:`An input extension that reads the specification from a GraphQL schema document using loaders defined in GraphQL-Tools packages.`,readFrom:(e,t)=>`Reads the GraphQL schema from ${i(t.inputPath)?`"${t.inputPath}"`:a(t.inputPath)?`the remote source at "${t.inputPath.toString()}"`:r(t.inputPath)?`the file at "${t.inputPath.file}"`:`a specified schema source`}.`,version:`1.0`,tags:[`graphql`],links:[{href:`https://the-guild.dev/graphql/tools`,description:`GraphQL Tools`},{href:`https://github.com/ardatan/graphql-tools`,description:`GraphQL Tools - repository`},{href:`https://the-guild.dev/graphql/tools/docs/schema-loading`,description:`GraphQL Tools - Schema Loading`},{href:`https://the-guild.dev/graphql/tools/docs/documents-loading`,description:`GraphQL specification - Documents Loading`}]},input:n});export{t as createSchemaLoaders,s as default,e as toSchemaPointer};
1
+ import{input as e}from"./input.mjs";import{defineInput as t}from"@power-plant/core";var n=t({meta:{name:`graphql-input`,description:`An input extension that reads the specification from a GraphQL schema document using loaders defined in GraphQL-Tools packages.`,usage:`Reads the GraphQL schema from a file path, remote URL, or schema loader source configured via inputPath.`,version:`1.0`,tags:[`graphql`],links:[{href:`https://the-guild.dev/graphql/tools`,description:`GraphQL Tools`},{href:`https://github.com/ardatan/graphql-tools`,description:`GraphQL Tools - repository`},{href:`https://the-guild.dev/graphql/tools/docs/schema-loading`,description:`GraphQL Tools - Schema Loading`},{href:`https://the-guild.dev/graphql/tools/docs/documents-loading`,description:`GraphQL specification - Documents Loading`}]},input:e});export{n as default};
2
2
  //# sourceMappingURL=index.mjs.map
package/dist/input.cjs CHANGED
@@ -1,2 +1,2 @@
1
- Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./utilities.cjs"),t=require("./loaders.cjs");let n=require("@graphql-tools/load"),r=require("@power-plant/core/context"),i=require("@power-plant/graphql-schema/codegen");async function a(a){let{inputPath:o,...s}=a,{cwd:c}=(0,r.useContext)(),l=e.toSchemaPointer(o);try{return await(0,n.loadSchema)(l,{...i.defaultSchemaLoadOptions,cwd:c,loaders:t.createSchemaLoaders(s),...s})}catch(t){throw Error([`Failed to load GraphQL schema from ${String(l)}:`,e.formatLoadError(t),``,`Supported schema sources include:`,"- ES Modules and CommonJS exports (default or named export `schema`)",`- Introspection JSON files`,`- GraphQL endpoint URLs`,`- SDL files and glob expressions`,`- Inline SDL strings`].join(`
1
+ Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./utilities.cjs"),t=require("./loaders.cjs");let n=require("@graphql-tools/load"),r=require("@power-plant/core/context"),i=require("@power-plant/graphql-schema/codegen");async function a(a){let{inputPath:o,...s}=a,{cwd:c}=(0,r.useExecution)(),l=e.toSchemaPointer(o);try{return await(0,n.loadSchema)(l,{...i.defaultSchemaLoadOptions,cwd:c,loaders:t.createSchemaLoaders(s),...s})}catch(t){throw Error([`Failed to load GraphQL schema from ${String(l)}:`,e.formatLoadError(t),``,`Supported schema sources include:`,"- ES Modules and CommonJS exports (default or named export `schema`)",`- Introspection JSON files`,`- GraphQL endpoint URLs`,`- SDL files and glob expressions`,`- Inline SDL strings`].join(`
2
2
  `))}}exports.input=a;
package/dist/input.d.cts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { Options } from "./types.cjs";
2
- import { GraphQLSchemaDocument } from "@power-plant/graphql-schema";
2
+ import { GraphQLSchema } from "@power-plant/graphql-schema";
3
3
  //#region src/input.d.ts
4
4
  /**
5
5
  * Loads a GraphQL schema from the configured pointer using the same loaders and defaults as GraphQL Code Generator.
@@ -10,7 +10,7 @@ import { GraphQLSchemaDocument } from "@power-plant/graphql-schema";
10
10
  * @param options - The options for the input.
11
11
  * @returns A loaded {@link GraphQLSchema} instance.
12
12
  */
13
- declare function input(options: Options): Promise<GraphQLSchemaDocument>;
13
+ declare function input(options: Options): Promise<GraphQLSchema>;
14
14
  //#endregion
15
15
  export { input };
16
16
  //# sourceMappingURL=input.d.cts.map
package/dist/input.d.mts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { Options } from "./types.mjs";
2
- import { GraphQLSchemaDocument } from "@power-plant/graphql-schema";
2
+ import { GraphQLSchema } from "@power-plant/graphql-schema";
3
3
  //#region src/input.d.ts
4
4
  /**
5
5
  * Loads a GraphQL schema from the configured pointer using the same loaders and defaults as GraphQL Code Generator.
@@ -10,7 +10,7 @@ import { GraphQLSchemaDocument } from "@power-plant/graphql-schema";
10
10
  * @param options - The options for the input.
11
11
  * @returns A loaded {@link GraphQLSchema} instance.
12
12
  */
13
- declare function input(options: Options): Promise<GraphQLSchemaDocument>;
13
+ declare function input(options: Options): Promise<GraphQLSchema>;
14
14
  //#endregion
15
15
  export { input };
16
16
  //# sourceMappingURL=input.d.mts.map
package/dist/input.mjs CHANGED
@@ -1,3 +1,3 @@
1
- import{formatLoadError as e,toSchemaPointer as t}from"./utilities.mjs";import{createSchemaLoaders as n}from"./loaders.mjs";import{loadSchema as r}from"@graphql-tools/load";import{useContext as i}from"@power-plant/core/context";import{defaultSchemaLoadOptions as a}from"@power-plant/graphql-schema/codegen";async function o(o){let{inputPath:s,...c}=o,{cwd:l}=i(),u=t(s);try{return await r(u,{...a,cwd:l,loaders:n(c),...c})}catch(t){throw Error([`Failed to load GraphQL schema from ${String(u)}:`,e(t),``,`Supported schema sources include:`,"- ES Modules and CommonJS exports (default or named export `schema`)",`- Introspection JSON files`,`- GraphQL endpoint URLs`,`- SDL files and glob expressions`,`- Inline SDL strings`].join(`
1
+ import{formatLoadError as e,toSchemaPointer as t}from"./utilities.mjs";import{createSchemaLoaders as n}from"./loaders.mjs";import{loadSchema as r}from"@graphql-tools/load";import{useExecution as i}from"@power-plant/core/context";import{defaultSchemaLoadOptions as a}from"@power-plant/graphql-schema/codegen";async function o(o){let{inputPath:s,...c}=o,{cwd:l}=i(),u=t(s);try{return await r(u,{...a,cwd:l,loaders:n(c),...c})}catch(t){throw Error([`Failed to load GraphQL schema from ${String(u)}:`,e(t),``,`Supported schema sources include:`,"- ES Modules and CommonJS exports (default or named export `schema`)",`- Introspection JSON files`,`- GraphQL endpoint URLs`,`- SDL files and glob expressions`,`- Inline SDL strings`].join(`
2
2
  `))}}export{o as input};
3
3
  //# sourceMappingURL=input.mjs.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@power-plant/graphql-input",
3
- "version": "0.0.8",
3
+ "version": "0.0.12",
4
4
  "private": false,
5
5
  "description": "A Power Plant input for reading the source specification from a GraphQL schema document.",
6
6
  "keywords": [
@@ -124,29 +124,29 @@
124
124
  "typings": "dist/index.d.mts",
125
125
  "files": ["dist"],
126
126
  "dependencies": {
127
- "@graphql-tools/apollo-engine-loader": "^8.0.32",
128
- "@graphql-tools/code-file-loader": "^8.1.34",
129
- "@graphql-tools/git-loader": "^8.0.38",
130
- "@graphql-tools/github-loader": "^9.1.4",
131
- "@graphql-tools/graphql-file-loader": "^8.1.16",
132
- "@graphql-tools/json-file-loader": "^8.0.30",
133
- "@graphql-tools/load": "^8.1.13",
134
- "@graphql-tools/url-loader": "^9.1.4",
135
- "@graphql-tools/utils": "^11.2.0",
127
+ "@graphql-tools/apollo-engine-loader": "^8.0.34",
128
+ "@graphql-tools/code-file-loader": "^8.1.36",
129
+ "@graphql-tools/git-loader": "^8.0.40",
130
+ "@graphql-tools/github-loader": "^9.1.6",
131
+ "@graphql-tools/graphql-file-loader": "^8.1.18",
132
+ "@graphql-tools/json-file-loader": "^8.0.32",
133
+ "@graphql-tools/load": "^8.1.15",
134
+ "@graphql-tools/url-loader": "^9.1.6",
135
+ "@graphql-tools/utils": "^11.2.2",
136
136
  "@graphql-typed-document-node/core": "^3.2.0",
137
- "@power-plant/core": "^0.0.12",
137
+ "@power-plant/core": "^0.0.16",
138
138
  "@power-plant/graphql-schema": "^0.0.1",
139
- "@power-plant/schema": "^0.0.12",
139
+ "@power-plant/schema": "^0.0.16",
140
140
  "@stryke/resolve": "^0.0.11",
141
141
  "@stryke/type-checks": "^0.6.28",
142
142
  "@stryke/types": "^0.12.23",
143
143
  "graphql": "^17.0.2"
144
144
  },
145
145
  "devDependencies": {
146
- "@powerlines/plugin-tsdown": "^0.1.543",
146
+ "@powerlines/plugin-tsdown": "^0.1.545",
147
147
  "@types/node": "^25.9.5",
148
- "powerlines": "^0.47.142"
148
+ "powerlines": "^0.47.144"
149
149
  },
150
150
  "publishConfig": { "access": "public" },
151
- "gitHead": "27e84d9116561bc573590459566dc4443b02b9c6"
151
+ "gitHead": "8cb4ebd50961de43b9482885f5ba5779b8ded913"
152
152
  }