gatsby-source-prismic
Version:
Gatsby source plugin for building websites using Prismic as a data source
14 lines (11 loc) • 331 B
text/typescript
import * as gatsby from "gatsby";
import * as RTE from "fp-ts/ReaderTaskEither";
import { Dependencies } from "../types";
/**
* Returns all nodes using the environment's `getNodes` function.
*/
export const getAllNodes = (): RTE.ReaderTaskEither<
Dependencies,
never,
gatsby.Node[]
> => RTE.asks((deps) => deps.getNodes());