Replies: 2 comments
-
I looked at the code for creating a collection of files. And three ideas arose:
@Diizzayy What do you think about this? |
Beta Was this translation helpful? Give feedback.
0 replies
-
For my case, it is enough to patch the generateGqlTypes method by replacing // node_modules/nuxt-graphql-client/dist/module.mjs
for await (const path of documentPaths) {
const files = (await resolveFiles(path, [gqlMatch, "!**/schemas"], { followSymbolicLinks: false })).filter(allowDocument);
documents.push(...files);
} on for await (const path of documentPaths) {
const files = (await resolveFiles(path, [gqlMatch, "!**/schemas"], { followSymbolicLinks: false })).filter(allowDocument);
files.forEach(file => {
const fileNameWithoutExtension = file.split('/').pop().split('.')[0];
if (!documents.some(uniqueFile => uniqueFile.split('/').pop().split('.')[0] === fileNameWithoutExtension)) {
documents.push(file);
}
});
} cc @Diizzayy |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
The "./layer/query/ship.gql" file is present in the Layer and in the project I want override ship.gql . How do this?
Example: https://stackblitz.com/edit/nuxt-starter-kr8arq?file=nuxt.config.ts
Expected result:
If a file with the same name as layer is present in the project, then it must have priority, and it must be used.
Actual result:
I see error in console - "Error: Not all operations have an unique name: ships".
Beta Was this translation helpful? Give feedback.
All reactions