gatsby
create-react-app
does not help you generate a server-side-rendered app easily. Anything that comes with it (SEO, speed…) is only provided by tools like Next.js and Gatsby.
create-react-app
无法帮助您轻松生成服务器端渲染的应用程序。 它随附的所有内容(SEO,速度…)仅由Next.js和Gatsby之类的工具提供。
When is Next.js better than Gatsby?
什么时候Next.js比Gatsby更好?
They can both help with server-side rendering, but in 2 different ways.
它们都可以帮助服务器端呈现 ,但是有2种不同的方式。
The end result using Gatsby is a static site generator, without a server. You build the site, and then you deploy the result of the build process statically on Netlify or another static hosting site.
使用Gatsby的最终结果是没有服务器的静态站点生成器。 您生成站点,然后在Netlify或另一个静态托管站点上静态部署生成过程的结果。
Next.js provides a backend that can server side render a response to request, allowing you to create a dynamic website, which means you will deploy it on a platform that can run Node.js.
Next.js提供了一个后端,可以在服务器端呈现对请求的响应,从而允许您创建一个动态网站,这意味着您将其部署在可以运行Node.js的平台上。
Next.js can generate a static site too, but I would not say it’s its main use case.
Next.js 也可以生成一个静态站点,但是我不会说这是它的主要用例。
If my goal was to build a static site, I’d have a hard time choosing and perhaps Gatsby has a better ecosystem of plugins, including many for blogging in particular.
如果我的目标是建立一个静态站点,那么我将很难选择,也许盖茨比拥有一个更好的插件生态系统,其中包括许多用于博客的插件。
Gatsby is also heavily based on GraphQL, something you might really like or dislike depending on your opinions and needs.
Gatsby很大程度上也是基于GraphQL的 ,根据您的意见和需求,您可能会真正喜欢或不喜欢它。
gatsby