Closed bviebahn closed 1 month ago
This is probably due to us calling .compile
on the supplied Kysely query to get the SQL and query parameters. We don't explicitly call .execute
on the Kysely query. I'm assuming the .execute
call should allow the plugins to map column data. We can investigating supporting .execute
This means I can't use https://kysely-org.github.io/kysely-apidoc/classes/CamelCasePlugin.html for now, right?
This means I can't use https://kysely-org.github.io/kysely-apidoc/classes/CamelCasePlugin.html for now, right?
Most likely. This will be fixed soon.
I love the team's speed for improvements!
Reminder: this will help with converting Temporal datetimes via a plugin. More here https://discord.com/channels/1138230179878154300/1282584951656550473/1282671991005909072
Closing this issue as plugins should be supported from @powersync/kysely-driver@0.4.0
Using Kysely plugins doesn't seem to be properly supported by the react package. I am using the
ParseJSONResultsPlugin
, and it works when I callexecute
on the query, but not when I pass the query to the useQuery hook.I guess this is a bug rather than a feature request, because:
wrapPowerSyncWithKysely
suggest kysely can be configured as usual using the second config parameter. (On another note: I think the config parameter should be changed toOmit<KyselyConfig, 'dialect'>
, sincedialect
is set bywrapPowerSyncWithKysely
and I'm not sure it ever makes sense to override it. At least it should be optional)jsonArrayFrom
andjsonObjectFrom
assume to be used withParseJSONResultsPlugin
, so the types will be wrong if the plugin doesn't work.