jakearchibald / idb

IndexedDB, but with promises
https://www.npmjs.com/package/idb
ISC License
6.2k stars 348 forks source link

How order for getAllFromIndex #310

Open perfect opened 2 months ago

perfect commented 2 months ago

I have an index result

 const groupsTable = db.createObjectStore("groups", {
      keyPath: "groupId",
    });
    groupsTable.createIndex("boardId", "boardId", { unique: false });
 await db.getAllFromIndex("groups", "boardId", boardId);   

but I need order result by "index" property , sort it by code or sort function ? Can I get the right order from indexed DB directly?