Skip to content

proposal: refactor $.getJSON examples to use fetch #570

@ghost

Description

Converting code examples for Octane has refreshed a discussion about using jQuery in trivial code examples. I think we should refactor code examples that feel dated due to using $.getJSON. See #33 for my prior hang ups. Tangential to #499.

current usage in release guides

why use window.fetch?

I propose we use window.fetch for at least 3 reasons:

  1. it is widely supported by modern browsers.
  2. In a land of jQuery free Ember applications, why should we promote depending on the entire jQuery library for a single function?
  3. Easier teaching and mental model. By aligning with a web standard, we leverage existing teaching and developer experience. For new developers it gives them a helpful tool that could be considered a best practice in web development. Fetch's Promise based design flows nicely with concepts taught throughout the Ember guides and modern asynchronous web programming.

Metadata

Metadata

Assignees

No one assigned

    Labels

    help wantedExtra attention is neededtime-sensitiveIt is important that this task be finished very quickly

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions