Categories
Jobs

Pleased to announce a new role

I’m very excited about my new role as Senior Frontend Developer at Rexlabs in Brisbane.

This is an opportunity to work for an actual industry success story. A prosperous software house, it employs around 60 engineers and makes really good software to the real estate industry.

“A team of entrepreneurs that seek to take complex problems and untangle them into simple, usable products.”

Rexlabs.io

Categories
React

To use PropTypes in React or not

We’ve developed a simple rule of thumb to follow on this question;

“Don’t. Use. Bloody. PropTypes. They’re just annoying.”

Why do people use PropTypes?

One way to catch and debug errors in your software as you develop is the use of typed programming. JavaScript didn’t used to have that and that was thought of as a bad thing. So when coders came to JavaScript from ‘proper’ programming languages which did enforce strict typing they brought their shit idea with them. They probably thought it would make JavaScript better.

It doesn’t. If you want a typed language for some reason, use typescript. There’s a time & a place for PropTypes. The time is in the past and the place is in the bin.

Why NOT to use them?

They cause crashing errors all the damn time, bloat your code and generally put barriers in the way of clarity and efficiency. If PropTypes are helping you, you should look at how you’re developing.

Learn more about what PropType means from the horses mouth (reactjs.org)