christopherafbjur / sanity-plugin-icon-picker

MIT License
30 stars 27 forks source link

Add compatibility with `@sanity-typed` #62

Open saiichihashimoto opened 11 months ago

saiichihashimoto commented 11 months ago

Watch How to Type Your Sanity Document and Client

@sanity-typed enables typed output from sanity's groq clients!

When using untyped plugins (like this one), it'll provide an unknown for the plugin's values, which isn't ideal. Luckily if you use the typed definePlugin and castFromTyped methods, you can enable typed values and continue to support your default users!

Here is the guide on the changes in this PR.