Questions tagged [dexie]
Dexie.js is a minimalistic wrapper for IndexedDB
316
questions
1
vote
1
answer
7
views
Dexie Live Query and Service Worker
I want to use Dexie within the service worker to sync my data.
I also want to use useLiveQuery hook in the React frontend.
Would Dexie automatically update the query if new data gets written in the ...
0
votes
0
answers
16
views
Memory problem when running foreach with dexie
I have blobs inside my indexeddb around 10mb per row. So when im trying to do a query like this, Dexie loads all my rows in memory then looping it. So the memory consuming is huge. How can iterate my ...
0
votes
0
answers
18
views
Error when getting data using indexeddb with Dexie
I use Dexie to store data on the brozwser using HTML and javascript,
I have no problem when I store data but I have an issue when I get data to IndexedDb
this my code to get data
var db = new Dexie('...
0
votes
1
answer
11
views
Dexie eachUniqueKey and Where Clause
I'm developing an application in Quasar/Electron and using Dexie/IndexedDB for my database. I want to find all distinct records in the database that contain both my Event ID and a Dog ID (both key ...
0
votes
1
answer
40
views
does the IndexedDB Wrapper Dexie.js support all kinds of Web browser?
I'm planning to use IndexedDB Wrapper Dexie.js for my react.js application.
Does Dexie.js support all kinds of web browsers?
If there is any limitation, kindly let me know
Thanks in advance.
0
votes
0
answers
20
views
Dexie pass auth token with request
My app lets guests (not logged in) save their data in the indexeddb. When logged in this data should be synced with a backend.
I implemented dexie for the handling of the indexeddb and dexie syncable ...
3
votes
1
answer
44
views
Dexie.js delete one item with id not working
Hi this my simple project js code example
const deleteOneNote = (id) => {
const db = openNoteDb();
db.notes.where('id').equals(id).delete();
}
$(document).on("click", "....
1
vote
0
answers
63
views
using pinia states and dexie in the same time?
For my app I'm using Vue3, pinia for state management, and dexie as indexedDB wrapper.
my app work this way:
on Mount :
data is fetched from dexie and saved in a pinia state.
then in my component , ...
2
votes
1
answer
78
views
How to sync database with remote database with Dexie
I making Notes PWA App that work offline and online.
I am saving notes records on IndexedDB with Dexie.js. I am using Quasar as frontend and backend as Laravel 8.
I want to sync IndexedDB Database ...
0
votes
0
answers
17
views
How do I use a named export from an external script in Angular?
https://stackblitz.com/edit/angular-ivy-4666q1?file=src%2Fdb%2Fdb.ts is a great demo of using Dexie in Angular, but instead of npm installing and importing, I would like to dynamically load Dexie AND ...
2
votes
1
answer
133
views
Retrieve value from IndexedDB using Dexie and Svelte
I don't understand how I can get a value from IndexedDB using Dexie. Database is all good in 'application' tab in inspect tool. Total newbie, so please be understanding.
My db.js
import Dexie from &...
1
vote
0
answers
29
views
How to change the secretKey in Dexie-Encrypted?
I've been looking for an example about how to modify the secretKey of a IndexedDB that is protected by Dexie-Encrypted.
So far I've read that if I wanna change the key, the version of the DB should be ...
0
votes
0
answers
52
views
Is there a way to import JSON file into dexie js?
I am using dexie js which has a import db method for importing large json files. The problem is it is only for dexis db files. I need to be able to basically do bulk add but with this json file as it ...
1
vote
0
answers
14
views
Accessing Dexie(Indexed db) inside FCM onBackgroundMessageHandler
I am using FCM for push notifications in my web app and everything is working fine foreground and background except the fact that when my browser is closed, I am receiving FCM notifications but unable ...
0
votes
0
answers
41
views
Pass some query params with Vue
we are trying to use Dexie with Vue. We are loading some table data into the Vue component and we would like to sort it by clicking on the column. We are having problems with changing sort order in ...
0
votes
0
answers
145
views
"class constructors must be invoked with 'new'" when using Dexie in React
I am using Dexie with Gatsby, I try to create database in db.ts with the code below, but there is error class constructors must be invoked with 'new' pointing to the line super('newDB'). Any help for ...
0
votes
1
answer
22
views
DexieJS await count() not working in interation
I had been studying and searching without any luck on my following issues:-
let groups = [ 1, 2, 3, 4, 5 ];
await groups.map( async (value) => {
let total = 0;
if (value > 3) {
total = ...
0
votes
0
answers
17
views
dynamicly generating tables in Dexie IndexedDB
I am working on a tiny messenger and want to generate dexie tables dynamically based on id of rooms,
I have no idea about creating dynamic tables in dexie,
I'll be glad hearing you.
0
votes
1
answer
176
views
Next.js / Dexie: Failed to execute 'add' on 'IDBObjectStore': Evalu…he object store's key path did not yield a value
When attempting to save using Dexie i encounter the error below, this error strictly occurs in production with no errors occurring when i attempt to save data. Any help much appreciated!
the error:
&...
0
votes
1
answer
26
views
Dexie.js: What is the dist/modern directory
Just downloaded Dexie.js-3.2.1.zip. Unlike a previous version I was using, this contains a dist/modern directory. How do files in this directory differ from those in the dist directory?
0
votes
0
answers
52
views
Using Dexie.js from content script of a WebExtension
I'm trying to use Dexie.js from a content script inside my Firefox extension but it throws an error when I try to open the database.
Dexie.js works great from a background script but I'm trying to ...
0
votes
1
answer
64
views
Pass a paramter to dexie livequery in vue3
Background
I have some data in indexdb and I'm using dexie.js to access it. I'm using livequery to connect the data to the views in Vue3 and its working fine so far.
Now I want to pass a parameter to ...
0
votes
0
answers
54
views
indexedDB wrapper Dexie
This is my angular code to insert into the BD. The problem is sometimes, it fails to add the value.
addNewImage(imgName:string, imgDataVal:any) {
db.imageList.put({
imgName: imgName,
...
0
votes
0
answers
49
views
How can I index and query array with object in Dexie.js?
I would like ask if how can i search the supplier inside the array of objects ?
like this one, i want to search of suppliers inside the items
items: Array(4) 0: {
product_id: 487, product_name: "...
0
votes
0
answers
35
views
How to insert an entry to the store Dexie
I keep getting this when trying to insert an entry to the store.
The schema was extended without specifying the version.
schemaError: KeyPath imgName on object store imageList is not indexed
0
votes
1
answer
171
views
Indexed database using Dexie not created
I have a angular app where I am trying to insert into an indexed Database.
The problem is that the database is not getting created.
Below is a section of the code where I insert an entry into the ...
0
votes
0
answers
40
views
IndexedDB setup for in browser random access on 10 GB file?
We want to repeatedly and continuously query a downloaded 10 GB file in browser. It's hard because just downloading that much data will fill memory and crash chrome, so we have to use a memory space ...
0
votes
1
answer
120
views
IndexedDB: SchemaError when trying to access nested object inside a table
I have an IndexedDB named pos and inside that table named pos_customers. The structure looks like https://imgur.com/e9ZrxVm
Now my goal is to access phone which is inside billing object. If you look ...
0
votes
0
answers
37
views
Dexie js Changable tables
I am using Dexie.js as a wrapper for my IndexedDB local database.
I have a list of tables that i am getting from my server, each table is also contains its own schema and then i am creating the ...
0
votes
0
answers
17
views
Is there an REST-API-Adaptor for Wordpress and Dexie.js to sync posts?
I want to prepare an (optimized) offline database for Wordpress-posts (via REST-API replies) and was wondering, if there's an existing adaptor for that? (Ideally bi-directional)
I am mostly interested ...
0
votes
1
answer
55
views
Angular, Dexie, invalid date
I have a Angular V13.0.2 app that I am expanding. I just recently added Dexie (indexedDB). Now when I try to add a date to my database I only get a "Invalid Date" statement out of it.
// ...
0
votes
0
answers
89
views
iOS resizing image with canvas results in black image
I am trying to resize multiple images in the browser (same results in Chrome and Safari) by using canvas, to then save them to IndexedDB via Dexie.js. It all works fine in Android, but on iOS (tested ...
0
votes
1
answer
98
views
Adding Dexie.js queries in JavaScript file gives hint of missing type
If I add a Dexie.js query in a JavaScript file such as:
let friends = liveQuery(async () => {
return await db.friends
.where("age")
.between(18, 65)
.toArray();
});
I get a ...
0
votes
1
answer
14
views
Returned value from dexie qualifies as object, but then it isn't
I create an object store with dexie.js and populate it with an empty object like this:
db.version(1).stores({
status: 'id, settings' // only one entry, no need to auto-increment
})
// Add initial ...
0
votes
0
answers
66
views
Openlayers Layers are populated but Features don't show
The application is svelte, but I don't think svelte is the cause of this problem.
What the application is doing:
Check local dexie.js cache for graph data
Check with server if graph is correct and ...
0
votes
1
answer
80
views
How to create a method that returns Observable that emits result of 2 Promises that need to be executed one after another?
I asked a question
Is Observable from chained promises equivalent of observables created with from and chained with concatMap?
on totally false premises. It seems that neither of my solutions had ...
0
votes
0
answers
27
views
VueJS failing to compile DexieJS Database Class in Typescript because of ESLint
VueJS failing to compile DexieJS Database Class in Typescript. The errors points at failing to handle Dexie.Table type but DexieJS comes with types included in its plugin. It says "You may need ...
0
votes
1
answer
116
views
Is Observable from chained promises equivalent of observables created with from and chained with concatMap?
I have an Angular app that have DexieDb / IndexedDb storage for objects selected from map. I always clear the db before adding new items. If the new items are same sometimes there can be constraint ...
0
votes
1
answer
129
views
Problems understanding Dexie Encrypted
Could somebody help me with dexie-encrypted found here . The documentation provided was pretty short and was missing real-life examples of how to actually encrypt and decrypt the data from indexDb.
0
votes
1
answer
141
views
Dexie.js: Update nested object via dynamic id
My Dexie Database db.playground (with the id audioFiles) holds infos about audio files. Those audio files have to be analysed by a user, who adds markers (so it is an analog process, not a ...
0
votes
1
answer
130
views
I want to change my dexie values which are null to empty strings
I want to change my data-tables values which are null to empty strings.
Sometimes the department value will be empty, in which case it will put null in my data tables.
db = db_open();
db.fuel.toArray(...
0
votes
1
answer
62
views
can you change the local dexie DB values of null to just a string with no value
so i update my dexie db with my sql db, but the problem is that some of the values are empty
THE PROBLEM IS THAT WHEN I WANT TO PRINT THE VALUE IN PHP IT PRINTS ALL THE VALUES AND THE
ONES WHICH ARE &...
1
vote
1
answer
291
views
Dexie useLiveQuery hook causes the error "TypeError: dexie.liveQuery is not a function"
Did an npm install of dexie and dexie-react-hooks yesterday. package-lock.json shows dexie 3.0.3 and dexie-react-hooks 1.0.7
Created a react app using the template "cra-template-pwa"
Used ...
0
votes
1
answer
192
views
Is there a better way to write this code in svelte using dexie?
Trying to learn svelte and using dexie. Is there a better way to get data to the array from indexedDB?
My functions.js file
export const db = new Dexie("todos");
db.version(1).stores({
...
0
votes
1
answer
354
views
Reactive Dexie-Query in Vue
I am using Dexie and would like to implement this in my Vue 3 frontend.
In the mount() method, I query the database using the following example and assign this to a local variable in the Vue template ...
0
votes
0
answers
80
views
Get data function in Dexie is returning undefined
My function is simple. Create table, bulk put data and retriew object based on index.
const db = new Dexie('data');
const dataToInsert = [{id: "aaaa", name: "bbb"}]
function data()...
0
votes
0
answers
41
views
How do I get a value from a Dexie get?
New to both Dexie and Svelte. Trying to use both. Can add/put into indexedDB but I have problem with get.
let person = db.persons.get("Peter")
console.log(person.mobile);
Returns undefined.
...
1
vote
1
answer
155
views
Dexie -> column names as variables
We are updating/inserting on multiple tables that each has the same basic fields with a prefix.
We want to use variables to change the column names.
e.g. db.friends.update(2, {name: "Number 2&...
0
votes
0
answers
62
views
How to name dexie db from localstorage item?
I'm using Dexie for my vue project and I'm trying to give Dexie DB a name depending on the user name logged in;
I'm following this logic:
Login component gets uid and save in local storage
in db.js ...
2
votes
0
answers
88
views
Angular 11: Dexie Dynamically created stores, Getting InvalidTableError while performing search on table
I have create stores dynamically in the database.
try {
if (!(await existingCollection).includes(tableName)) {
const dbVersion = this.collectionsDb.verno + 1;
await ...