{"id":21713,"date":"2014-04-28T16:01:08","date_gmt":"2014-04-28T14:01:08","guid":{"rendered":"https:\/\/mamchenkov.net\/wordpress\/?p=21713"},"modified":"2014-04-28T16:01:08","modified_gmt":"2014-04-28T14:01:08","slug":"john-resig-write-code-every-day","status":"publish","type":"post","link":"https:\/\/mamchenkov.net\/wordpress\/2014\/04\/28\/john-resig-write-code-every-day\/","title":{"rendered":"John Resig : Write Code Every Day"},"content":{"rendered":"<!-- google_ad_section_start -->\n<p><a href=\"http:\/\/ejohn.org\/\">John Resig<\/a>, of the Khan Academy developers and the author of jQuery JavaScript library, ran an interesting experiment on himself &#8211; <a href=\"http:\/\/ejohn.org\/blog\/write-code-every-day\/\">write code every day<\/a>. \u00a0The rules were very simple:<\/p>\n<blockquote><p>I decided to set a couple rules for myself:<\/p>\n<ol>\n<li>I must write code every day. I can write docs, or blog posts, or other things but it must be in addition to the code that I write.<\/li>\n<li>It must be useful code. No tweaking indentation, no code re-formatting, and if at all possible no refactoring. (All these things are permitted, but not as the exclusive work of the day.)<\/li>\n<li>All code must be written before midnight.<\/li>\n<li>The code must be Open Source and up on Github.<\/li>\n<\/ol>\n<p>Some of these rules were arbitrary. The code doesn\u2019t technically need to be written before midnight of the day of but I wanted to avoid staying up too late writing sloppy code. Neither does the code have to be Open Source or up on Github. This just forced me to be more mindful of the code that I was writing (thinking about reusability and deciding to create modules earlier in the process).<\/p><\/blockquote>\n<p>And he got some very interesting results, not to mention &#8211; a whole lotta work done.<\/p>\n<p>While I&#8217;m not the biggest fan of productivity boost experiments, this one does resonate with me. \u00a0I&#8217;ve done a similar one when I was learning photography. \u00a0I decided to take at least one picture every day with my camera (no mobile phones), with no automatic settings. \u00a0Some days were better, some were worse, but I manage to run it for about four month and I couldn&#8217;t believe how much better I got \u00a0&#8211; I was still a noob, but the difference between the first days and the last days was huge! \u00a0The routine, once you get into it, is a very powerful tool, apparently.<\/p>\n<p>For about a year or so now I&#8217;ve been avoiding any side projects, trying to recover from a previous burnout. \u00a0But now, slowly, I am looking into ways to get me back on tracks. \u00a0This approach looks interesting enough for me to consider.<\/p>\n<!-- google_ad_section_end -->\n","protected":false},"excerpt":{"rendered":"<!-- google_ad_section_start -->\n<p>John Resig, of the Khan Academy developers and the author of jQuery JavaScript library, ran an interesting experiment on himself &#8211; write code every day. \u00a0The rules were very simple: I decided to set a couple rules for myself: I must write code every day. I can write docs, or blog posts, or other things &hellip; <a href=\"https:\/\/mamchenkov.net\/wordpress\/2014\/04\/28\/john-resig-write-code-every-day\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">John Resig : Write Code Every Day<\/span><\/a><\/p>\n<!-- google_ad_section_end -->\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"_links_to":"","_links_to_target":""},"categories":[1,18,62],"tags":[1115,1079,17],"keyring_services":[],"class_list":["post-21713","post","type-post","status-publish","format-standard","hentry","category-general","category-programming","category-technology","tag-experiments","tag-productivity","tag-work"],"aioseo_notices":[],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack-related-posts":[{"id":8431,"url":"https:\/\/mamchenkov.net\/wordpress\/2005\/01\/06\/how-to-write-unmaintainable-code\/","url_meta":{"origin":21713,"position":0},"title":"How To Write Unmaintainable Code","author":"Leonid Mamchenkov","date":"January 6, 2005","format":false,"excerpt":"In many places Perl is called an unmaintainable language. People with brains know that you can write unmaintainable code in any programming language what-so-ever. People who are familiar with Perl know that it can be used to write the uglies code ever, or the most beautiful code ever. Aside from\u2026","rel":"","context":"In &quot;All&quot;","block_context":{"text":"All","link":"https:\/\/mamchenkov.net\/wordpress\/category\/general\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":9326,"url":"https:\/\/mamchenkov.net\/wordpress\/2005\/08\/10\/the-worst-code-ever\/","url_meta":{"origin":21713,"position":1},"title":"The worst code ever","author":"Leonid Mamchenkov","date":"August 10, 2005","format":false,"excerpt":"Today is the black day in my experiences calendar. I have seen the worst code ever. I found all that mess in our corporate intranet. It has been written by one guy who long left the company and noone looks at it nomore. Other programmers avoid it like a plague\u2026","rel":"","context":"In &quot;All&quot;","block_context":{"text":"All","link":"https:\/\/mamchenkov.net\/wordpress\/category\/general\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":22007,"url":"https:\/\/mamchenkov.net\/wordpress\/2014\/06\/18\/komanda-irc-for-people-who-write-code\/","url_meta":{"origin":21713,"position":2},"title":"komanda &#8211; IRC for people who write code","author":"Leonid Mamchenkov","date":"June 18, 2014","format":"link","excerpt":"komanda - IRC for people who write code","rel":"","context":"In &quot;All&quot;","block_context":{"text":"All","link":"https:\/\/mamchenkov.net\/wordpress\/category\/general\/"},"img":{"alt_text":"komanda-ss-2","src":"https:\/\/i0.wp.com\/mamchenkov.net\/wordpress\/wp-content\/uploads\/2014\/06\/komanda-ss-2-500x320.png?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":26333,"url":"https:\/\/mamchenkov.net\/wordpress\/2016\/08\/09\/how-do-i-write-good-code\/","url_meta":{"origin":21713,"position":3},"title":"How Do I Write Good Code?","author":"Leonid Mamchenkov","date":"August 9, 2016","format":false,"excerpt":"Eric Dietrich, over at DaedTech, explains how he writes good code. \u00a0It's a post worth a read in full, but here is a summary: Make it easy to change Make it really readable Make it work Make it elegant Learn from accomplished practitioners He is also listing a few books\u2026","rel":"","context":"In &quot;All&quot;","block_context":{"text":"All","link":"https:\/\/mamchenkov.net\/wordpress\/category\/general\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":19138,"url":"https:\/\/mamchenkov.net\/wordpress\/2014\/01\/08\/how-to-write-code\/","url_meta":{"origin":21713,"position":4},"title":"How to write code","author":"Leonid Mamchenkov","date":"January 8, 2014","format":"image","excerpt":"","rel":"","context":"In &quot;All&quot;","block_context":{"text":"All","link":"https:\/\/mamchenkov.net\/wordpress\/category\/general\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/mamchenkov.net\/wordpress\/wp-content\/uploads\/2014\/01\/fast-or-proper.png?fit=455%2C695&ssl=1&resize=350%2C200","width":350,"height":200},"classes":[]},{"id":22296,"url":"https:\/\/mamchenkov.net\/wordpress\/2014\/07\/29\/the-goal-challenge\/","url_meta":{"origin":21713,"position":5},"title":"The goal() challenge","author":"Leonid Mamchenkov","date":"July 29, 2014","format":false,"excerpt":"I came across the goal() challenge this morning. g()('al') is a challenge whereby you need to write in as many languages as possible code which enables the code g()('al') to return the string \"goal\", the code g()()('al') to return the string \"gooal\", the code g()()()('al') return the string \"goooal\", etc.\u2026","rel":"","context":"In &quot;All&quot;","block_context":{"text":"All","link":"https:\/\/mamchenkov.net\/wordpress\/category\/general\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]}],"jetpack_sharing_enabled":true,"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/posts\/21713","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/comments?post=21713"}],"version-history":[{"count":0,"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/posts\/21713\/revisions"}],"wp:attachment":[{"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/media?parent=21713"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/categories?post=21713"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/tags?post=21713"},{"taxonomy":"keyring_services","embeddable":true,"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/keyring_services?post=21713"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}