fix(seed): Fixed disruptive, unclosed <code> tag (#16594)

Closes #16581
This commit is contained in:
Jason Kao
2018-02-06 05:18:11 -05:00
committed by Stuart Taylor
parent 6d566bfb9b
commit d3b663338c

View File

@ -2842,7 +2842,7 @@
"releasedOn": "December 25, 2017",
"description": [
"The <code>map</code> array method is a powerful tool that you will use often when working with React. Another method related to <code>map</code> is <code>filter</code>, which filters the contents of an array based on a condition, then returns a new array. For example, if you have an array of users that all have a property <code>online</code> which can be set to <code>true</code> or <code>false</code>, you can filter only those users that are online by writing:",
"<code>let onlineUsers = users.filter(user => user.online);",
"<code>let onlineUsers = users.filter(user => user.online);</code>",
"<hr>",
"In the code editor, <code>MyComponent</code>&apos;s <code>state</code> is initialized with an array of users. Some users are online and some aren't. Filter the array so you see only the users who are online. To do this, first use <code>filter</code> to return a new array containing only the users whose <code>online</code> property is <code>true</code>. Then, in the <code>renderOnline</code> variable, map over the filtered array, and return a <code>li</code> element for each user that contains the text of their <code>username</code>. Be sure to include a unique <code>key</code> as well, like in the last challenges."
],