You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 24, 2026. It is now read-only.
Repository navigation
This repository was archived by the owner on Apr 24, 2026. It is now read-only.
Cannot read property 'openDatabase' of undefined Test in device #32
ERROR Error: Uncaught (in promise): TypeError: Cannot read property 'openDatabase' of undefined
TypeError: Cannot read property 'openDatabase' of undefined
at vendor.js:168847
at new t (polyfills.js:3)
at CordovaDriver.createDatabaseConnection (vendor.js:168842)
at CordovaDriver.<anonymous> (vendor.js:35867)
at step (vendor.js:228)
at Object.next (vendor.js:209)
at vendor.js:202
at new t (polyfills.js:3)
at __awaiter (vendor.js:198)
at CordovaDriver.AbstractSqliteDriver.connect (vendor.js:35861)
at c (polyfills.js:3)
at polyfills.js:3
at polyfills.js:3
at t.invoke (polyfills.js:3)
at Object.onInvoke (vendor.js:4446)
at t.invoke (polyfills.js:3)
at r.run (polyfills.js:3)
at polyfills.js:3
at t.invokeTask (polyfills.js:3)
at Object.onInvokeTask (vendor.js:4437)
Add "typeRoots": ["node_modules/@types"] to your tsconfig.json under compilerOptions
Open tsconfig.app.json file and in compilerOptions --> types add "node" to the array
if you get runtime error global is undefined in my case in buffer module;
edit file /node_modules/buffer/index.js and add at the top window.global = window;
Activity
willyguevara commentedon Nov 17, 2020
Same problem with me.
ionic info:
willyguevara commentedon Nov 26, 2020
i solve my issues with the following steps using ionic 5
"typeRoots": ["node_modules/@types"]to yourtsconfig.jsonundercompilerOptionstsconfig.app.jsonfile and incompilerOptions --> typesadd"node"to the arrayif you get runtime error
global is undefinedin my case inbuffermodule;edit file
/node_modules/buffer/index.jsand add at the topwindow.global = window;