expo-sqlite
Version:
Provides access to a database using SQLite (https://www.sqlite.org/). The database is persisted across restarts of your app.
15 lines (11 loc) • 378 B
text/typescript
import { requireNativeModule } from 'expo';
let ExpoSQLite;
if (typeof window === 'undefined') {
// expo-sqlite is not supported on server runtime.
ExpoSQLite = {};
} else if (typeof globalThis.ExpoDomWebView !== 'undefined') {
ExpoSQLite = requireNativeModule('ExpoSQLite');
} else {
ExpoSQLite = require('../web/SQLiteModule').default;
}
export default ExpoSQLite;