3 ms·
I sometimes develop javascript things. And indeed it is a complex system. I only do it once or twice a month. I have build a few react native and web apps. All
by BozeWolf 6y ago
I sometimes develop javascript things. And indeed it is a complex system. I only do it once or twice a month. I have build a few react native and web apps. All them are hard to work on because i didnt touch it for a while. Anyways, i am not familiar with next js.
-Is it the same thing as nuxt js but different?
- Yarn? I thought that npm was the thing to use again.
- How does yarn know that “create next-app” command? Perhaps some yarn install globally thing?
- Does it include typescript support or is it javascript only?
- Which node version is needed? And if I switch, is that create next app still available then?
- How many things are transpiled? Are there any other concepts i need to understand?
- What is the testing framework of choice these days?
- 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.
- Apparently i need this layer on top of react client side rendering. Another concept.
- 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.
- 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?
Even if every answer is positive, it is such a huge amount of stacked concepts and technologies.
Dont get me wrong, i like programming in javascript / typescript. I think the programming is fun, but fixing the damn tooling and having debates about it sucks.
- a_wild_dandan 6y ago> Is it the same thing as nuxt js but different? NextJS is a library for doing server-side rendering in your React app. I've never touched Vue, so I don't know if that's what nuxt js does > Yarn? I thought that npm was the thing to use again. They're fairly interchangeable and it doesn't matter much these days. > How does yarn know that “create next-app” command? Perhaps some yarn install globally thing? Yeah it checks the registry of create-* packages and installs the relevant ones. > Does it include typescript support or is it javascript only? Yep, by default can use TS with NextJS. I only use TS when possible. Going back to vanilla JS is a horrifying thought! > How long will this framework be hip? React is probably the most popular front-end framework and pretty beloved. It's used seemingly everywhere these days. Since SSR is such an important use-case for websites, I'd wager that combined with how prevalent React is, NextJS will be around for a long, long time. > 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. Anecdotally, I've used the default configs for create-react-app starters, NextJS, or Electron Forge starters and haven't needed to modify anything.
- 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.