TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Does your idea really need a server?

3 点作者 talsraviv将近 13 年前

1 comment

gizmo686将近 13 年前
My concern with using localStorage.has_paid isn't a malicious user trying to cheat, but a legitimate user loosing their has_paid status, which bring up the larger issue that you are saving the user data in the mysterius localStorage, and how many people know where that is, or that erasing your history will delete it, or any other thing that could go wrong.<p>Also,isn't saving key-value pairs on a per user bases a common enough problem to have already been solved. It would involve one blackbox program on the server, the javascript could be as simple as:<p>serverStorage.login(username, password) serverStorage.getValue(key) serverStorage.function setValue(key,value)