bigbinary/babel-preset-neeto

zustand-pick transformer does not support default value assignment

Closed this issue · 4 comments

Below syntax with default value assignment, doesn't seem to be allowed by zustand-pick tranformer currently:

const {
    solution = {},
    packages = null,
  } = useConfigStore.pick();

cc: @Amaljith-K

@ajmaln _a I forgot whether renaming of variables would work:

const { id: userId } = useUserStore.pick();

If it doesn't work either, please add support for it too.

const { id: userId } = useUserStore.pick();

@Amaljith-K This case works just fine.

ajmaln commented

@Calvinwilson99 _a

ajmaln commented

Fixed in #22