Better HN
topnewbestaskshowjobs
Log inSign up

postcoroner

9 karma · joined Oct 20, 2022 (4y ago) · 7 submissions

Submissions

comment 4y ago · link · parent

You could use the dexie.js based storage [1] as a start. It is fast enough for most use cases and comes for free.

[1] https://rxdb.info/rx-storage-dexie.html

comment 4y ago · link · parent

Cool, but we are talking about a PM tool here, so what really matters is people having no/slow internet for a short period of time.

comment 4y ago · link · parent

> 2GB of persistent storage

2 GB is a lot when you store plain json document data.

> IndexedDb is the only option, it's slow on writes

Only when you need a new transaction per write. Writing many documents in a single tx is not slow [1]

> Safari are known to delete IndexedDB after 1 week

This is not really a problem because if you have not used the app for one week, you can just replicate the data from the server again.

> WebAssembly based sqlite is coming along nicely too

WebAssembly cannot access the IndexedDB API. In my tests, all the wrappers that use webassembly are slower on writes the just using IndexedDB via javascript.

The fastest you can go is by using a Memory-Synced wrapper around IndexedDB, like LokiJS does it or the RxDB memory plugin. [2]

[1] https://rxdb.info/slow-indexeddb.html

[2] https://rxdb.info/rx-storage-memory-synced.html

4.

GitHub Release Radar – September 2022(github.blog ↗)

1 points · by postcoroner · 4y ago · discuss

comment 4y ago · link · parent

I am using sharp to transform jpeg to avif images. The conversion also takes very long, for my images about 45s each.

6.

Conflict free replication with CRDTs and RxDB(rxdb.info ↗)

12 points · by postcoroner · 4y ago · discuss

7.

Storing CRDTs in RxDB(rxdb.info ↗)

1 points · by postcoroner · 4y ago · discuss