Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Classes

Type aliases

Type aliases

LoaderOptions

LoaderOptions<T>: { id: string; itemId?: string; loadData: () => Promise<T>; preloadedData?: T; store: ItemStore<T> }

Type parameters

  • T

Type declaration

  • id: string

    ID for debugging

  • Optional itemId?: string

    The ID of the item we're going to load, if available. Not needed if preloadedData is given (it'll just get the ID from that)

  • loadData: () => Promise<T>

    The function which loads the data

      • (): Promise<T>
      • Returns Promise<T>

  • Optional preloadedData?: T

    Any preloaded data associated with this loader. e.g. For a user loader, this would be the user object, if available

  • store: ItemStore<T>

    The ItemStore in which the data will be saved for usage later

Generated using TypeDoc