localStorage、sessionStorage、cookie储存

storage

cookie

It is used in the browser and server
cookie is borrowed. It was not available before. Both methods use localStorage and sessionStorage
. When the maximum storage is 4kb,
http requests need to be sent to the server. To increase the number of requests,
only document can be used. cookie = "··" to modify, too crude

localStorage

Data will be stored permanently, unless manually deleted
this point with the general will of

sessionStorage

Close the browser and empty

Guess you like

Origin blog.csdn.net/weixin_54163765/article/details/115192428