mirror of
https://github.com/rive-app/rive-react.git
synced 2026-03-13 08:22:30 +08:00
Bind rive to viewModel
This commit is contained in:
@@ -19,7 +19,7 @@ const DataBinding = () => {
|
||||
const viewModel = useViewModel(rive, { name: 'Rewards' });
|
||||
|
||||
// Get the default instance of the view model
|
||||
const viewModelInstance = useViewModelInstance(viewModel);
|
||||
const viewModelInstance = useViewModelInstance(viewModel, { rive });
|
||||
console.log('ViewModelInstance:', viewModelInstance);
|
||||
|
||||
const { value: priceValue, setValue: setPriceValue } =
|
||||
|
||||
Reference in New Issue
Block a user