js-cookie
localForage
Our great sponsors
js-cookie | localForage | |
---|---|---|
21 | 27 | |
21,564 | 24,213 | |
0.4% | 0.8% | |
7.7 | 0.0 | |
9 days ago | 3 months ago | |
JavaScript | JavaScript | |
MIT License | Apache License 2.0 |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
js-cookie
-
Coding Authentication? Stop now and let Choreo manage it.
Once the user is logged in, you may need to access information like the user's name, email, etc. Choreo sends this information encoded in a cookie (named userinfo) upon successful login. We can extract the information using a cookie parsing library. For this example, we will be using js-cookie library.
-
Rust For JavaScript Developers Ltd. Received a Cease and Desist From Oracle Due to JavaScript Trademark
Interesting thread. If oracle were to send a cease and desist to everyone that uses "javascript" I would have received one years ago: https://github.com/js-cookie/js-cookie
-
Saving users’ preferences in SvelteKit
So something like this... (I’ll be using this package to simplify the code)
-
I'm giving out microgrants to open source projects for the third year in a row! Brag about your projects here so I can see them, big or small!
I created js-cookie with Klaus as we're planning to do something similar, but by leveraging crypto gains and leaving the money in a wallet to hopefully accrue some value over time and maximize the impact in other Open Source projects in the future.
-
Storing Login Information With Cookies (JavaScript)
There is an npm package we can use called js-cookie(or, alternatively, you can use a script tag to import it from jsDelivr CDN. Use this link for more info on how to install it.)
-
Which library to use to store tokens in cookies?
We use vuex-persisted state for session storage. We use https://github.com/js-cookie/js-cookie to set the auth cookie and then we have a getter in our store that checks the cookie token for validity for isLoggedIn
localForage
-
How to get core.async to play well with IndexedDB
Not really an answer but have you looked into https://github.com/localForage/localForage
-
Better Ways To Handle Data Storage on The Web Client
LocalForage: this is a wrapper around IndexedDB, WebSQL, LocalStorage, and SessionStorage with a way to define more interfaces (called drivers) *for additional storage solutions. It does a great job handling all your serialization needs, it is **asynchronous **and handles a large set of data types. Its **API resembles Web Storage API* and it is ridiculously simple to learn.
-
SvelteKit: Use local database in the browser
Depending on what kind of storage requirements you have, LocalForage might be a good fit. It provides a unified API to access WebSQL, indexedDB or localStorage.
-
Experienced JavaScript Developer Meme
Have a look at local forage. It is an almost drop in replacement for local storage, but with doing what you want and using the much nicer indexeddb when available.
This is why we have localForage.
- Where should I store images ?
-
Recommended storage for pinia
I have been using localforage (https://github.com/localForage/localForage) in non vue applications and haven't looked back since. All the features of indexeddb with the same interface as localstorage.
-
IndexedDB. Storing data in browsers
localForage: A Polyfill providing a simple name-value syntax for client-side data storage, which uses IndexedDB in the background, but falls back to WebSQL and then localStorage in browsers that don't support IndexedDB.
-
Is it possible to bundle a SQlite database file into a ReactJS web application using webpack?
Or even a wrapper like this https://github.com/localForage/localForage which falls back to local storage if indexeddb or Web SQL are not available
-
How do you persist Pinia state across reloads
LocalForage is a good wrapper for it that had worked well for me in Vue 3. https://github.com/localForage/localForage
What are some alternatives?
Dexie.js - A Minimalistic Wrapper for IndexedDB
store.js - Cross-browser storage for all use cases, used across the web.
PouchDB - :koala: - PouchDB is a pocket-sized database.
svelte-persisted-store - A Svelte store that persists to localStorage
Cookies - JavaScript Client-Side Cookie Manipulation Library
LokiJS - javascript embeddable / in-memory database
vue-cookies - A simple Vue.js plugin for handling browser cookies
jquery-cookie
WatermelonDB - 🍉 Reactive & asynchronous database for powerful React and React Native apps ⚡️
cookies.js - 🍫 Tastier cookies, local, session, and db storage in a tiny package. Includes subscribe() events for changes.
cross-storage - Cross domain local storage, with permissions
sql.js - A javascript library to run SQLite on the web.