Open Realm-JS Defined in Another .JS File
问题 I am trying to use realm-js in react-native so what I did is created a class of realm-js in my action folder as in LoginActions.js , which will write the data after user logs in. My Question is How do I open the same schema into another .js file? Realm-js Defined in LoginActions.js: class Login { get token() { return this.token; } } Login.schema = { name: 'Login', primaryKey: 'id', properties: { id: 'int', token: 'string', } }; Then I Open the Realm to Write and Update in this Schema with