2 ms·
> Is it the same thing as nuxt js but different? Yes. > Yarn? I thought that npm was the thing to use again. Yarn has many features that npm doesn't - plugin
by searchableguy 6y ago
> Is it the same thing as nuxt js but different?
Yes.
> Yarn? I thought that npm was the thing to use again.
Yarn has many features that npm doesn't - plugins, constraints, PNP, zero installs, workspaces, etc.
> How does yarn know that “create next-app” command? Perhaps some yarn install globally thing?
You can do yarn dlx or npx create-next-app. It will temporarily install and run the package or command.
> Does it include typescript support or is it javascript only?
Typescript support is as easy as changing your file names, installing typescript, and adding a tsconfig. You don't need to set up anything. Next does it for you on the first run.
> Which node version is needed? And if I switch, is that create next app still available then?
You are cool with current LTS and previous LTS (from my testing).
> How long will this framework be hip? Am i talking about months, a few months, a year, two years? Hip is important, i (or new employees) dont want to work with software which is considered old fashioned.
Next has been supported for years. Vercel is the company backing next for their platform so I would say about the same time as vercel. Given they got funding this year, don't think they will die soon.
> What is the testing framework of choice these days?
jest
> How many things are transpiled? Are there any other concepts i need to understand?
SSR. There are few concepts you will have to learn to actually take benefit of it (getServerSide props, getStaticSideProps, etc) but out of the box, you don't need to do anything different. The routing is already included so that's one less thing to worry about. Next does automatic static optimization (unless you do something stupid with your root app). You are benefiting without doing any work.
> Full control over babel or webpack is exactly the thing which makes it complex. It is probably easy to get started and then you have to make that little tweak on a changed babel plugin to make “it” work.
Most things will work via the next plugins. It will be a rare case where you have to set up your own server. You can take full control when you want.
> Is frontend and backend react the same? As in: will it share the same babel config and will every node function be available on the client side and vice versa?
Next builds your app and responds with either fully static views or via pre-hydrated views hydrating on the client-side. Look up hydration in react.