Allow runtime plugins to extend scene meta fields #927
Labels
a-core
Relates to the core package
b-enhancement
New feature or request
c-accepted
The issue is ready to be worked on
Description
Runtime plugins should be able to configure project and scene meta fields in a similar manner to custom exporters. This would enable editor plugins to easily add new gizmos as well as allowing for state-persisting hooks similar to the existing
waitUntil
anduseDuration
functions.Proposed solution
The API should extend
makePlugin
(andmakeEditorPlugin
) with functions for configuring both project level and scene level meta fields, similar to how custom exporters provide meta fields throughmeta()
.Considered alternatives
Currently, the best way for plugins to implement stateful interaction between the editor and animation (like
useDuration
) is to use the vite websocket to send messages between the editor and server, and then fetch that data in the scene whenever it is recalculated.The text was updated successfully, but these errors were encountered: