Skip to content
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

Olivia's Trek #35

Open
wants to merge 12 commits into
base: master
Choose a base branch
from
Open

Olivia's Trek #35

wants to merge 12 commits into from

Conversation

secretsharer
Copy link

TREK

Congratulations! You're submitting your assignment!

Comprehension Questions

Question Answer
What does it mean for code to be asynchronous? Instead of code being executed line by line in a linear fashion, JS browser functions and event handling appear "out of order", being dependent on user decisions and each other, i.e., a click triggers an event, which triggers a function, which triggers a template load so there can be another event, etc...
Describe a piece of your code that executes asynchronously. How did this affect the way you structured it? $(document).ready(function() {
$('#bon-voyage').click(allTripsClickHandler) is a good example. In order for the list of all trips to load, the event listener must be loaded w/ doc.ready when the initial page loads, waiting for the click that will load the populated template and consequent functions.
What kind of errors might the API give you? How did you choose to handle them? I used a failure callback for both show and all, with response/messages to let the user know more information if they were using a bad url or the was an outage preventing them from connecting to the api/getting its response.
What is an Underscore template? Describe one template you used for this project. Much the way we would use era in our HTML in rails, an underscore template can employ js and jq to call/interact with events and vars on the page to keep dry, templated actions in our html. I used a show trip, trip details template with reserve form to reserve the displayed trip.
Do you have any recommendations on how we could improve this project for the next cohort? <3

@secretsharer
Copy link
Author

My response to question 2 ended up in the question box - cool trick!?

@CheezItMan
Copy link

TREK

What We're Looking For

Feature Feedback
Core Requirements
Git hygiene Good # of commits
Comprehension questions Check, good answers
Functionality
Click a button to list trips Check
Click a trip to see trip details Check
Fill out a form to reserve a spot The form exists, but it look like you have the event handler commented out, // $('#new-trip-form').submit(newTripClickHandler);.
Errors are reported to the user Nope, you're missing .fail handlers for the AJAX requests.
Styling, Foundation grid layout Grid-Layout used, not a lot of content spread out using the grid layout, lots of white text.
Under the Hood
Trip data is retrieved using jQuery AJAX Check
JavaScript is well-organized and easy to read Nice work dividing content with comments.
HTML is semantic Check
All dynamic content is rendered using Underscore templates Check
Overall Good work getting the trip listing and showing details. Looks like you ran out of time before registering for a trip.

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.

2 participants