Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

dropping support for ie8 #339

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

Merged
richardwestenra merged 2 commits into codebar:gh-pages from trevorah:forEach-like-a-peach
Feb 23, 2017

Conversation

@trevorah
Copy link
Contributor

@trevorah trevorah commented Feb 20, 2017

ie8 is the last supported version of internet explorer for windows xp. It's usage is 1%-4% depending on which site you ask.

At the moment, we teach $.each as the way to iterate through an array, and I'd rather have students know the built-in array functions. Dropping ie8 means we can update our material, which is what this pull request does.

Thoughts?

Copy link
Member

Thanks Andy, this is great! 👌

Thoughts: On the one hand, this is the jQuery tutorial not the JS native Array method tutorial. On the other hand, you're 100% right, we should be teaching Array.prototype.forEach instead of $.each. While this section was probably originally intended to teach the jQuery method, I'm happy with this change.

I wonder whether we should include a section on advanced native Array/Object methods (e.g. map and reduce) at the end of tutorial 2, but that's a different topic.

> You can use `<title>` to display a humanly readable format of the Genre
As you can see from the console, the resulting objects are returned inside an Array. We want to iterate over the list using the `$.each( )` function and add each item to the `#genres` list, as a **list item**. As we need to have access to the `key` as well, we can set that as the list item's `id`.
As you can see from the console, the resulting objects are returned inside an Array. We want to iterate over the list using the `forEach( )` function and add each item to the `#genres` list, as a **list item**. As we need to have access to the `key` as well, we can set that as the list item's `id`.
Copy link
Member

@richardwestenra richardwestenra Feb 21, 2017
edited
Loading

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should probably clarify here that we mean the native method. How about we change the following

using the forEach( ) function

to something like

using the native Array forEach( ) method

trevorah reacted with thumbs up emoji
Copy link
Contributor Author

I totally agree with splitting things out later on, especially for introducing terms like "method" rather than just "function". It was a bit tricky to talk about forEach without mentioning methods.

Like you said though, we can always introduce that later.

Copy link
Member

@richardwestenra richardwestenra left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👌 Thanks Andy!

@richardwestenra richardwestenra merged commit 9d32046 into codebar:gh-pages Feb 23, 2017
Copy link
Contributor Author

trevorah commented Feb 23, 2017 via email

No problem!
...
On 23 Feb 2017, at 10:28, Richard Westenra ***@***.***> wrote: Merged #339. — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@richardwestenra richardwestenra richardwestenra approved these changes

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /