From c9a24f98f986fbf645b802bc70526c36f9f49ba9 Mon Sep 17 00:00:00 2001 From: Vladimir Razuvaev Date: Tue, 16 Jun 2020 20:04:29 +0700 Subject: [PATCH] fix(gatsby-source-filesystem): Update typings for createRemoteFileNode (#24750) --- packages/gatsby-source-filesystem/index.d.ts | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/packages/gatsby-source-filesystem/index.d.ts b/packages/gatsby-source-filesystem/index.d.ts index aec7ef5cd843a..d7c02db11d0f2 100644 --- a/packages/gatsby-source-filesystem/index.d.ts +++ b/packages/gatsby-source-filesystem/index.d.ts @@ -1,4 +1,4 @@ -import { Node, Store, Cache } from "gatsby" +import { Node, Store, NodePluginArgs } from "gatsby" /** * @see https://www.gatsbyjs.org/packages/gatsby-source-filesystem/?=files#createfilepath @@ -29,7 +29,8 @@ export interface CreateFilePathArgs { export interface CreateRemoteFileNodeArgs { url: string store: Store - cache: Cache["cache"] + // TODO: use GatsbyCache type (requires gatsby@2.22.13) + cache: NodePluginArgs["cache"] createNode: Function createNodeId: Function parentNodeId?: string @@ -46,7 +47,8 @@ export interface CreateRemoteFileNodeArgs { export interface CreateFileNodeFromBufferArgs { buffer: Buffer store: Store - cache: Cache["cache"] + // TODO: use GatsbyCache type (requires gatsby@2.22.13) + cache: NodePluginArgs["cache"] createNode: Function createNodeId: Function parentNodeId?: string