In this video, get a code walk-through of creating a new data store using localForage, including how to create multiple stores.
- [Instructor] I'm going to be using localForage … for this tutorial. … Depending on your project, … text address or another library may be best suited. … If this is your first time … working with the Client-Side Database, … I strongly recommend starting with localForage. … The localForage API is designed … to be as similar to the localStorage API as possible. … So you don't have to manually create a new database. … You can just start storing data using set item. … This will create a default database … and object store for you. … However, you may want more control than this, … with multiple databases or multiple object stores. … For these, localForage gives us "create instance". … Here, you can pose the name of … the database you want to create. … You'll create a database and return an open connection. … To create multiple object stores inside the same database, … we co-create "instance" twice, … giving the same database name with a different store name. … LocalForage will create two object stores …
Skill Level Advanced
Web Programming Foundationswith Morten Rand-Hendriksen58m 44s Beginner
1. Front-End Performance Tools
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.