@graphql-codegen/cli 3.3.0-alpha-20230327211145-bd2d527a5 → 3.3.0-alpha-20230328125526-ff9d4c01a
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/cjs/codegen.js +2 -3
- package/cjs/config.js +2 -2
- package/package.json +2 -2
package/cjs/codegen.js
CHANGED
|
@@ -28,15 +28,14 @@ const makeDefaultLoader = (from) => {
|
|
|
28
28
|
}
|
|
29
29
|
const relativeRequire = (0, module_1.createRequire)(from);
|
|
30
30
|
return async (mod) => {
|
|
31
|
-
|
|
32
|
-
return _a = isESMModule
|
|
31
|
+
return Promise.resolve(`${isESMModule
|
|
33
32
|
? /**
|
|
34
33
|
* For ESM we currently have no "resolve path" solution
|
|
35
34
|
* as import.meta is unavailable in a CommonJS context
|
|
36
35
|
* and furthermore unavailable in stable Node.js.
|
|
37
36
|
**/
|
|
38
37
|
mod
|
|
39
|
-
: relativeRequire.resolve(mod)
|
|
38
|
+
: relativeRequire.resolve(mod)}`).then(s => tslib_1.__importStar(require(s)));
|
|
40
39
|
};
|
|
41
40
|
};
|
|
42
41
|
function createCache() {
|
package/cjs/config.js
CHANGED
|
@@ -182,9 +182,9 @@ exports.parseArgv = parseArgv;
|
|
|
182
182
|
async function createContext(cliFlags = parseArgv(process.argv)) {
|
|
183
183
|
if (cliFlags.require && cliFlags.require.length > 0) {
|
|
184
184
|
const relativeRequire = (0, module_1.createRequire)(process.cwd());
|
|
185
|
-
await Promise.all(cliFlags.require.map(mod => {
|
|
185
|
+
await Promise.all(cliFlags.require.map(mod => Promise.resolve(`${relativeRequire.resolve(mod, {
|
|
186
186
|
paths: [process.cwd()],
|
|
187
|
-
})
|
|
187
|
+
})}`).then(s => tslib_1.__importStar(require(s)))));
|
|
188
188
|
}
|
|
189
189
|
const customConfigPath = getCustomConfigPath(cliFlags);
|
|
190
190
|
const context = await loadContext(customConfigPath);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@graphql-codegen/cli",
|
|
3
|
-
"version": "3.3.0-alpha-
|
|
3
|
+
"version": "3.3.0-alpha-20230328125526-ff9d4c01a",
|
|
4
4
|
"peerDependencies": {
|
|
5
5
|
"graphql": "^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0"
|
|
6
6
|
},
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"@babel/template": "^7.18.10",
|
|
10
10
|
"@babel/types": "^7.18.13",
|
|
11
11
|
"@graphql-codegen/core": "^3.1.0",
|
|
12
|
-
"@graphql-codegen/plugin-helpers": "4.2.0-alpha-
|
|
12
|
+
"@graphql-codegen/plugin-helpers": "4.2.0-alpha-20230328125526-ff9d4c01a",
|
|
13
13
|
"@graphql-tools/apollo-engine-loader": "^7.3.6",
|
|
14
14
|
"@graphql-tools/code-file-loader": "^7.3.17",
|
|
15
15
|
"@graphql-tools/git-loader": "^7.2.13",
|