reactpractice's profile picture. Coding challenges to improve your React skills.

reactpractice.dev

@reactpractice

Coding challenges to improve your React skills.

Spelling mistakes can make your code look unprofessional. Instead: - ✅ use lowercase to name your variables (e.g. `match`) and use uppercase for naming your components - ✅ use camelCase when a name is composed of multiple words - e.g. `isLoading`, `MemoryGame`

reactpractice's tweet image. Spelling mistakes can make your code look unprofessional.

Instead:
- ✅ use lowercase to name your variables (e.g. `match`) and use uppercase for naming your components 
- ✅ use camelCase when a name is composed of multiple words - e.g. `isLoading`, `MemoryGame`

How would you pass the params for this GET request if you wanted them to be configurable? Checkout the article for the how to use the URLSearchParams API for this! reactpractice.dev/articles/how-t…

reactpractice's tweet image. How would you pass the params for this GET request if you wanted them to be configurable?

Checkout the article for the how to use the URLSearchParams API for this!

reactpractice.dev/articles/how-t…

Did you know "Create React App" is no longer maintained? Start your React projects with Vite instead! reactpractice.dev/articles/how-s…


msw is great for mocking requests when testing your react components. Do you use it in your projects?

reactpractice's tweet image. msw is great for mocking requests when testing your react components.
Do you use it in your projects?

Do you think this snippet throws when the server returns HTTP error code 500? It doesn't! Instead, `fetch` returns the response `ok` property as `false`, and you need to check for that.

reactpractice's tweet image. Do you think this snippet throws when the server returns HTTP error code 500?
It doesn't! Instead, `fetch` returns the response `ok` property as `false`, and you need to check for that.
reactpractice's tweet image. Do you think this snippet throws when the server returns HTTP error code 500?
It doesn't! Instead, `fetch` returns the response `ok` property as `false`, and you need to check for that.

How do you type a custom hooks that accepts a generic data type? When using an arrow function, you can add `<T>` at the beginning of the function:

reactpractice's tweet image. How do you type a custom hooks that accepts a generic data type?
When using an arrow function, you can add `&amp;lt;T&amp;gt;` at the beginning of the function:

Custom hooks are great at abstracting logic. What are some custom hooks you built in your projects?

reactpractice's tweet image. Custom hooks are great at abstracting logic.
What are some custom hooks you built in your projects?

reactpractice.dev podał dalej

The tech stack I'd use in 2025 ⏭️ Next.js ⚛️ React.js 🔗 TypeScript + Zod ❌ No Form Library 🎨 Shadcn + Tailwind 🎯 React Query (optional) 💎 Prisma + Supabase 🔒 Lucia (Oslo + Arctic) ✉️ React Email + Resend 📁 AWS S3 + IAM 💤 Inngest 😎 Coolify Blog Post in reply 👇


Just published a new React challenge: build a custom `useFetch` hook starting from failling unit tests! reactpractice.dev/exercise/build…


Great to see the React team officially deprecating `create-react-app`. It's been unmaintained for a while, so this bring clarity to the community that it shouldn't be used anymore. What to use instead? I recommend Vite for practice projects!

Today, we’re deprecating Create React App for new apps, and encouraging existing apps to migrate to a framework. We’re also providing docs for when a framework isn’t a good fit for your project, or you prefer to start by building a framework. react.dev/blog/2025/02/1…



How do you pass query string params to a GET request with `fetch`? Use the `URLSearchParams` API!

reactpractice's tweet image. How do you pass query string params to a GET request with `fetch`? Use the `URLSearchParams` API!

reactpractice.dev podał dalej

If you’ve ever needed to break up a long JavaScript task to keep the UI responsive, you’ve probably reached for setTimeout(). Turns out there are a boatload of other options at your disposal, like scheduler.yield(). I wrote about a handful & their tradeoffs:

amacarthur's tweet image. If you’ve ever needed to break up a long JavaScript task to keep the UI responsive, you’ve probably reached for setTimeout(). Turns out there are a boatload of other options at your disposal, like scheduler.yield(). I wrote about a handful &amp;amp; their tradeoffs:

New challenge just launched - build a budget app dashboard! Start from a sample JSON file of transactions and show aggregated amounts and expense charts to get insights about each months expenditure.

reactpractice's tweet image. New challenge just launched - build a budget app dashboard!

Start from a sample JSON file of transactions and show aggregated amounts and expense charts to get insights about each months expenditure.

Great article about the importance of writing code that is easy to understand! Timely reminder of the importance of naming variables, components and how to decide on when to split a component down or not. minds.md/zakirullin/cog…


United States Trendy

Loading...

Something went wrong.


Something went wrong.