realm-js
realm-js copied to clipboard
How to create a clone of realm object in Realm JS
Is it possible to copy a RealmObject and assign a different primary key to it and store this Object to Realm DB.
It looks this can be achieved in Realm Java as realm.copyToRealmOrUpdate(objCopy).
Any advise on similar behaviour in Realm JS?
any update on this...???
As a work-around you can use let jsObject = JSON.parse(JSON.stringify(realmObject))