marcuswestin / store.js

Cross-browser storage for all use cases, used across the web.
MIT License
14.01k stars 1.33k forks source link

What about building each default storage to dist ? #273

Open cyrilchapon opened 6 years ago

cyrilchapon commented 6 years ago

I personally love this library, but I don't need the "fallback" stuff.

I do appreciate the effort on "uniformizing" stores APIs, but i'm struggling with that basic use-case :

I need to include the same piece of code, on all three of an ES6 monolithic app, a React app, and a wordpress site. That piece of code use (and needs to use) only SessionStorage (I don't want full browser support, and I don't want any fallback logic. I want it to work on SessionStorage and only on SessionStorage).

Importing it into my wordpress is currently impossible, appart making a small npm module witch basically produces a custom build... This seems to go against "UMD" logic with <script> requirable stuff, isn't it ?

Wouldn't it be worth, making each store(storage) individually available on dist ?