2022-03-31 12:59:31 +00:00
|
|
|
const { loadEnvConfig } = require("@next/env");
|
|
|
|
loadEnvConfig(process.cwd());
|
|
|
|
|
|
|
|
module.exports = {
|
|
|
|
overwrite: true,
|
|
|
|
schema: {
|
|
|
|
[process.env.URL_GRAPHQL]: {
|
|
|
|
headers: { Authorization: `Bearer ${process.env.ACCESS_TOKEN}` },
|
|
|
|
},
|
|
|
|
},
|
2022-03-31 13:01:44 +00:00
|
|
|
documents: [
|
2022-08-27 15:03:05 +00:00
|
|
|
"src/graphql/operations/**/*.graphql",
|
2022-03-31 13:01:44 +00:00
|
|
|
"src/graphql/fragments/*.graphql",
|
|
|
|
],
|
2022-03-31 12:59:31 +00:00
|
|
|
generates: {
|
|
|
|
"src/graphql/generated.ts": {
|
|
|
|
plugins: [
|
|
|
|
"typescript",
|
|
|
|
"typescript-operations",
|
|
|
|
"typescript-graphql-request",
|
|
|
|
],
|
|
|
|
},
|
|
|
|
},
|
|
|
|
};
|