6
Tounai
13d

Fuck react, fuck nextJS and fuck frontend unit testing, it doesn’t work and will never work.

Comments
  • 1
    Exactly. Fully agreed. I have still never seen any fucking nextjs developer write 1 single fucking unit or integration test. In fact they are so fucking stupid they explicitly say testing is a waste of time and not important. They think unit testing is the old way of writing software
  • 0
    I find React fairly testable as far as frontend goes. Flushing the task queue is clumsy but other than that it's fine IMO.
  • 0
    @b2plane 90% of the time, it tests the test itself. Testing in React is broken and NextJS makes it even more broken. I 100% prefer end to end tests, which are quite broken as well, but have the benefit of actually testing something meaningful.
  • 1
    @lorentz As long as you test small simple components it’s fine, but when you try to deal with routing, or more complex feature of React it becomes unbelievably complex. And the worst part is not writing the test, but modifying it when you modify a component, to the point that I generally prefer making another component rather than editing the one in place.
  • 1
    testing components is an integration test

    unit tests on functions work fine?
  • 1
    Yehh.. If frontend changes often, it's better to just do e2e tests. Browserstack is free for opensource.
Add Comment