-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refactor AJAX with Fetch API #18
Comments
Note: this has the potential of opening up a can of worms, like installing Babel into our project.... |
Promises for APIs? I'm intrigued. I'll probably want to take the udacity course you took so I'm sorta up to speed. But yeah, let's think about this for a future release. Speaking of AJAX, I wanted to let you know that the json scripts now throw cross domain errors when working locally. It works in Edge locally and is still working on our GitHub pages. I'm guessing that's an update from Chrome. |
@digilou Do you expect promises to only affect our current JSON block? Might it have implications for the displayResults function? I'm thinking of doing some refactoring of the display code based on what I've learned in Practical JavaScript. I'm deciding whether I need to take the promises course before or after. |
That's a good question @ddcornwall. I'm not sure, as I haven't evaluated your JS code all that closely. Refactoring is always a work in progress. I say, refactor, then worry about promises later. |
Recently learned more about this in my Mobile Web Specialist class. The Fetch API is the modern way to handle these requests. It is not supported by IE 11 or Opera Mini, but there is a fetch polyfill available here on Github. |
Looks like the non-nanodegree version for learning is available as a 3-week course: Asynchronous JavaScript Requests, which looks like the lessons I'm currently going through. Once I finish the Fetch lesson, I will have a better idea about how to implement this. |
@ddcornwall I'm working on this right now, while Fetch is fresh in my mind from my Google/Udacity coursework. |
Finished my nanodegree! So now I'm ready to get back to personal projects (like this) and apply what I've successfully learned. |
Congratulations on finishing the Nanodegree and thanks for taking another
look at NARA Alaskana. - Danie
…On Mon, Nov 12, 2018 at 5:04 PM Amy Carney ***@***.***> wrote:
Finished my nanodegree! So now I'm ready to get back to personal projects
(like this) and apply what I've successfully learned.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#18 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AfPYQSYzMdy7XF7Qt90P_QA2htYDSRgGks5uuiFCgaJpZM4SyNZ2>
.
--
==================
Daniel Cornwall
[email protected]
http://godort.libguides.com/alaskadbs
|
It sounds like ES6 promises open a whole new door for API calls. It may even offer better performance and security. I'd like to give it a shot later on in the project, once all the functionality has been worked out.
The text was updated successfully, but these errors were encountered: