DEV Community

Cover image for 6 Ways to Help Keep You Going When Working on JavaScript Projects
jsmanifest
jsmanifest

Posted on • Originally published at jsmanifest.com

6 Ways to Help Keep You Going When Working on JavaScript Projects

Find me on medium

While you're coding you might feel happy, sad, tired, or unmotivated. Some of these can undermine your abilities to effectively code JavaScript applications. But there are ways to treat this behavior (based on my experiences) and keep you coding for the whole day without feeling overwhelmed.

In the weekends I spend an average of 15 hours per day coding in JavaScript or at least being involved somewhat in some JavaScript related activity like reading changelogs of libraries or listening to JavaScript related podcasts on YouTube. While it's unhealthy to be doing these for such long periods of time, the point I want to make is that I never get bored and I always feel like the day ends TOO soon, which i'm sure is what some developers need in their lives--to stay focused and not get distracted, bored, or overwhelmed at writing JavaScript applications. When the weekend ends, I always feel like I need more time.

This post will list some things that make me code for longer periods of time and the goal is to help shed some light on how you can take some of these tips to improve your focus on your tasks.

Having said that, this isn't an article where I'm saying "Please do this to code for 15 hours a day like I am". You don't need to code 15 hours a day. You just need to avoid feeling unmotivated, hopeless, or overwhelmed. We're all adults here and I trust you to make the best decision :)

When you're not working, don't be like me where I'm still coding until it's bed time. I have my reasons but I am glad I'm able to code and never get bored, which happened to be something I needed at the right time. Spend time with your family, friends, and eat well!

Here are 6 Ways to Help Keep You Going When Working on JavaScript Projects.

1. Have At Least One JavaScript Project in Active Development That You Believe Will Benefit Your Future

10-10-10 rule
Photo by Avi Richards on Unsplash

I like to use the 10/10/10 rule to keep me in check and motivated to code for ridiculously longer periods of time. I always like to have a project that i'm actively developing on when I'm not working which I believe will end up providing a lot of impact on my future.

But how can you tell if your project will benefit your future?

While definitions of the 10/10/10 rule vary here and there, here's the 10/10/10 rule I follow at all times:

Will this project be worth all the trouble 10 days from now? How about 10 months from today? 10 years? If it satisfies all three of these criterias, this should be enough to keep you on your feet to code like your life depends on it. And when it's time for bed, you'll feel like you're going to code harder tomorrow because you underestimated today.

2. Listening to JavaScript Podcasts

listening to javascript podcasts
Photo by Juja Han on Unsplash

I like to listen to JavaScript related podcasts in the background while I code. This means I would just turn on a podcast and leave it running in the background while I write JavaScript.

Before I begin working on something, I often like to brainstorm the code that i'm going to write so that my mind is already prepared for writing so that I can confidently give a little more attention to the podcast playing in the background.

The reason why I like listening to podcasts in the background is because it helps keep me updated with what's going on in the JavaScript community and I always end up learning new things about people, the technology, best practices in code, etc. This sort of fills in the gap of missing out on the social experiences. This might apply more or less important for certain people.

Podcasts go by quick, and normally by the time the podcast ends it makes me feel productive because now I've got all this new valuable information in my head. This makes me feel great about my progress. It excites me. You know that awesome feeling when you're finally getting progress from the gym, and now you just don't want to stop? Keep the momentum going.

The podcasts I listen to is normally whatever sparks my curiosity. I listened to Kent C. Dodds and Ali Spittel while I coded and learned valuable insights on life like how people deal with imposter syndrome when it creeps onto them, which online communities are toxic (Very important actually. Surround yourself with positive energy and keep yourself motivated and strong at all times), how she became successful, etc. An important thing to keep in mind when listening to these podcasts is that these people are JavaScript developers too. Anything they experience can potentially become your experience.

Some other notable ones I listened to were between Kent C. Dodds and Dan Abramov and Kent C. Dodds and Swyx. Podcasts like these expose some valuable information that you wouldn't find anywhere else.

3. Listen to Good Music

listen to good music while writing in javascript
Photo by Steinar Engeland on Unsplash

This might sound silly but when I listen to music that make me feel "badass", I apply better code practices which makes coding a great experience.

Many positive effects can happen by listening to music while you code. For example, a research from the journal of Psychology of Music in 2005 had demonstrated that software developers had experienced increased positive moods, quality and efficiency when listening to music. It also mentions that music can alter your moods.

I've never had a great coding experience listening to sad music. Just putting this out there.

4. Always Having a Cup of Coffee Nearby

always have a cup of coffee nearby when writing javascript
Photo by BRUNO CERVERA on Unsplash

Coffee helps you code more effectively in several ways. First, the consumption of coffee was proven to improve memory and cognitive function over time as we age. This means that our performance in writing JavaScript applications (or anything really) becomes stronger as we're able to solve problems faster and focus on tasks throughout the day.

Now when I drink coffee while I code, I find myself coding for longer periods of time. It helps make me type faster and it noticeably helps to avoid random thoughts of my personal life in between coding.

It helps keep my focus and mindset in check. There is some backed up science behind this effect in coffee consumption.

For example, coffee can help temporarily relieve annoying headaches because it reduces inflammation in the body. But sometimes I get headaches from drinking coffee. In this case it might occur to me that dehydration is the cause (water ALWAYS helps to remove the headache when this happens by the way). Coffee stimulates the release of dopamine, improving mood and helps stabilize your emotions so I feel better throughout the day. This also contributes to the effects of keeping random personal thoughts away from coding. It's a natural adderall.

5. Drinking Water Every 30 Minutes (Coffee still applies)

drink water while developing in javascript
Photo by Steve Johnson on Unsplash

At my job, people know that I drink a lot of water because i'm always carrying and refilling these bottles. I drink a minimum of three of those per day.

Water helps me maintain a good state of mental health and wellbeing which is a vital combination with frequent sips of coffee! This is probably the most effective habit in the entire article that helps you code longer. I'd call it a secret of mine, but that'd be silly. We should all drink plenty of water and at least a cup of coffee every day :)

6. Sitting Next to a Window With Sunlight

sit next to a window with sunlight when writing javascript
Photo by Ethan Sykes on Unsplash

My desk is literally right next to my window inside my room. When I wake up in the morning, there's sunlight coming through this window. My computer is literally right next to it. It's like I have a window in my chest where sunlight is pouring in. JavaScript, here I come!

Try not to be coding in dark areas. When walls and desks are dark, or when there aren't any plants or pictures on the walls, this has detrimental effects on your health and productivity which can lead to depression and anxiety.

Conclusion

And that concludes the end of this post. I hope you found something valuable and look out for more in the future!

Find me on medium

Top comments (12)

Collapse
 
chrisachard profile image
Chris Achard

15 hours per day sounds like a bunch! But I totally get what you mean when you feel like a day ends TOO soon (even when you've been coding the entire day). Do you think that your pace will change, or do you think you'll keep doing that much for a long time into the future?

Thanks for the post - lots of good advice there :)

Collapse
 
jsmanifest profile image
jsmanifest • Edited

No problem! I will definitely not be spending 15 hours a day in the future like I currently am. It can get a little boring if you work reactively and not proactively--but thankfully some things can keep me going (as explained on this page) I haven't been able to do the things like "normal" people do, in years. Watching a movie for example; I haven't really watched a movie in over three years. Watching tv shows and movies were one of my funnest activities. It sounds bizarre. But since I do have plans to shift this lifestyle into a more social approach, it's not that much of a bother. Just going with the flow as long as I'm following my plans then everything will be okay.

Collapse
 
chrisachard profile image
Chris Achard

Sounds like you have a plan :) Hope everything goes well for you!

Collapse
 
iamfeek profile image
Muhammad Syafiq Hanafee

Have you calculated how much water you drink a day, while at work? In litres or whatever imperial equivalent

Collapse
 
jsmanifest profile image
jsmanifest • Edited

Hi Muhammad. Yes I have. One bottle of these is nearly equivalent to three 16.9oz of water bottles each. On average I drink a little more than 150oz of water a day

Collapse
 
iamfeek profile image
Muhammad Syafiq Hanafee

Cool!

I hope you don't mind me asking about the semantics of your water habit.

  1. How long do you you take to drink that 150oz?
  2. For every "drink instance", how much do you drink?
  3. For every "drink instance", do you take sips or is it more of a continuous gulp?
  4. How often is your trip to the toilet?
Thread Thread
 
jsmanifest profile image
jsmanifest

Hi muhammad,

  1. I drink it throughout the day until I go to bed. So my last gulp of water is usually 45 minutes before I sleep.

  2. Each time I take a gulp or two of water. Every other thirty minutes I would naturally just take a couple of gulps more.

  3. I always take a gulp or more. When my water becomes warm I usually try to finish it quickly so I can refill it with iced cold water.

  4. About every hour on average.

Thread Thread
 
iamfeek profile image
Muhammad Syafiq Hanafee

Awesome stuff!

So I calculated that I want to drink about 4.5 litres while at work.

I work from 10am to 6pm.

I have a mug that is 500ml.

I calculated 9 refills!

I then calculated the time it will take to do 9 refills.

Check out this schedule

Thread Thread
 
jsmanifest profile image
jsmanifest

Approximately one bottle an hour or half a bottle every 30 minutes is very doable! How has it been going so far?

Collapse
 
justsharkie profile image
/*Sharkie*/

Another benefit of drinking lots of water - it gets you out of the chair more (for bathroom breaks!)

Great article!

Collapse
 
jsmanifest profile image
jsmanifest • Edited

Very true, Sharkie :) it's always a phenomenal choice when exercise is involved

Collapse
 
ardraeiss profile image
Mikhail Merzlyutin • Edited

Just be careful, coffee can also increase anxiety and/or make you more "locked" on sudden ideas/emotions(HSP/high sensitive people are more vulnerable to this effect). The effect is different for each person and weather/health conditions combination.