Best way to store small UI user preferences in web app?

后端 未结 4 830
执念已碎
执念已碎 2020-12-02 18:42

I have a web app I\'m developing and quite like the idea that if the user makes changes to the view of the UI (eg. Lists open or closed, certain viewing preferences) those c

4条回答
  •  无人及你
    2020-12-02 19:04

    Do you want the look and field changes remembered across multiple machines? Are they critical or will they cause major user frustrations if they are forgotten (clear cookies)?

    The answer to this question decides whether you store locally or on the server.

    If this is not required then a cookie or local storage should be sufficient. HTML 5 local storage is not really prevalent (a little old question).

    If you want to remember across machines, a database is the only option.

提交回复
热议问题