Trusted answers to developer questions
Trusted Answers to Developer Questions

Related Tags

productivity
codesandb
repl
problem solv
communitycreator

5 tips for overcoming coder's block

Osinachi Chukwujama

5 tips for overcoming coder's block

TL;DR

  1. Use a sandbox
  2. Get a cheat-sheet
  3. Take a quickstart
  4. Break down the problem
  5. Mix 'em up

Intro

Usually, developers experience a block. During the block period, they don’t write any useful or reasonable code. This block may be due to tiredness; you may have been coding for days without a break. But when you can’t code because you have no idea how to approach the problem, follow the tips below.

1. Use a sandbox

Sandboxes are great because they help you to immediately flesh out some code. Most times, they are separate from your project, which means that your old code won’t weigh you down. Some great sandbox environments are:

  1. Codesandbox
  2. Codepen
  3. Repl
  4. Glitch

The ability to download your modules and packages in no time is a big plus.

2. Get a cheatsheet

When using new technology, you might need a general overview but are too lazy to watch a crash course (it happens). So, you need to read a cheat sheet. To get one, just google “{insert technology name} cheat sheet filetype:pdf”. If you don’t need the cheat sheet in pdf format, you don’t have to include the filetype:pdft.

A cheat sheet will show you the big picture. No crash course can beat that (in my opinion).

3. Take a quick start

Consider using a quick start if your first instinct is to watch an intro video. You should experiment once in a while. Go to the docs of the technology and check out the quick start. Most modern, well-documented projects have a quick start. A quick start will allow you to quickly get your hands dirty while referring you to relevant links in the docs.

4. Break down the problem

How can you solve a problem without breaking it down? This is a fundamental part of problem-solving.

Say you want to add state management to an app with several levels of state. You can begin by sketching the state-flow among the key components, or by going down to your readme or a new markdown file and writing how to implement feature-x. This way, your brain will be more prepared to face the problem at hand.

I recently discovered that draw.io has a VsCode extension. You can use draw.io right from your favorite editor. If you are a visually-oriented thinker, this extension is for you. If you aren’t, still consider diagrams of state-flow and logic.

5. Mix 'em up

So, you have these four tips and you still don’t know where to start…Mix them up! You could start with tip 4 and then go to tip 2. It all depends on your use case. Don’t slack when you have the power not to.

Note: rubber ducking and pseudocoding. I don’t practice rubber ducking and flowcharting can replace ​pseudocoding.

Thanks for reading.

RELATED TAGS

productivity
codesandb
repl
problem solv
communitycreator
RELATED COURSES

View all Courses

Keep Exploring