W3C home > Mailing lists > Public > public-webapps@w3.org > April to June 2014

Re: Fetch API

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Sun, 1 Jun 2014 10:31:21 -0700
Message-ID: <CAAWBYDA5ENxXBsAU2WVDQPzcUk4uj-bVzjSv6o-i7dC-D2UPPA@mail.gmail.com>
To: Domenic Denicola <domenic@domenicdenicola.com>
Cc: Anne van Kesteren <annevk@annevk.nl>, public-script-coord <public-script-coord@w3.org>, Joshua Bell <jsbell@chromium.org>, Jungkee Song <jungkee.song@samsung.com>, Yehuda Katz <wycats@gmail.com>, Alex Russell <slightlyoff@google.com>, Jonas Sicking <jonas@sicking.cc>, Jake Archibald <jaffathecake@gmail.com>, Tobie Langel <tobie.langel@gmail.com>, WebApps WG <public-webapps@w3.org>
On Sat, May 31, 2014 at 11:06 PM, Domenic Denicola
<domenic@domenicdenicola.com> wrote:
> - Named constructors scare me (I can't figure out how to make them work in JavaScript without breaking at least one of the normal invariants). I think a static factory method would make more sense for RedirectResponse.

What invariants are you concerned about?  Using NamedConstructor is
identical to doing:

class Foo { ... }
let Bar = Foo;
// now I can do "new Foo()" or "new Bar()", to the same effect.

Received on Sunday, 1 June 2014 17:32:11 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 18:14:24 UTC