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

科技回声

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

GitHubTwitter

首页

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

资源链接

HackerNews API原版 HackerNewsNext.js

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

Ask HN: How do you build complex web apps with vanilla JavaScript

5 点作者 sunsetSamurai超过 3 年前
Hello everyone, I wanted to ask you how do you learn to build complex web apps by just using javascript? It seems to be a common thing to complain in HN about bloated websites with a heavy use of js and frameworks, for example: https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=29703546.<p>Every time I try to build anything more complex than a weather app, my codebase becomes a mess. I&#x27;m still very new to software development and I still have a lot to learn, so maybe that&#x27;s part of the problem. How do you manage your app state, how do you get back your state after a crash or a refresh? All these seem difficult to accomplish without a framework.<p>Any good courses, blogs, repos to study in order to learn this? Thank you!

1 comment

jsprogram超过 3 年前
Some of the vanilla JavaScript methods come from libraries, for example querySelector and fetch. It used to take a few lines of code and a callback to do a XHR in JavaScript, then it was replaced by fetch. In the older example, you can just use querySelector and fetch from the library then ignore the rest of the library.<p>You can also look for libraries that are short, for example Redux. It was much shorter than Flux but was so much better that the Flux creators recommended Redux.