Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Search - "next.js"
-
This is what you're in for when you go for THE state-of-the-art "React stack". What you see in the screenshot below is the hellofresh.be website (it's the same as .com). It uses Next.js, React, emotion & styled-components (2 CSS-in-JS libraries). It uses 140MB of RAM for a single tab with some product cards and a slider, logs 70 console errors in production, and fails to load 3/4 times on Firefox.
On mobile, opening a meal card to view its recipe literally takes up to 10 seconds (and I have good connection and performant devices) and you can't choose the last meal card because a f*ing overlay hides the "add" button. And this is a global company with millions in revenue.
All this bugginess has already resulted in incorrect or missed deliveries and they're not doing anything about it. F* you Next.js & F* you HelloFresh IT management19 -
A new head of operations joins a small company.
— Okay guys, I’m planning for the long run. I need 500 warehouses across the country — we might need that capacity. We will build them rather than renting them — Amazon does the same thing, so we should too. We also need our own shipping fleet — FedEx has that too, so it’s a battle-tested approach. We might need that capacity. We need a future-proof solution.
— Uh… That’s kind of dumb. Are you kidding me?
A new head of engineering joins a small company.
— Okay guys, I’m planning for the long run. I need an AWS cluster running Kubernetes deploying microservices built with Docker. We might need autoscaling. Frontend should be Next.js + TypeScript — everyone does that now, plus we can develop a React Native app more easily if need be. We need a future-proof solution.
— Wow! That’s what I call a good manager. You really know what you’re talking about. You’re promoted!4 -
It is only now that I can finally appreciate how brilliant PHP is.
When you're new to programming, you write some HTML + CSS, it looks good, but the dynamic part is missing. So, you install PHP and just… write dynamic parts right in your HTML? How crazy is that? You can even write regular code there too! Errors are logged right away, common features like DB driver and sessions are built in…
It's all about marketing. Next.js does exactly the same thing when they brag about writing SQL in React. When they do it, it's revolutionary. When PHP does it, PHP bad. Gotcha fam 🫤15 -
There you are, fiddling with next.js webpack settings, because your isomorphic JS-in-CSS-in-JS SSR fallback from react-native-web to react-dom throws a runtime error on your SSR prerendering server during isomorphic asynchronous data prefetching from Kubernetes backend-for-frontend edge-server with GraphQL.
You have all that tech to display a landing page with an email form, just to send spam emails with ten tracking links and five tracking beacons per email.
Your product can be replaced by an Excel document made in two days.
It was developed in two years by a team of ten developers crunching every day under twelve project managers that can be replaced with a parrot trained to say “Any updates?”
Your evaluation is $5M+. You have 10,000 dependency security warnings, 1000 likes on Product Hunt, 500 comments on Hacker News, and a popular Twitter account.
Your future looks bright. You finish your coffee, crack your knuckles and carry on writing unit tests.5 -
For the very first time, I bought a personal domain, and created my personal website. Kept it simple and in a single page. And it's open source. Check it out at https://shubham.sh/
Built with Next.js and MDX ✨
Let me know if you like it. I'm excited to read your reviews and suggestions.
Repo link: https://github.com/imshubhamsingh/...9 -
Why the fuck nobody talks about Multi-page apps?! We went from a Web where everything was Multi-page server-rendered, and now everything for Web developers is "Single-page apps".
What about websites who can't do that? Not everything can be a single-page app. Only my uncle's restaurant website, or something which is TRULY a full app. No half choices.
If your website is a multi-page app/portal which actually PRELOADS data, instead of doing 100 fetch to an API within a page that is full of loading bars, well, your life is a pain.
When you want a first contentful paint which isn't a white page, well, your life is a pain.
What are React, Vue, Ember, Angular (let's exclude Svelte and Marko) going to do about Multi-page apps and SSR?
React-router sucks to me. It's performance is weak and it's useful only when you have an SPA with multiple sections which can be treated as pages (e.g. A single SPA divided in tabs).
Server-side rendering is the worst pain ever made by humanity, in React (and prob Vue, I didn't try but I can bet). And even when made easier from libs like Svelte and Marko, I (personally) can't get it to be faster enough compared to a traditional website without a JS framework and with a templating engine.
Anyways, if there's anything that I learnt from React, is to stay away from Next.js. Perfect, beautiful, mess.
All JS frameworks just seem to bloat the code and make it worse and slower, even though they're REALLY helpful.
Why? Why everyone loves them if their downsides are so clear? Why 3 projects out of 3 I made (1 React SSR, 1 Vue, 1 Marko SSR) are and will stay painfully slow and bloated, full of shit, even if in 2020 we should have evolved with the famous three shaking, with the famous lazy loading, etc.?
I am just frustrated.
And let's not even talk about Webpack, Rollup, Lasso, those module bundlers shit which are harder to configure and understand than finding a needle in a haystack.
Lasso was the easiest to configure but I anyways can't understand it. Webpack seems it was made to handle SPAs, as any tool in this freaking world, and not even considering an easy way to integrate multiple bundles for multiple pages (I know it's pretty easy, but with component sharing between pages and big unique bundles Next.js handles it soooo bad it feels like hell).
Am I the only one?
Sorry for the long rant. I just needed to rant right now.17 -
When I’m getting to 100k MRR, if I have any developers but me, I’m gonna spoil them. I mean making them obscenely spoiled. Here, take your 4 times the market salary. Enjoy the culture and never leave.
Why? Because my architecture approach makes products that don’t need many devs, plus I don’t like making useless features. Every product has a scope. Every scope can be completed. “There are always tasks” notion is wrong.
Also, because to me 1000% and 10000% margins aren’t different at all. Those who seek MOAR and MOAR money, amassing more money than they can ever spend, do it out of fear.
I don’t have any kind of fear. Those who looked their death straight in the eyes don’t fear materialistic misfortunes.
My favorite word is “enough”. I speak it to myself several times a day, over and over, like a mantra. It helps me overcome but-what-ifs that plague people to the point of using next.js just to make trivial saas apps that can be replaced by Excel in one week of work.8 -
God bless PHP
God bless Excel
God bless Visual Basic
God bless JavaScript
God bless jQuery
God bless Python 2
God bless Perl
God bless Bash
---
God, destroy React
God, destroy Vue
God, destroy Angular
God, destroy Java
God, destroy Next.js
God, destroy Rust
God, destroy Go
God, destroy Kubernetes
God, destroy Docker
God, destroy Flutter17 -
If you’re ever feel tired of annoying corporate presence everywhere, go straight to Next.js issues on github.
Since zeit (the company behind it) are too busy polishing their pitches and building more and more fragile betas, no one will ever help you with your problem there. They literally pitch and release more often than writing anything there.
People are seem to have built the help community there all by themselves, and the more I look at it the more it reminds me of SCP Foundation IKEA (http://www.scp-wiki.net/scp-3008) where people forever stuck in eerie infinite IKEA with no exit just built the whole new society.1 -
All the JavaScript "thought-leaders" have shitted up the ecosystem so damn much. Everything is so goddamn over-complicated it really took the joy out of programming.
A new dawn of simpler tools will come and all this trash will disappear. And not tools abstracting the garbage underneath. This is the cause of the problems.
Everything you think is gold is shit.
React, Next.js, Webpack, GraphQL, etc, etc.14 -
My boss gave me the task of rewriting the app to Next.js from regular react app, I've been procrastinating for a while now....2
-
https://github.com/PwnFunction/...
Who led this flattening user input object into the Next.js codebase, also thinking that `runContext` is going to make better companion than `eval`?
Yet another reason to switch over Sapper and other Svelte minimalistic solutions, in my opinion.rant nextjs security react gone wrong pwnfunction this is fine in the light of recent events with log4j code review disasters1 -
Just look at the open issues counters for "state-of-the-art" "production-ready" JS packages:
https://github.com/storybookjs/....
Almost 1900.
https://github.com/vercel/next.js
More than 1200.
It's just depressing5 -
How to protect API endpoints from unauthorized usage by bots?
If the API end points are meant to be used by any incoming to CSR frontend user without prior registration?
So far, my the only idea is going from pure CSR React to something with partial SSR at least in Node.js, Django or any other backend framework. I would be able restricting some API endpoints usage to specific allowed server ip.
Next.js allows dynamically both things as well.
As alternative I have a guess to invent some scheme with temporally issued tokens... But all my scheme ideas I can break really easily so far.
Any options? If SSR is my only choice, what would you recommend as best option in already chosen Django and not decided fully front-end framework?
I have the most crazy idea to put some CSR frontend framework literally into my django backend and making initial SSR from it. The only thing its missing... my lack of skills how to use React, but perhaps I have enough time to get a hang of it.
SSRed frontend can be protected with captcha means at least.16 -
Are there any Italian devs here? Or anyone who wants to move to italy? 😂
I built startupjobsitalia com a couple months ago to help early Italian startups and founders find local talent. I moved to Italy from Norway in 2022 and noticed that there wasn't a dedicated site for this like they have in the Nordics!
It was a good way to learn Next.js, OAuth, and Supabase, but it'd be way cooler if Italians could actually get some value out of it🤞🏻2 -
Trying to learn react and Next.js so far having one hell of a time even connecting a mongodb atlas database and displaying the data. Guides show nothings, YouTube shows nothing. Fun.5
-
Is there any stable Node.js framework that is convention based? My problem is everytime I begin a new project I have to think of the folder structure, packages to use etc. I looked into AdonisJS which seems to be what I need but then there are so many opinions on the internet regarding how it uses custom require mechanism instead of going ES6 style modules and how it is small and this will be no future proof . Tried Next.js and there seems to be steep learning curve. Any advices?2
-
In most businesses, self-proclaimed full-stack teams are usually more back-end leaning as historically the need to use JS more extensively has imposed itself on back-end-only teams (that used to handle some basic HTML/CSS/JS/bootstrap on the side). This is something I witnessed over the years in 4 projects.
Back-end developers looking for a good JS framework will inevitably land on the triad of Vue, React and Angular, elegant solutions for SPA's. These frameworks are way more permissive than traditional back-end MVC frameworks (Dotnet core, Symfony, Spring boot), meaning it is easy to get something that looks like it's working even when it is not "right" (=idiomatic, unit-testable, maintainable).
They then use components as if they were simple HTML elements injecting the initial state via attributes (props), skip event handling and immediately add state store libraries (Vuex, Redux). They aren't aware that updating a single prop in an object with 1000 keys passed as prop will be nefarious for rendering performance. They also read something about SSR and immediately add Next.js or Nuxt.js, a custom Node express.js proxy and npm install a ton of "ecosystem" modules like webpack loaders that will become abandonware in a year.
After 6 months you get: 3 basic forms with a few fields, regressions, 2MB of JS, missing basic a11y, unmaintainable translation files & business logic scattered across components, an "outdated" stack that logs 20 deprecation notices on npm install, a component library that is hard to unit-test, validate and update, completely vendor-& version locked in and hundreds of thousands of wasted dollars.
I empathize with the back-end devs: JS frameworks should not brand themselves as "simple" or "one-size-fits-all" solutions. They should not treat their audience as if it were fully aware and able to use concepts of composition, immutability, and custom "hooks" paired with the quirks of JS, and especially WHEN they are a good fit. -
Next.js is a piece of shit framework, (Like React is next level shit), which enforces things in the name of "convention" and is just a PITA to work with. Have to migrate an existing project to next? Make sure you use css-in-js, or you cant use next. Want to use a shared layout? lol, gtfo. Want statically optimized assets? make sure you call the correct apis in pages or you get no optimization.
┻━┻︵ \(°□°)/ ︵ ┻━┻5 -
I have a side project which contains very simple data (a URL and a list of strings associated with that URL). I would like a way to automatically generate a webpage for each of those links (I believe the right term is template ?). Does anyone have any suggestions? Is this something like Next.js or Gatsby would be used for? I can provide more info if I’m not clear enough8
-
I found Server-Side Rendering in Next.js & astro a difficult sell (and I'm not a JS framework enthusiast), but this Solid JS SSR guide makes me want to consider it, maybe: https://solidjs.com/guides/server/. I really like the philosophy of one of their subpackages: https://github.com/solidjs/solid/...
This could inspire future enhancements to the foundations of my SSG, metalsmith. -
Ok. If you had a blog made with next.js and mongodb, and you are too depressed and lazy to learn AWS lambda/serverless, where would you deploy?15
-
I’ve been jumping on techs for a web application I wrote in Next.js and Mongo (mongoose) using Typescript.
The problem- I hate looking at codebase. Partly due to mongoose has a bug which makes type intelisense slow.
Moving forward, I’ve been creating different projects of the backend, in plain node typescript, in nest, in graphql but my inner self wasn’t satisfied.
Last night I deleted all the projects and decided not to change anything and continue working on the garbage code I’ve written a year ago.1 -
can someone guide me How to show courses learned from Documentation(JavaScript, Django, react.js, next.js etc) in a resume and committed in Github parallelly1