Skip to content

Replace ajax reference to fetch in release guide#742

Merged
jenweber merged 2 commits intoember-learn:masterfrom
dcyriller:ajax-to-fetch
May 23, 2019
Merged

Replace ajax reference to fetch in release guide#742
jenweber merged 2 commits intoember-learn:masterfrom
dcyriller:ajax-to-fetch

Conversation

@dcyriller
Copy link
Copy Markdown
Contributor

This relates to ember-cli/ember-cli#8394

@acorncom
Copy link
Copy Markdown
Member

As we've been discussing in a few other places (#570 and #708 (comment), switching to fetch usage without a polyfill such as ember-fetch means that we're encouraging usage that will break IE 11 folks. While that's something that is increasingly ok for apps depending on their users, I don't think we can yet encourage that as a global pattern while IE 11 is still part of the Ember framework support matrix.

@dcyriller any thoughts on how you'd update things here given that constraint? 😉

@dcyriller
Copy link
Copy Markdown
Contributor Author

There are roughly two options for the guides: either focus on completeness or on fundamentals.

We can go deep in the explanations around Ember (including how Ember polyfills for IE11)... Or we can show them how simple ember can be. 😉

It's your call and I'll update the PR if you still want me to. But I wanted to let you know what I think 🙂. Let me know if my word makes you change your mind.

@jenweber
Copy link
Copy Markdown
Contributor

@dcyriller thanks for your work here! The first time ever in the guides that we are advising fetch is now merged, however it uses ember-fetch. If you update the code samples to show using ember-fetch imported, I think we can merge this PR too.

So many new devs copy & paste our code as it is written, that we want to play it safe. I had no idea myself that fetch was a problem until fairly recently, so I assume that other people may have the same issue. You can link to https://guides.emberjs.com/release/routing/specifying-a-routes-model/#toc_fetch-example if you want to point people towards an explanation of why we are using ember-fetch.

Does that sound ok?

@jenweber
Copy link
Copy Markdown
Contributor

P.S. I really like that you have made the prose more generalized. I think it really helps people who are just learning to figure out what is mentioned as examples vs what is a learning requirement.

@MelSumner
Copy link
Copy Markdown
Member

@jenweber @acorncom I wonder if this would be okay to merge, since ember-data now uses ember-fetch (which was a necessary part of removing the need for jQuery from Ember). What do you think?

@dcyriller
Copy link
Copy Markdown
Contributor Author

I've added fetch import in javascript files 👍

@jenweber
Copy link
Copy Markdown
Contributor

@MelSumner good point, that makes sense.

Thanks @dcyriller for your patience and keeping up with comments/edits! Let's merge 🎉

@jenweber jenweber merged commit 40dc187 into ember-learn:master May 23, 2019
@dcyriller dcyriller deleted the ajax-to-fetch branch May 23, 2019 16:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants