- New Runtime (Recommended)
- Legacy Runtime
The following are props you can set on the
RiveView component:The riv file to display, loaded via
useRiveFile or RiveFileFactory.The view reference setter, obtained from
useRive.Automatically start playing the state machine.
How the Rive graphic should fit within its container.
How the Rive graphic should be aligned within its container.
Ignored when using
Fit.Layout.The scale factor to apply to the Rive graphic when using
Fit.Layout. The default value of -1 uses the device’s DPI.
This property has no effect for any other
Fit type.The name of the artboard to display.If not set, the default artboard will be used, as configured in the Editor.
The name of the state machine to play.If not set, the default state machine will be used, as configured in the Editor.
The view model instance to bind to the state machine. Can be:
- A
ViewModelInstanceobject (fromuseViewModelInstance) DataBindMode.Auto(default) - automatically binds the default view model instanceDataBindMode.None- no data binding{ byName: string }- bind by instance name
Custom error handling callback.