16 ms·
Next.js 13
- pen2l 4y agoI'm pleased to see cumulative layout shift (re self-hosted fonts) advertised as a feature, this is the right kind of user-centric development, indeed the small details like these go a long way in improving user experience.
- neurostimulant 4y agoNot knowing anything about the new /app directory support, I'm able to migrate my static landing page in about two hours. The resulting page is definitely smaller and load faster than the previous version. Now I'm consistently getting 100 on page speed insight (mobile) while previously it's hovering around 98-99. The documentation for the new /app directory support is not complete though. API routes seems to be not documented yet (or is it not implemented yet?) so I haven't ported mine and leave it on the /pages/api directory for now.
- javiercr 4y agoAPI routes are not supported yet for /app
- adoxyz 4y agoAwesome release. As an early adopter of Next.js and seeing it evolve over the years, it's been one of the most consistent frameworks that continues to get better and "just works". Is it perfect. No. But it's very close for most of my use cases.
- samyok 4y agoAll these changes look great. I'm especially glad that next/link always renders an <a> now, if I read it right it seems to solve the "create a dummy span around some imported component" issue.
- davidspiess 4y agoWhat i am still missing is the possibility to deploy next.js to a serverless platform where files have to be stored in S3 or Google Cloud Storage. Had anybody success to get it working, without loosing ISR functionality?
- JSavageOne 4y agoWhere are you struggling? Just `next build && next export` and your static site is compiled to the /out folder which you can subsequently push to S3 or Google Cloud Storage. No idea what ISR stands for.
- davidspiess 4y agoIncremental Static Regeneration. Next.js allows you to create or update static pages after you’ve built your site but stores them on the filesystem, which in a serverless environment does not exist.
- dsissitka 4y agoEdit: There's some more discussion about Turbopack at https://news.ycombinator.com/item?id=33333695 https://news.ycombinator.com/item?id=33333695. Looks like they launched a webpack alternative called Turbopack today: > Next.js 13 includes Turbopack, the new Rust-based successor to Webpack. https://vercel.com/blog/turbopack https://vercel.com/blog/turbopack https://turbo.build/pack https://turbo.build/pack
- nightski 4y agoSigh another one? I thought Vite was the new thing.
- AlmostAnyone 4y agoSigh? I think the speed improvement is awesome.
- hirop 4y agoIt is awesome to see so much innovation, but it can be exhausting to keep up.
- apozem 4y agoI'm quite alright with new tooling every six months when the new thing is orders of magnitude faster. If people want to compete to make my job as a frontend dev easier and faster, that is just fine.
- nightski 4y agoIdeally we could learn how to make the existing tools better/faster and create software that can evolve rather than re-writing everything from scratch every six months.
- yboris 4y agoI suspect at some point we hit the limit of the language performance. I can't imagine JavaScript beating Rust when both are written well.
- yboris 4y agoTurbopack (comes with Next.js 13) seems AMAZING! > Turbopack updates 10x faster than Vite and 700x faster than Webpack > Turbopack is an incremental bundler optimized for JavaScript and TypeScript, written in Rust by the creators of Webpack and Next.js at Vercel.
- solardev 4y agoSuper excited about Turbopack! Thank you for moving the Web forward so much.
- gl-prod 4y agoNext[js] Conf is live right now at https://nextjs.org/conf https://nextjs.org/conf
- latchkey 4y ago// "alt" is now required for improved accessibility I'm all for accessibility, but let us decide when to implement it.
- calvin 4y agoYou should still be able to use alt="" to indicate that it is "decorative" and not meaningful imagery for a visually-impaired user.
- latchkey 4y agoThat's like the difference between null and undefined.
- cramforce 4y agoIf you have no alt attribute, then screen readers read the URL! Empty strings are the way to go for decorative images
- deleted 4y ago[deleted]
- latchkey 4y agoWhat if I have an app that no screen reader will ever read?
- joshka 4y agoThen write your own component that extends and removes the requirement. Until then, web tooling is better off explicitly acknowledging that accessibility is an explicit goal.
- abujazar 4y agoAlt is a required attribute of the <img> tag, so requiring it is just basic validation. C code won't compile if you omit the semicolon after statements, either.
- guhidalg 4y agoTheir tutorial is incredible, everyone should take a lesson from Vercel on this: https://nextjs.org/learn/foundations/from-react-to-nextjs/getting-started-with-nextjs https://nextjs.org/learn/foundations/from-react-to-nextjs/ge... Tell me: 1. What I need to know to understand this documentation 2. The before state (plain React.js) 3. The after state (Next.js) I'm fucking sold, I'm going to use Next.js just based on how well written this documentation is.
- hardwaregeek 4y agoI'm totally biased here but I've been super impressed with the documentation culture at Vercel. Definitely a high high priority internally.
- JSavageOne 4y agoTheir tutorial is fine, but personally I'd much rather just see a GitHub repo of a project that covers all the basics (eg. a CRUD app).
- toinewx 4y ago> I'm going to use Next.js just based on how well written this documentation is. I Understand the euphoria, but this is a pretty bad take.
- guhidalg 4y agoIs it? Give me an example of a poorly documented yet wildly popular and good software tool built in the last 10 years (No Stockholm Syndrome for old tools allowed!).
- NayamAmarshe 4y agoSurprisingly, my compile times with Next.js 12.3 have been really really awful. A simple CSS change takes almost 10 seconds to compile and I'd love to know why. My app isn't complex, it uses Recoil, Tailwind and that's it. Compile times were better in v11 in my experience.
- parhamn 4y agoThe next-gen bundler rewrites are getting insane, just as things were consolidating in the other parts of JS. We now have: - EsBuild - SWC (also written by someone who works at Vercel) - TurboPack - Vite (rollup) - Parcel - Rome I've noticed in the javascript ecosystem there is much less convergence than in other languages. Everyone wants a flag in the ground.
- halfmatthalfcat 4y agoThat's a good thing? Keeps things fresh and keeps established "norms" unable to stay complacent.
- nightski 4y agoActually it tells me that the javascript ecosystem fails to build software that can adapt to change. The culture is to throw everything out and start fresh every time they want to do something different. It's terrible engineering.
- halfmatthalfcat 4y agoThankfully that's just your opinion. I appreciate all the innovation and experimentation that's happening. Nobody is dictating you or anyone else use these tools.
- ConsoleTVs 4y agoIt's not an opinion. It's common sense. Do you think Rust or Swift would exist if LLVM would have stopped its development long ago in favour of <insert new exiting tool>? Not only in software, if we keep renewing rather than perfecting software, we won't go anywhere.
- deleted 4y ago[deleted]
- nightski 4y agoMy opinion based on decades of experience in web development. I've been through this churn dozens of times, it is tiring. The other ecosystems I work with do not work this way and yet they still innovate a lot.
- slooonz 4y agoI find the data fetching example extremely confusing… 1. Where does this "use" comes from ? It is not present in the official React API reference : https://reactjs.org/docs/react-api.html https://reactjs.org/docs/react-api.html 2. It says that the value is not serialized, but what if Page is rendered client side and I want getData to always be executed server side (for example, it may contains secret API key, or make a database call) ? 3. getData is async, so what happens to name if the promise is not yet resolved ?
- nthitz 4y agoit's a new "hook", https://vived.io/new-hook-is-coming-to-react-frontend-weekly-vol-109/ https://vived.io/new-hook-is-coming-to-react-frontend-weekly... https://github.com/reactjs/rfcs/pull/229 https://github.com/reactjs/rfcs/pull/229 contain some discussion
- Vinnl 4y agoBut `use` is still just in the RFC phase, right? How can Next.js already be (committing to) using it?
- andrewingram 4y agoThey’re essentially both in beta, but for something like this, React needs a proving ground - hence it’s being used in Next’s beta functionality
- Vinnl 4y agoOh! I'd mis-parsed the heading sizes, didn't realise the "data fetching" heading was underneath the "app/ directory (beta)" heading, and thus that they were both in beta. Thanks!
- rektide 4y ago> With Server Components and nested layouts in Next.js, you're able instantly render parts of the page that do not specifically require data, and show a loading state for parts of the page that are fetching data. With this approach, the user does not have to wait for the entire page to load before they can start interacting with it. Crazy huge user win. I am a little nervous how much stuff Next does in the middle, how thoroughly it links front & back end. Streaming a page with chunks missing then streaming sections as they resolve is pretty advanced magic. Amazing DX experience but I also can think back to asp.net & remember huge viewstate blobs & utterly magic middle-layers, and those were powerful too, but impregnible bizarre systems to the developer & that wasnt good. Next keeps hitting reaply really nice sweet spots & consolidates & tackles so many problems, and my trepidation is small at this point, but this is really redefining the page a lot, & I feel like I really want some deep dives on the technics involved here, want to know the magic is somewhat accessible & coherent, for fellow would be meddlers.
- andrewingram 4y agoI’ve been trying out the pre-release version for the last couple of months, just published a quick brain dump of my thoughts related to the major changes (router, server components, etc) as they stand today. I’ve already heard from the team about the plan for my last concern, and it seems viable. https://andrewingram.net/posts/thoughts-on-next-13-react-18-3-dynamic-with-some-limits/ https://andrewingram.net/posts/thoughts-on-next-13-react-18-...
- elforce002 4y agoI started my journey with Vue, then Nuxt (of course),then switched to React and last year started to use Nextjs. So far I have no complains (at least no big ones). With new frameworks poping out (qwik, remix, fresh, etc...), it's getting really interesting and tiresome at the same time. We're migrating all our platforms to React/Next and we couldn't be happier. Is it perfect? Nothing really is. Next is good enough, the community is engaged, the ecosystem is big, and the industry is basically dominated by react (giving react devs some sort of peace of mind when looking or switching jobs). Sometimes, you have to pick a piece of tech and roll with it as long as the tech keeps improving and the community improves alongside it. Nextjs is currently doing it.
- Old_Thrashbarg 4y agoI'm curious why you decided to migrate from Vue to React.