- From: Tab Atkins Jr. <jackalmage@gmail.com>
- Date: Tue, 3 Dec 2013 08:19:55 -0800
- To: Rick Waldron <waldron.rick@gmail.com>
- Cc: "Marat Tanalin | tanalin.com" <mtanalin@yandex.ru>, Elliott Sprehn <esprehn@gmail.com>, "www-dom@w3.org" <www-dom@w3.org>
On Mon, Dec 2, 2013 at 6:40 PM, Rick Waldron <waldron.rick@gmail.com> wrote: > On Mon, Dec 2, 2013 at 9:39 PM, Tab Atkins Jr. <jackalmage@gmail.com> wrote: >> On Mon, Dec 2, 2013 at 6:05 PM, Rick Waldron <waldron.rick@gmail.com> >> wrote: >> > Yes, and it's not just you—the "single function/constructor/method that >> > accepts a string and produces a node" is a common pattern implemented by >> > all >> > major libraries: >> > >> > Y.Node.create("<div>"); >> > jQuery("<div>"); >> > dojo.create("div"); >> > new Element("div"); >> > new Ext.dom.Element("div"); >> >> There's *also* a common pattern of something like "HTML.h1()", for >> simple "templating in JS" libraries. > > References? I've never actually used them, so I can't name any off the top of my head. ^_^ I'll ask on Twitter. ~TJ
Received on Tuesday, 3 December 2013 16:20:45 UTC