const result = {
success: ["max-length", "no-amd", "prefer-arrow-functions"],
failure: ["no-var", "var-on-top", "linebreak"],
skipped: ["no-extra-semi", "no-dup-keys"]
};
function makeList(arr) {
// Only change code below this line
const failureItems = [];
// Only change code above this line
return failureItems;
}
const failuresList = makeList(result.failure);
Your browser information:
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.5993.731 YaBrowser/23.11.1.731 Yowser/2.5 Safari/537.36
Challenge Information:
ES6 - Create Strings using Template Literals
Reading the order of the task, I don’t even understand what needs to be written down and in what order, because everything here is very difficult for me to understand. It’s one thing to write this in back quotes, but besides this you need to do a bunch of other things that I don’t understand.
Ok. Having made it this far you should feel proud and know that experienced programmers get stuck. The great thing about all of this is that it has to be logical or it just wouldn’t work.
Sometimes the best way forward is to pick apart a challenge - and just focus on one part of it, solve it, and move on to the next bit.
You say that everything is difficult to understand, but to help you understand, can you describe the first thing that you are having difficulty with?
Once we solve that, we can tackle the next thing. What do you say?
Each element of the array is composed of something that looks like html, isn’t it? So, each element could be described as html of some sort.
This is an important fact to really understand, because this challenge is about using Template Literals. You will combine what you already know about html, arrays and objects, AND javascript.
Now, look at the coding window again. On line 1, how would you describe what is in the ‘result’ variable?