Closed geohuz closed 4 years ago
It seems like it's not possible with useLocalStore
. You can also use useState
to create a local store:
class GroupStore {
@observable.shallow rows = [];
addRow(payload) {
let newRow = new groupRow()
newRow.setRowStore(payload)
groupStore.rows.push(newRow)
}
}
...
const [groupStore] = useState(() => new GroupStore());
If you have further questions, please open a new issue.
Is it possible to use observable.deep/shallow in mobx-react-lite? I tried the following code but get errors: