Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
utils,
{
typeName = "PostGraphile",
fieldName = "postgres",
refetchInterval,
...options
}
) => {
const { connectionString, schema: postgresSchema, ...rest } = options;
const pool = new Pool({
connectionString,
});
const graphqlSchema = await createSchema(pool, postgresSchema, rest);
await gatsbySourceGraphQLNode.sourceNodes(utils, {
typeName,
fieldName,
refetchInterval,
createLink: () => new PostGraphileLink({ pool, schema: graphqlSchema }),
createSchema: () => graphqlSchema,
});
};