I have this error : undefined is not an object (evalueting 'NativeModules["SQLite"][method]')
getAllTests () {
let DB = null;
const getDB = SQLite.openDatabase({name: 'database.db', createFromLocation: 1});
const query = 'select * from tests;';
return DB.executeSql(query).then(([results]) => {
return JSON.parse(results.rows.item(0).data || '{}');
});
}
Comments
Post a Comment