<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title>Michi Kono - Latest Comments</title><link>http://michiknows.disqus.com/</link><description></description><atom:link href="https://michiknows.disqus.com/comments.rss" rel="self"></atom:link><language>en</language><lastBuildDate>Sat, 22 Feb 2014 15:03:10 -0000</lastBuildDate><item><title>Re: Adding a Centralized Event Dispatcher on Backbone.js</title><link>http://www.michikono.com/2012/01/11/adding-a-centralized-event-dispatcher-on-backbone-js/#comment-1256484782</link><description>&lt;p&gt;Sorry, pls delete this post. The leak was elsewhere.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Robert</dc:creator><pubDate>Sat, 22 Feb 2014 15:03:10 -0000</pubDate></item><item><title>Re: Adding a Centralized Event Dispatcher on Backbone.js</title><link>http://www.michikono.com/2012/01/11/adding-a-centralized-event-dispatcher-on-backbone-js/#comment-1256403848</link><description>&lt;p&gt;There is a memory leak in this script. When I used it as event dispatcher in a phonegap iOS project, the heap allocations slowly grew because of it. So beware to use it, as it could crash your app. Currently using the "vent" solution of Derick Bailey which doesn't increase the heap.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Robert</dc:creator><pubDate>Sat, 22 Feb 2014 13:41:56 -0000</pubDate></item><item><title>Re: Adding a Centralized Event Dispatcher on Backbone.js</title><link>http://www.michikono.com/2012/01/11/adding-a-centralized-event-dispatcher-on-backbone-js/#comment-833200105</link><description>&lt;p&gt;Seriously dude crawl out of your hole and actually try it.  CoffeeScript is really great and it is completely manageable and results in less code and less bugs.  And yes advanced js syntax is bad and combined with the flexibility that the language provides it results in more bugs when there is a lot of people working on the same code base.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Frank</dc:creator><pubDate>Mon, 18 Mar 2013 00:53:22 -0000</pubDate></item><item><title>Re: Adding a Centralized Event Dispatcher on Backbone.js</title><link>http://www.michikono.com/2012/01/11/adding-a-centralized-event-dispatcher-on-backbone-js/#comment-750043601</link><description>&lt;p&gt;Interesting idea, but it seems terrible in practice.  The core problem you start out with (two views need to communicate) can be solved so many ways in Backbone (the most obvious being A) sharing a model between the views, B) passing a reference from one view to the other).  They may not magically work out of the box, but they're WAY better than throwing all of your events in to one giant global space.&lt;/p&gt;&lt;p&gt;If using Backbone (and frameworks like it) has taught us anything it's that encapsulation is essential to managing serious web apps.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Jeremy</dc:creator><pubDate>Fri, 28 Dec 2012 19:28:28 -0000</pubDate></item><item><title>Re: Adding a Centralized Event Dispatcher on Backbone.js</title><link>http://www.michikono.com/2012/01/11/adding-a-centralized-event-dispatcher-on-backbone-js/#comment-682785081</link><description>&lt;p&gt;Keep in mind people are "littering" their own code bases. I've found coffeescript to be less verbose for the same functionality, which means less lines of code to maintain. Also, keep in mind because it compiles, it means one CAN leave it if later it turns out to be a bad idea. Lastly, while it does remove the "feature" to debug, it also ADDS a LOT of features. The list is long and you'd have to read their documentation to see what they are, but some worth mentioning are: automatically protecting the global scope, standardized support for more formal OOP concepts, and string interpolation. I think code readability is a very important, if not the most important, "feature" since you spend 10% of a code's lifetime writing it and 90% of its time reading it.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Michi Kono</dc:creator><pubDate>Mon, 15 Oct 2012 11:01:07 -0000</pubDate></item><item><title>Re: Adding a Centralized Event Dispatcher on Backbone.js</title><link>http://www.michikono.com/2012/01/11/adding-a-centralized-event-dispatcher-on-backbone-js/#comment-682354536</link><description>&lt;p&gt;This would probably be a great solution were it not for the fucking CoffeeScript.  Is JS syntax really so bad that we have to add another layer of abstraction on top that actually removes functionality? I.e. you can't debug CoffeeScript.  And I'm not going to get in an argument about how you can still debug the resultant JS.  It's just not the same.  The code that CoffeeScript spits out just isn't as clear and understandable as hand written JS, simply because YOU DIDN'T WRITE IT, and a human didn't write it.  I'd understand if JS were some sort of bytecode, but jesus people, JS is C-style syntax, which is very readable and meant for human consumption.  You are littering the JS landscape with this pseudo-compiled BS.  If you want ruby then go work with ruby.  Get off my lawn, bah humbug and all that.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Enunna</dc:creator><pubDate>Sun, 14 Oct 2012 23:51:52 -0000</pubDate></item><item><title>Re: The Destruction of the Head Hunting Industry</title><link>http://www.michikono.com/2010/04/04/the-destruction-of-the-head-hunting-industry/#comment-521584918</link><description>&lt;p&gt;Recruiters have simply argued that sourcing is not the key to their jobs. It's selling. Would you like to defend your idea on The Recruiting Animal Show? You can read about it here &lt;a href="http://OccupyRecruiting.com" rel="nofollow noopener" target="_blank" title="http://OccupyRecruiting.com"&gt;http://OccupyRecruiting.com&lt;/a&gt; &lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">RecruitingANIMAL</dc:creator><pubDate>Mon, 07 May 2012 09:49:21 -0000</pubDate></item><item><title>Re: About Me</title><link>http://www.michikono.com/about/#comment-517993941</link><description>&lt;p&gt;Thanks for the heads up, Dave! Good hearing from you. :)&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Michi Kono</dc:creator><pubDate>Thu, 03 May 2012 16:33:55 -0000</pubDate></item><item><title>Re: About Me</title><link>http://www.michikono.com/about/#comment-517880627</link><description>&lt;p&gt;Hey Michi!&lt;/p&gt;&lt;p&gt;This is David, from Hydra. Just noticed you were quoted in an article: &lt;a href="http://www.businessinsider.com/former-headhunter-linkedin-replaced-the-recruiting-industry-2012-5" rel="nofollow noopener" target="_blank" title="http://www.businessinsider.com/former-headhunter-linkedin-replaced-the-recruiting-industry-2012-5"&gt;http://www.businessinsider....&lt;/a&gt;&lt;/p&gt;&lt;p&gt;Hope things are well for you man,&lt;/p&gt;&lt;p&gt;Cheers!&lt;br&gt;~David C&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">dave c</dc:creator><pubDate>Thu, 03 May 2012 14:02:11 -0000</pubDate></item><item><title>Re: About Me</title><link>http://www.michikono.com/about/#comment-483623441</link><description>&lt;p&gt;Good luck to you Michi!!&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Bilal Ben Clarance</dc:creator><pubDate>Mon, 02 Apr 2012 11:47:55 -0000</pubDate></item><item><title>Re: Facebook is okay with hurting their developers</title><link>http://www.michikono.com/2012/03/22/facebook-is-okay-with-hurting-their-developers/#comment-475705726</link><description>&lt;p&gt;I assume this is why it's dangerous to have a business model that fully depends on an ecosystem controlled by a single entity.  They can decide to change course for whatever reason, and you can get wiped out. &lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Gigio</dc:creator><pubDate>Sun, 25 Mar 2012 03:41:19 -0000</pubDate></item><item><title>Re: Adding a Centralized Event Dispatcher on Backbone.js</title><link>http://www.michikono.com/2012/01/11/adding-a-centralized-event-dispatcher-on-backbone-js/#comment-454013152</link><description>&lt;p&gt;After some tinkering and getting more familiar, I think your approach makes more sense than mine when it comes to dealing with adding more event dispatchers. Ultimately, I think these solutions (mine included) should be avoided where possible. Once you start writing to global dispatchers, the allure is strong to just dump everything there rather than doing it "right" and encapsulating the view logic properly (just a warning for visitors who might later read this!).&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Michi Kono</dc:creator><pubDate>Thu, 01 Mar 2012 20:43:00 -0000</pubDate></item><item><title>Re: Adding a Centralized Event Dispatcher on Backbone.js</title><link>http://www.michikono.com/2012/01/11/adding-a-centralized-event-dispatcher-on-backbone-js/#comment-417963819</link><description>&lt;p&gt;Augmenting the backbone objects with your dispatcher is a bad idea, IMO. You're right in that the dependency injection that I showed in my original articles is stupid. I don't do that anymore, either. It creates a huge mess.&lt;/p&gt;&lt;p&gt;I think augmenting the Backbone constructs like you're showing goes against your stated goal in the comment to redsquare, about future proofing against backbone changes. Augmenting an object you don't own is always dangerous, no matter the language. Ruby, JavaScript and other dynamic languages state "best practices" as not doing this.&lt;/p&gt;&lt;p&gt;My solution is to keep it simple and just attach my "vent" object to the application namespace: "MyApp.vent = _.extend({}, Backbone.Events)" done. All of my app objects just call out to this ... and you are using a single namespace object for your app, right?&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Derick Bailey</dc:creator><pubDate>Sun, 22 Jan 2012 05:48:30 -0000</pubDate></item><item><title>Re: Adding a Centralized Event Dispatcher on Backbone.js</title><link>http://www.michikono.com/2012/01/11/adding-a-centralized-event-dispatcher-on-backbone-js/#comment-417962886</link><description>&lt;p&gt;The idea about event registration with "channels" is overcomplicating things, IMO. It would take some code to implement this and may turn into a performance problem - especially if you're trying to parse ":" in event names to determine the right channel. &lt;/p&gt;&lt;p&gt;If you're publishing so many different events and have so many different event handlers registered at one time, that it becomes a bottleneck in itself to publish a single event, just create a second or third event aggregator as your channels: &lt;/p&gt;&lt;p&gt;MyApp.imageEvents = _.extend({}, Backbone.Events); &lt;br&gt;MyApp.userEvents = _.extend({}, Backbone.Events); &lt;br&gt;MyApp.someOtherEvents = _.extend({}, Backbone.Events}); &lt;/p&gt;&lt;p&gt;and on like that. There's instant channels with no performance hit or additional code required.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Derick Bailey</dc:creator><pubDate>Sun, 22 Jan 2012 05:44:20 -0000</pubDate></item><item><title>Re: Adding a Centralized Event Dispatcher on Backbone.js</title><link>http://www.michikono.com/2012/01/11/adding-a-centralized-event-dispatcher-on-backbone-js/#comment-415727713</link><description>&lt;p&gt;I'm hitting this exact issue now after implementing this solution where I'm seeing "spaghetti" events. One benefit of creating a global dispatcher is that you are not limited to the way that backbone handles events natively. Of course, my goal was to leave the solution as open as possible to future proof it against backbone's inevitable coming enhancements. It is entirely possible for you to create your own construct that extends Event (which is then access via global_dispatcher). I haven't figured out what would be best here, but one idea I've thought about is having an event namespace registration process in the initializer that all global events would need to match. In other words, something like:&lt;br&gt;// inside the initializer&lt;br&gt;this.global_dispatcher.register_namespace('panel')&lt;/p&gt;&lt;p&gt;// listener&lt;br&gt;this.global_dispatcher.bind_one('panel', 'special_button:click', my_function)&lt;br&gt;// normally might look like: this.global_dispatcher.bind('panel:special_button:click')&lt;br&gt;this.global_dispatcher.bind_all('panel', my_function) // listen to all events from this namespace&lt;/p&gt;&lt;p&gt;// later&lt;br&gt;this.global_dispatcher.trigger_namespace('panel', 'special_button:click')&lt;/p&gt;&lt;p&gt;An alternate implementation could recognize such namespaces using the current ":" convention (parse out the first block).&lt;/p&gt;&lt;p&gt;I'll definitely post an update if I end up doing something like this. For now, I'm dealing with the event spaghetti by using conventions. I'm fairly new to writing a complex event driven application so I may be overlooking a best-practice for organizing such an app.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Michi Kono</dc:creator><pubDate>Thu, 19 Jan 2012 18:44:17 -0000</pubDate></item><item><title>Re: Adding a Centralized Event Dispatcher on Backbone.js</title><link>http://www.michikono.com/2012/01/11/adding-a-centralized-event-dispatcher-on-backbone-js/#comment-415691531</link><description>&lt;p&gt;Damn phone. Apologies for the typos above&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">redsquare</dc:creator><pubDate>Thu, 19 Jan 2012 17:58:31 -0000</pubDate></item><item><title>Re: Adding a Centralized Event Dispatcher on Backbone.js</title><link>http://www.michikono.com/2012/01/11/adding-a-centralized-event-dispatcher-on-backbone-js/#comment-415690600</link><description>&lt;p&gt;Nice, is there no better way to make the events that get triggered discoverable. Having them as hardcodef strings makes it a pita to see what is exposed. Could you not use an events object literal at the top of the class ti shiw others what events can be subscribed to rather than having to pick out a hard to find strung?&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">redsquare</dc:creator><pubDate>Thu, 19 Jan 2012 17:57:27 -0000</pubDate></item><item><title>Re: What Agile is NOT</title><link>http://www.michikono.com/2012/01/11/what-agile-is-not/#comment-408242886</link><description>&lt;p&gt;Great article.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Jackson</dc:creator><pubDate>Wed, 11 Jan 2012 19:17:02 -0000</pubDate></item><item><title>Re: What Agile is NOT</title><link>http://www.michikono.com/2012/01/11/what-agile-is-not/#comment-408044158</link><description>&lt;p&gt;Great (and succinct) summary of Agile.  I especially like the perspective on scaling.  Right on!&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Tom Looy</dc:creator><pubDate>Wed, 11 Jan 2012 14:42:59 -0000</pubDate></item><item><title>Re: What Agile is NOT</title><link>http://www.michikono.com/2012/01/11/what-agile-is-not/#comment-407990589</link><description>&lt;p&gt;Hell yes! Agile != random/panic acts of coding. You should write an anti-agile manifesto with the points you're making.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Ben Love</dc:creator><pubDate>Wed, 11 Jan 2012 13:28:59 -0000</pubDate></item><item><title>Re: Ruby: Time Comparisons Seem Backwards Due to Asian Culture</title><link>http://www.michikono.com/2011/09/24/ruby-time-comparisons-seem-backwards-due-to-asian-culture/#comment-339542802</link><description>&lt;p&gt;alternatively, &amp;lt;=&amp;gt; is shorthand for compareTo, which in many programming languages returns 1 if first arg is greater, 0 if they're equal, and -1 if first arg is less.&lt;/p&gt;&lt;p&gt;example: comparison_result = today_time.compareTo(yesterday_time) =&amp;gt; comparison_result = 1&lt;br&gt;hi michi :-P&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Charles Lee</dc:creator><pubDate>Wed, 19 Oct 2011 20:21:44 -0000</pubDate></item><item><title>Re: Make Text Come Out Backwards!</title><link>http://www.michikono.com/2007/01/31/make-text-come-out-backwards/#comment-336243293</link><description>&lt;p&gt; ‮RAWR&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">DelaneyH</dc:creator><pubDate>Sun, 16 Oct 2011 18:36:05 -0000</pubDate></item><item><title>Re: Make Text Come Out Backwards!</title><link>http://www.michikono.com/2007/01/31/make-text-come-out-backwards/#comment-331817847</link><description>&lt;p&gt;Difficulty in learning to read, write, or spell, despite, regular instruction, adequate intelligence, and sociocultural opportunity.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Sirattac</dc:creator><pubDate>Tue, 11 Oct 2011 13:20:56 -0000</pubDate></item><item><title>Re: Who Else Wants to Hide Their WordPress Folder?</title><link>http://www.michikono.com/2007/02/12/who-else-wants-to-hide-their-wordpress-admin-folder/#comment-331556928</link><description>&lt;p&gt;Had the same problem. Try this (thanks to Lazeg):&lt;/p&gt;&lt;p&gt;    RewriteEngine On&lt;br&gt;    RewriteBase /&lt;br&gt;    # wp-admin aanpassen&lt;br&gt;    RewriteCond %{REQUEST_URI} wp-admin/&lt;br&gt;    RewriteCond %{REQUEST_FILENAME} !load-styles.php&lt;br&gt;    RewriteCond %{QUERY_STRING} !YOURSECRETWORD&lt;br&gt;    RewriteRule .*\.php [F,L]&lt;br&gt;    RewriteCond %{QUERY_STRING} !YOURSECRETWORD&lt;br&gt;    RewriteRule ^YOURSECRETROOM/(.*) wp-admin/$1?%{QUERY_STRING}&amp;amp;YOURSECRETWORD [L]&lt;br&gt;    # wp-admin aanpassen&lt;br&gt;    RewriteRule ^index\.php$ - [L]&lt;br&gt;    RewriteCond %{REQUEST_FILENAME} !-f&lt;br&gt;    RewriteCond %{REQUEST_FILENAME} !-d&lt;br&gt;    RewriteRule . /index.php [L]&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Freshcode</dc:creator><pubDate>Tue, 11 Oct 2011 06:34:15 -0000</pubDate></item><item><title>Re: Make Text Come Out Backwards!</title><link>http://www.michikono.com/2007/01/31/make-text-come-out-backwards/#comment-329355597</link><description>&lt;p&gt;‮ Haha , you fail , you put the period in the beginning  . Your suppose to put it at the end , stupid!&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Sasuke510</dc:creator><pubDate>Fri, 07 Oct 2011 23:02:45 -0000</pubDate></item></channel></rss>