#Fetcher not running on changing option in a custom component

1 messages · Page 1 of 1 (latest)

spice sapphire
#

Current action code:

export const invoke = createAction({
  name: 'Invoke',
  baseOptions,
  options: option.object({
    chain: option.string.layout({
      placeholder: 'Select a chain',
      label: 'Chain',
      isRequired: true,
      fetcher: 'fetchChains',
    }),
  })
  ,
  fetchers: [
    {
      "id": "fetchChains",
      dependencies: ["baseUrl"],
      fetch: async ({ credentials, options }) => {
        return ["1", "2", "3", "4"]
      }
    }
  ],
})

the return of the fetcher is static for now only for me to test, I change the baseURL and see the chain component blinking but no data is added to the dropdown, am I missing something?

bleak oasis
#

Mmmh

#

Can you provide a git branch that I can pull to try it out?

spice sapphire
bleak oasis
#

Ok I managed to reproduce

#

I will push a fix now onto main