Re: [ReSpec]: dropping $ajax support

Awesome! Keep up the good work :)

— Michiel

> On 20 Nov 2017, at 04:21, Marcos Caceres <mcaceres@mozilla.com> wrote:
> 
> Hi ReSpec users,
> tl;dr: If you are using jQuery's Ajax via ReSpec for custom
> processing, please read on as your spec may be affected. If you would
> like to continue using jQuery's Ajax, you will need to import jQuery
> independently of ReSpec (see "## I'm affected", below).
> 
> ## What's changing?
> Back in January [1] of this year, I announced my intention to migrate
> ReSpec away from full jQuery to jQuery slim (and eventually completely
> off jQuery). Last night, I landed the last changes needed to make the
> transition to jQuery slim.
> 
> ## What's jQuery slim?
> It's a jQuery build that "excludes ajax, effects, and currently
> deprecated code" as of 2016. So, unless you rely on those things, you
> are not affected.
> 
> See:
> https://blog.jquery.com/2016/06/09/jquery-3-0-final-released/
> 
> ## Why?
> Short answer: all "Ajax" functionality in ReSpec is now achieved with
> `fetch()`, and all effects are achieved with CSS Transitions - because
> today's Web Platform is awesome 💗
> 
> Long version: Although jQuery was basically the only sane way to cope
> with cross-browser development a decade ago, we (the Web community)
> have made strides in interop, and bringing similar features to the
> Web, and come up with much nicer/faster ways of doing things natively
> (e.g., fetch, promises, more powerful css selectors, and general
> improvements to the DOM APIs).
> 
> In this new era of component/template/data-driven development, JQuery
> has become a maintainability burden to ReSpec - it just gets in the
> way and frustrates development, debugging, etc. It also means all
> users incur a a jQuery "tax", every time they open a ReSpec document:
> this wastes bytes over the wire, and wastes time by having to wait for
> jQuery to become available for use on the main thread.
> 
> ## I'm affected
> If you are affected by this change, you should include jQuery via, for
> example, a CDN:
> 
> https://code.jquery.com/
> 
> Remember to put class='removeOnSave', to make sure jQuery gets removed
> by ReSpec on export.
> 
> Otherwise, make the jump to using `fetch()`. You will be pleasantly
> surprised by how nice the API is. If you need a hand with the
> transition, give me a shout! Happy to help you.
> 
> ## What happens next
> Unless I hear otherwise, I'll wait a week or two before rolling this out.
> 
> Going forward, you should continue work with the assumption that
> jQuery will not be part of ReSpec in the future. Sooner, rather than
> later, I'll stop exposing jQuery via ReSpec to the global scope and
> eventually switch to Cash internally - a 3kb replacement library for
> jQuery.
> 
> Kind regards,
> Marcos
> 
> [1] https://lists.w3.org/Archives/Public/spec-prod/2017JanMar/0005.html
> 

Received on Monday, 20 November 2017 07:49:34 UTC