lowdb icon indicating copy to clipboard operation
lowdb copied to clipboard

fix: make LocalStorage adapter available in the browser

Open Arondight opened this issue 3 years ago • 2 comments
trafficstars

Arondight avatar Apr 12 '22 02:04 Arondight

https://github.com/typicode/lowdb/pull/528 cause this issue, it breaks Browser example.

Arondight avatar Apr 12 '22 02:04 Arondight

@typicode hi can you review this pull?

Arondight avatar May 03 '22 11:05 Arondight

Hey,

Sorry for the late reply.

As part of v4/v5 update, I went ahead and simply removed global. I tested it and it works in Vite and CodeSandbox (with .js). Also TypeScript doesn't seem to complain when lib has DOM in tsconfig.json.

Is there still a failing use case that I may be missing? Or v5 fixes your initial issue?

typicode avatar Oct 22 '22 02:10 typicode

New version looks good but import path of adapters breaks old code

Arondight avatar Oct 23 '22 16:10 Arondight