<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments for Infrequently Noted</title>
	<atom:link href="http://infrequently.org/comments/feed/" rel="self" type="application/rss+xml" />
	<link>http://infrequently.org</link>
	<description></description>
	<lastBuildDate>Thu, 10 May 2012 17:22:05 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
	<item>
		<title>Comment on Hoisted From The Comments by James Hatfield</title>
		<link>http://infrequently.org/2012/04/hoisted-from-the-comments/comment-page-1/#comment-239884</link>
		<dc:creator>James Hatfield</dc:creator>
		<pubDate>Thu, 10 May 2012 17:22:05 +0000</pubDate>
		<guid isPermaLink="false">http://infrequently.org/?p=1844#comment-239884</guid>
		<description>BTW companies like Strangeloop and Blaze.io make a business out of doing targeted optimizations for markup, CSS and JavaScript using a proxy/cache system that optimizes from the origin and then pushes out to the edge.</description>
		<content:encoded><![CDATA[<p>BTW companies like Strangeloop and Blaze.io make a business out of doing targeted optimizations for markup, CSS and JavaScript using a proxy/cache system that optimizes from the origin and then pushes out to the edge.</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Hoisted From The Comments by James Hatfield</title>
		<link>http://infrequently.org/2012/04/hoisted-from-the-comments/comment-page-1/#comment-239883</link>
		<dc:creator>James Hatfield</dc:creator>
		<pubDate>Thu, 10 May 2012 17:17:11 +0000</pubDate>
		<guid isPermaLink="false">http://infrequently.org/?p=1844#comment-239883</guid>
		<description>I&#039;d like to add a follow up to my comment quoted. 

Something my team has to deal with on a daily basis is multi-language, multi-region contexts for presentation, data and business logic. We also run a/b/m-v tests continuously and beta test site re-designs and new features regularly on multiple sites. 

This may not be a typical scenario but I&#039;m sure there are others who share our pain points. 

MDV looks good but how long do we wait? 

In the meanwhile we are looking to implement server and client templating using the same model (JSON) and the same markup (Mustache spec) but thinking seriously about whether the server side app is needed at all (outside of SERP considerations).</description>
		<content:encoded><![CDATA[<p>I&#8217;d like to add a follow up to my comment quoted. </p>
<p>Something my team has to deal with on a daily basis is multi-language, multi-region contexts for presentation, data and business logic. We also run a/b/m-v tests continuously and beta test site re-designs and new features regularly on multiple sites. </p>
<p>This may not be a typical scenario but I&#8217;m sure there are others who share our pain points. </p>
<p>MDV looks good but how long do we wait? </p>
<p>In the meanwhile we are looking to implement server and client templating using the same model (JSON) and the same markup (Mustache spec) but thinking seriously about whether the server side app is needed at all (outside of SERP considerations).</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Class Warfare by In Defense of JavaScript Constructor Functions (Classes) &#124; dBlogIt by Dustin Boston</title>
		<link>http://infrequently.org/2012/04/class-warfare/comment-page-1/#comment-239860</link>
		<dc:creator>In Defense of JavaScript Constructor Functions (Classes) &#124; dBlogIt by Dustin Boston</dc:creator>
		<pubDate>Sun, 06 May 2012 22:56:45 +0000</pubDate>
		<guid isPermaLink="false">http://infrequently.org/?p=1845#comment-239860</guid>
		<description>[...] 6, 2012 by Dustin Boston    So there&#8217;s lots of debate about the merits of pure JavaScript objects (using Prototypal Inheritance) vs constructor functions [...]</description>
		<content:encoded><![CDATA[<p>[...] 6, 2012 by Dustin Boston    So there&#8217;s lots of debate about the merits of pure JavaScript objects (using Prototypal Inheritance) vs constructor functions [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Class Warfare by Mark</title>
		<link>http://infrequently.org/2012/04/class-warfare/comment-page-1/#comment-239818</link>
		<dc:creator>Mark</dc:creator>
		<pubDate>Fri, 27 Apr 2012 14:52:17 +0000</pubDate>
		<guid isPermaLink="false">http://infrequently.org/?p=1845#comment-239818</guid>
		<description>I don&#039;t get why adding classes to the spec is even up for discussion. Call me a JS purist, but I came from a classical background, OOP to the core. Switching to the prototypical paradigm was like putting mayonnaise on my peanut butter &amp; jelly. It tasted bad; I hated taking bites and I just wanted nothing to do with it.

I realized, maybe if I have to deal with mayonnaise, why not just try making an equally tasty sandwich with the new ingredient?

&quot;Don’t add classes and the world at large thinks of JS as a joke and a toy&quot; -- so because we have a &quot;new generation&quot; of classically-trained programmers who are using Javascript we need to add a &quot;class&quot; keyword so they don&#039;t feel so weird about prototyping? I&#039;m one of those programmers. I got over it, so can they.

The ECMAScript 5 spec addressed A LOT of the issues I have personally with prototyping. I cannot wait until its adopted across the board.

I think creations like Coffeescript (and dare I even say Dart) have put the web app development world in a frenzy over shimming every classical OOP pattern into Javascript (or in the case of Dart, dropping JS altogether). I think this post highlights a critical fork in the road.</description>
		<content:encoded><![CDATA[<p>I don&#8217;t get why adding classes to the spec is even up for discussion. Call me a JS purist, but I came from a classical background, OOP to the core. Switching to the prototypical paradigm was like putting mayonnaise on my peanut butter &amp; jelly. It tasted bad; I hated taking bites and I just wanted nothing to do with it.</p>
<p>I realized, maybe if I have to deal with mayonnaise, why not just try making an equally tasty sandwich with the new ingredient?</p>
<p>&#8220;Don’t add classes and the world at large thinks of JS as a joke and a toy&#8221; &#8212; so because we have a &#8220;new generation&#8221; of classically-trained programmers who are using Javascript we need to add a &#8220;class&#8221; keyword so they don&#8217;t feel so weird about prototyping? I&#8217;m one of those programmers. I got over it, so can they.</p>
<p>The ECMAScript 5 spec addressed A LOT of the issues I have personally with prototyping. I cannot wait until its adopted across the board.</p>
<p>I think creations like Coffeescript (and dare I even say Dart) have put the web app development world in a frenzy over shimming every classical OOP pattern into Javascript (or in the case of Dart, dropping JS altogether). I think this post highlights a critical fork in the road.</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Class Warfare by alex</title>
		<link>http://infrequently.org/2012/04/class-warfare/comment-page-1/#comment-239807</link>
		<dc:creator>alex</dc:creator>
		<pubDate>Wed, 25 Apr 2012 22:12:24 +0000</pubDate>
		<guid isPermaLink="false">http://infrequently.org/?p=1845#comment-239807</guid>
		<description>Marco:

On browser population, trust me; I feel your pain. It&#039;s the reason I&#039;ve spent years of my life trying to provide us all with a workaround in the form of Chrome Frame. I get that none of this stuff really matters until we can fix the decay rate of Old IE, and I&#039;m still working to make that better. But we can&#039;t just do nothing while we wait for the cavalry to arrive, else we&#039;ll be empty handed when it *does* get better and have nothing to show for our hard-won victory.</description>
		<content:encoded><![CDATA[<p>Marco:</p>
<p>On browser population, trust me; I feel your pain. It&#8217;s the reason I&#8217;ve spent years of my life trying to provide us all with a workaround in the form of Chrome Frame. I get that none of this stuff really matters until we can fix the decay rate of Old IE, and I&#8217;m still working to make that better. But we can&#8217;t just do nothing while we wait for the cavalry to arrive, else we&#8217;ll be empty handed when it *does* get better and have nothing to show for our hard-won victory.</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Class Warfare by Marco Rogers</title>
		<link>http://infrequently.org/2012/04/class-warfare/comment-page-1/#comment-239797</link>
		<dc:creator>Marco Rogers</dc:creator>
		<pubDate>Tue, 24 Apr 2012 18:46:27 +0000</pubDate>
		<guid isPermaLink="false">http://infrequently.org/?p=1845#comment-239797</guid>
		<description>Alex:

I don&#039;t doubt what you&#039;re saying. I just doubt that adding a &quot;recommended&quot; version of classes is going to solve it. These various class libs all do things differently because that&#039;s how their authors want to solve the problem. And through conflict and fear of backwards incompatibility, we&#039;ve ensured that class syntax can be ignored, extended or co-opted for the same nefarious purposes. I think there will be some adoption of the class syntax and some reduction of ad-hoc solutions. But as long as it doesn&#039;t do what some people expect, javascript is still flexible enough for people to do their own thing.

All that being said. This may still be good enough. More important than anything is making it possible for devs to adopt the new syntax sooner rather than later. That story is getting better for browser apis, but not so much for js upgrades. New js syntax is still just not feasible for the wide majority of browser devs. This may seem like a lame argument, but it has consequences in trying to gain support for this stuff. What it means is that the support you might otherwise get isn&#039;t there because most practical devs just don&#039;t care. Because they know it won&#039;t make a difference for them for a while yet.</description>
		<content:encoded><![CDATA[<p>Alex:</p>
<p>I don&#8217;t doubt what you&#8217;re saying. I just doubt that adding a &#8220;recommended&#8221; version of classes is going to solve it. These various class libs all do things differently because that&#8217;s how their authors want to solve the problem. And through conflict and fear of backwards incompatibility, we&#8217;ve ensured that class syntax can be ignored, extended or co-opted for the same nefarious purposes. I think there will be some adoption of the class syntax and some reduction of ad-hoc solutions. But as long as it doesn&#8217;t do what some people expect, javascript is still flexible enough for people to do their own thing.</p>
<p>All that being said. This may still be good enough. More important than anything is making it possible for devs to adopt the new syntax sooner rather than later. That story is getting better for browser apis, but not so much for js upgrades. New js syntax is still just not feasible for the wide majority of browser devs. This may seem like a lame argument, but it has consequences in trying to gain support for this stuff. What it means is that the support you might otherwise get isn&#8217;t there because most practical devs just don&#8217;t care. Because they know it won&#8217;t make a difference for them for a while yet.</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Class Warfare by Charlie Hubbard</title>
		<link>http://infrequently.org/2012/04/class-warfare/comment-page-1/#comment-239796</link>
		<dc:creator>Charlie Hubbard</dc:creator>
		<pubDate>Tue, 24 Apr 2012 18:07:41 +0000</pubDate>
		<guid isPermaLink="false">http://infrequently.org/?p=1845#comment-239796</guid>
		<description>After reading the proposal I still think this might not be enough to really make a difference.  The biggest pain in the butt part of OO in javascript is loosing the this pointer when using function references.  So we have to proxy the methods every time we want to hand out a reference and maintain the this pointer.  I think without fixing that adding classes won&#039;t have as much impact to improved productivity because the competition, coffeescript and Dart, offers this already.  If you look at the feature list on coffeescript its disheartening the state of javascript.  This is happening one way or another the debate is will it be in javascript or other languages that transpile to javascript.  If TC39 kicks the can down the road for another 5 years they&#039;ll have to contend with the rising languages that will be working from a stronger position.</description>
		<content:encoded><![CDATA[<p>After reading the proposal I still think this might not be enough to really make a difference.  The biggest pain in the butt part of OO in javascript is loosing the this pointer when using function references.  So we have to proxy the methods every time we want to hand out a reference and maintain the this pointer.  I think without fixing that adding classes won&#8217;t have as much impact to improved productivity because the competition, coffeescript and Dart, offers this already.  If you look at the feature list on coffeescript its disheartening the state of javascript.  This is happening one way or another the debate is will it be in javascript or other languages that transpile to javascript.  If TC39 kicks the can down the road for another 5 years they&#8217;ll have to contend with the rising languages that will be working from a stronger position.</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Hoisted From The Comments by Four short links: 20 April 2012 &#124; Share Blog</title>
		<link>http://infrequently.org/2012/04/hoisted-from-the-comments/comment-page-1/#comment-239795</link>
		<dc:creator>Four short links: 20 April 2012 &#124; Share Blog</dc:creator>
		<pubDate>Tue, 24 Apr 2012 17:25:49 +0000</pubDate>
		<guid isPermaLink="false">http://infrequently.org/?p=1844#comment-239795</guid>
		<description>[...] Javascript All The Way Down (Alex Russell) &#8212; points out that we&#8217;re fixing so much like compatibility, performance, accessibility, all this stuff with Javascript. We&#8217;re moving further and further from declarative programming and more and more back to the days of writing heaps of Xlib or Motif toolkit code to implement our UIs and apps. [...]</description>
		<content:encoded><![CDATA[<p>[...] Javascript All The Way Down (Alex Russell) &#8212; points out that we&#8217;re fixing so much like compatibility, performance, accessibility, all this stuff with Javascript. We&#8217;re moving further and further from declarative programming and more and more back to the days of writing heaps of Xlib or Motif toolkit code to implement our UIs and apps. [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Class Warfare by Shannon</title>
		<link>http://infrequently.org/2012/04/class-warfare/comment-page-1/#comment-239794</link>
		<dc:creator>Shannon</dc:creator>
		<pubDate>Tue, 24 Apr 2012 15:19:19 +0000</pubDate>
		<guid isPermaLink="false">http://infrequently.org/?p=1845#comment-239794</guid>
		<description>Alex, yes it does! Thanks for your patience!</description>
		<content:encoded><![CDATA[<p>Alex, yes it does! Thanks for your patience!</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Class Warfare by Eugene Lazutkin</title>
		<link>http://infrequently.org/2012/04/class-warfare/comment-page-1/#comment-239790</link>
		<dc:creator>Eugene Lazutkin</dc:creator>
		<pubDate>Tue, 24 Apr 2012 13:14:47 +0000</pubDate>
		<guid isPermaLink="false">http://infrequently.org/?p=1845#comment-239790</guid>
		<description>I like the proposal, but one thing strikes me as strange --- explicit super calls in constructors. While it is flexible, it is extremely error prone, refactor-unfriendly, and violates an object invariant potentially. Realistically how many cases, when you want to skip super&#039;s constructors vs. cases when you don&#039;t? Obviously if it is the best we can have, it is better than nothing</description>
		<content:encoded><![CDATA[<p>I like the proposal, but one thing strikes me as strange &#8212; explicit super calls in constructors. While it is flexible, it is extremely error prone, refactor-unfriendly, and violates an object invariant potentially. Realistically how many cases, when you want to skip super&#8217;s constructors vs. cases when you don&#8217;t? Obviously if it is the best we can have, it is better than nothing</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Class Warfare by alex</title>
		<link>http://infrequently.org/2012/04/class-warfare/comment-page-1/#comment-239789</link>
		<dc:creator>alex</dc:creator>
		<pubDate>Tue, 24 Apr 2012 09:58:49 +0000</pubDate>
		<guid isPermaLink="false">http://infrequently.org/?p=1845#comment-239789</guid>
		<description>Shannon:

Your example still doesn&#039;t work. The &lt;code&gt;Color&lt;/code&gt; function object (aka &quot;class&quot;) delegates to something &lt;em&gt;other&lt;/em&gt; than &lt;code&gt;Color.prototype&lt;/code&gt;. In this case, that something is &lt;code&gt;Function.prototype&lt;/code&gt;. That means that you can&#039;t de-reference &lt;code&gt;Color.WHITE&lt;/code&gt; unless you add it to the function object directly (as you did above) as a &quot;static&quot;. That&#039;s allowed.

What adding things to &lt;code&gt;Color.prototype.*&lt;/code&gt; does is make them available as things you can de-reference on &lt;em&gt;instances&lt;/em&gt; of &lt;code&gt;Color&lt;/code&gt;. Here&#039;s a quick example showing what works:

&lt;pre lang=&quot;javascript&quot;&gt;
class Color { constructor() { ... } }
// Class-level data (aka, &quot;statics&quot;)
Color.WHITE = 0xffffff;
Color.blend = function(c1, c2, alpha) { ... };

// Prototypal method
Color.prototype.blend = function(other, alpha) {
  return Color.blend(this, other, alpha);
};

// Now, usage:
let c1 = new Color(...);
let c2 = new Color(...);
let b1 = Color.blend(c1, Color.WHITE, 0.5);
let b2 = c2.blendWith(c1, 0.5);
&lt;/pre&gt;

Does that clear it up?</description>
		<content:encoded><![CDATA[<p>Shannon:</p>
<p>Your example still doesn&#8217;t work. The <code>Color</code> function object (aka &#8220;class&#8221;) delegates to something <em>other</em> than <code>Color.prototype</code>. In this case, that something is <code>Function.prototype</code>. That means that you can&#8217;t de-reference <code>Color.WHITE</code> unless you add it to the function object directly (as you did above) as a &#8220;static&#8221;. That&#8217;s allowed.</p>
<p>What adding things to <code>Color.prototype.*</code> does is make them available as things you can de-reference on <em>instances</em> of <code>Color</code>. Here&#8217;s a quick example showing what works:</p>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #003366; font-weight: bold;">class</span> Color <span style="color: #009900;">&#123;</span> constructor<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> ... <span style="color: #009900;">&#125;</span> <span style="color: #009900;">&#125;</span>
<span style="color: #006600; font-style: italic;">// Class-level data (aka, &quot;statics&quot;)</span>
Color.<span style="color: #660066;">WHITE</span> <span style="color: #339933;">=</span> 0xffffff<span style="color: #339933;">;</span>
Color.<span style="color: #660066;">blend</span> <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span>c1<span style="color: #339933;">,</span> c2<span style="color: #339933;">,</span> alpha<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> ... <span style="color: #009900;">&#125;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #006600; font-style: italic;">// Prototypal method</span>
Color.<span style="color: #660066;">prototype</span>.<span style="color: #660066;">blend</span> <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span>other<span style="color: #339933;">,</span> alpha<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
  <span style="color: #000066; font-weight: bold;">return</span> Color.<span style="color: #660066;">blend</span><span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">this</span><span style="color: #339933;">,</span> other<span style="color: #339933;">,</span> alpha<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #006600; font-style: italic;">// Now, usage:</span>
let c1 <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">new</span> Color<span style="color: #009900;">&#40;</span>...<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
let c2 <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">new</span> Color<span style="color: #009900;">&#40;</span>...<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
let b1 <span style="color: #339933;">=</span> Color.<span style="color: #660066;">blend</span><span style="color: #009900;">&#40;</span>c1<span style="color: #339933;">,</span> Color.<span style="color: #660066;">WHITE</span><span style="color: #339933;">,</span> <span style="color: #CC0000;">0.5</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
let b2 <span style="color: #339933;">=</span> c2.<span style="color: #660066;">blendWith</span><span style="color: #009900;">&#40;</span>c1<span style="color: #339933;">,</span> <span style="color: #CC0000;">0.5</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<p>Does that clear it up?</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Class Warfare by alex</title>
		<link>http://infrequently.org/2012/04/class-warfare/comment-page-1/#comment-239788</link>
		<dc:creator>alex</dc:creator>
		<pubDate>Tue, 24 Apr 2012 09:21:07 +0000</pubDate>
		<guid isPermaLink="false">http://infrequently.org/?p=1845#comment-239788</guid>
		<description>Hey Marco:

I&#039;d be on-side with you if we didn&#039;t have *enormous* piles of evidence to suggest that people are already staring down the complexity you&#039;re accusing us of adding, but doing it in an ad-hoc, non-interoperable way. Nearly every JS library includes some form of class system (yes, even jQuery via jQuery UI). If we weren&#039;t simply codifying something you demonstrably need, I think your critique would be more relevant; but as it stands, we&#039;re overdue for this. The complexity exists, people are already struggling with it, and there&#039;s an opportunity for the language to do something reasonable to help settle the various style/pattern/library wars around classes.

I have some sympathy for the idea that we should use a name other than &quot;class&quot;, but doing that would prevent us from introducing them in non-module or opt-in environments and would make whatever the alternative keyword is contextual. That&#039;s going to force developers to know that they can only use these newfangled object factories in some contexts but not others, adding mental overhead.</description>
		<content:encoded><![CDATA[<p>Hey Marco:</p>
<p>I&#8217;d be on-side with you if we didn&#8217;t have *enormous* piles of evidence to suggest that people are already staring down the complexity you&#8217;re accusing us of adding, but doing it in an ad-hoc, non-interoperable way. Nearly every JS library includes some form of class system (yes, even jQuery via jQuery UI). If we weren&#8217;t simply codifying something you demonstrably need, I think your critique would be more relevant; but as it stands, we&#8217;re overdue for this. The complexity exists, people are already struggling with it, and there&#8217;s an opportunity for the language to do something reasonable to help settle the various style/pattern/library wars around classes.</p>
<p>I have some sympathy for the idea that we should use a name other than &#8220;class&#8221;, but doing that would prevent us from introducing them in non-module or opt-in environments and would make whatever the alternative keyword is contextual. That&#8217;s going to force developers to know that they can only use these newfangled object factories in some contexts but not others, adding mental overhead.</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Class Warfare by Nathan Wright</title>
		<link>http://infrequently.org/2012/04/class-warfare/comment-page-1/#comment-239785</link>
		<dc:creator>Nathan Wright</dc:creator>
		<pubDate>Tue, 24 Apr 2012 06:58:38 +0000</pubDate>
		<guid isPermaLink="false">http://infrequently.org/?p=1845#comment-239785</guid>
		<description>I think that Python is an excellent example of prototypal object orientation, and it works great. Much like in Javascript, everything in Python is a dict, including classes and their instances. Occasionally newbies will get tripped up when mutating an object in the class dict when they meant for the change to be local to an instance, but aside from that classes are very easy to use. It&#039;s a familiar pattern that&#039;s good at expressing certain ideas — and that&#039;s all it needs to be.

With javascript, any new framework you look at will have its own way of defining something like a class. They&#039;re trivially different and they haven&#039;t really evolved at all in the past few years. This makes them ripe for standardization IMO.

My only concern is that the underlying prototype still be exposed to those who know what they&#039;re doing. Also, classes should be mutable by default, just like everything in JS, but I guess if people want to &quot;freeze&quot; objects that should be easy enough too. Overall, the maximally minimal classes proposal seems to capture all the right behaviour pretty cleanly. +1</description>
		<content:encoded><![CDATA[<p>I think that Python is an excellent example of prototypal object orientation, and it works great. Much like in Javascript, everything in Python is a dict, including classes and their instances. Occasionally newbies will get tripped up when mutating an object in the class dict when they meant for the change to be local to an instance, but aside from that classes are very easy to use. It&#8217;s a familiar pattern that&#8217;s good at expressing certain ideas — and that&#8217;s all it needs to be.</p>
<p>With javascript, any new framework you look at will have its own way of defining something like a class. They&#8217;re trivially different and they haven&#8217;t really evolved at all in the past few years. This makes them ripe for standardization IMO.</p>
<p>My only concern is that the underlying prototype still be exposed to those who know what they&#8217;re doing. Also, classes should be mutable by default, just like everything in JS, but I guess if people want to &#8220;freeze&#8221; objects that should be easy enough too. Overall, the maximally minimal classes proposal seems to capture all the right behaviour pretty cleanly. +1</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Class Warfare by Shannon</title>
		<link>http://infrequently.org/2012/04/class-warfare/comment-page-1/#comment-239783</link>
		<dc:creator>Shannon</dc:creator>
		<pubDate>Tue, 24 Apr 2012 05:35:31 +0000</pubDate>
		<guid isPermaLink="false">http://infrequently.org/?p=1845#comment-239783</guid>
		<description>Whoops! Duh. Sorry about the missing .prototype. That was a typo.

A not-crazy example might be what amounts to an enum.

class Color { ... }
Color.prototype.WHITE = 0xffffff;
Color.prototype.RED = 0xff0000;
Colo.blend(Color.WHITE, 0xff00ff, .5);

I&#039;ve also used class variables for caches and the ilk as well.

I&#039;m perfectly happy declaring them in foo.prototype.blah form (as opposed to within the class block). I was confused because your comment seemed to indicate that one wasn&#039;t able to have prototype level data.</description>
		<content:encoded><![CDATA[<p>Whoops! Duh. Sorry about the missing .prototype. That was a typo.</p>
<p>A not-crazy example might be what amounts to an enum.</p>
<p>class Color { &#8230; }<br />
Color.prototype.WHITE = 0xffffff;<br />
Color.prototype.RED = 0xff0000;<br />
Colo.blend(Color.WHITE, 0xff00ff, .5);</p>
<p>I&#8217;ve also used class variables for caches and the ilk as well.</p>
<p>I&#8217;m perfectly happy declaring them in foo.prototype.blah form (as opposed to within the class block). I was confused because your comment seemed to indicate that one wasn&#8217;t able to have prototype level data.</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Class Warfare by Gavin Doughtie</title>
		<link>http://infrequently.org/2012/04/class-warfare/comment-page-1/#comment-239782</link>
		<dc:creator>Gavin Doughtie</dc:creator>
		<pubDate>Tue, 24 Apr 2012 04:45:39 +0000</pubDate>
		<guid isPermaLink="false">http://infrequently.org/?p=1845#comment-239782</guid>
		<description>Constantine -- classes and data hiding are orthogonal (see Smalltalk, etc.).

Everybody -- even having a *bleh* syntax for classic OO classes, even if it&#039;s just sugar, is a win in that we don&#039;t have to ship a convenience function down the wire, and classes from multiple sources can interoperate. Think of it as &quot;querySelectorAll&quot; for object designs.</description>
		<content:encoded><![CDATA[<p>Constantine &#8212; classes and data hiding are orthogonal (see Smalltalk, etc.).</p>
<p>Everybody &#8212; even having a *bleh* syntax for classic OO classes, even if it&#8217;s just sugar, is a win in that we don&#8217;t have to ship a convenience function down the wire, and classes from multiple sources can interoperate. Think of it as &#8220;querySelectorAll&#8221; for object designs.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

