Arrow function basics in javascript 😃

Sdílet
Vložit
  • čas přidán 6. 09. 2024
  • Welcome to a youtube channel dedicated to programming and coding related tutorials. We talk about tech, write code, discuss about cloud and devops. That’s what we do all day, all year. We roll out a lot of series and videos on our channel.
    All the learning resources such as code files, documentations, articles and community discussions are available on our website:
    chaicode.com/
    You can find our discord link, github link etc on the above website.
    Twitter/X link: x.com/hiteshdo...
    Discord link: hitesh.ai/discord
    Learn React with 10 projects: • Let's learn react from...
    Learn Docker: • A practical guide on D...
    Learn Kubernetes: • Complete Kubernetes Co...
    How does a browser works: • How does a browser wor...
    How nodejs works: • How node JS works | En...
    Learn Redux-toolkit: • Learn Redux Toolkit in...
    Learn NextJS: • Nextjs Full stack course
    Learn Typescript: • Why to learn Typescript
    Learn Javascript: • Welcome to new JavaScr...
    Learn React Native: • React Native Mastery: ...
    Learn Zustand: • React state management...
    Learn Golang: • How to get started wit...

Komentáře • 211

  • @anooppremkumar8529
    @anooppremkumar8529 Před 4 lety

    const todo = [{
    title: 'Learn coding',
    isDone: true,
    },{
    title: 'Work-Out',
    isDone: false,
    },{
    title: 'Go to office',
    isDone: true,
    },{
    title: 'meet customer',
    isDone: false,
    },{
    title: 'Drive home',
    isDone: true,
    },{
    title: 'collect laundry',
    isDone: false,
    }]
    let thingsNotDone = todo.filter((todo) => todo.isDone === false)
    for (var i = 0; i < thingsNotDone.length; i++) {
    console.log(thingsNotDone[i].title)
    }
    This one definitely works but hope this is the intended solution.
    Thank you Hithesh for your effort. Appreciate it

  • @prathameshjadhav5212
    @prathameshjadhav5212 Před 4 lety +24

    How many of u are here after quarantine**

  • @nishchaysharma5904
    @nishchaysharma5904 Před 4 lety +4

    Well documentations are really helpful when you know how to look upon them.
    const titleNotDone = myTodos.filter(todos => todos.isDone === false)
    .map(todos => todos.title)

  • @prakharagarwal40
    @prakharagarwal40 Před 6 lety +7

    Assignment :
    const ThingsNotDone = todo.filter((todos) => todos.done === false);
    ThingsNotDone.forEach((things) => console.log(things.title));

  • @fabienbedogue527
    @fabienbedogue527 Před 6 lety +53

    const notDone = todos.filter((todo) => todo.isDone === false);
    notDone.forEach(todoo => console.log(todoo.title));

  • @vinaymanikant9710
    @vinaymanikant9710 Před 6 lety +1

    //Assignment code for the video
    ------------------------------------------------------------------------------------------------------------------------------------
    const newTodo=[
    {
    title:'Brush',
    isDone:true,
    },
    {
    title:'Bath',
    isDone:true,
    },
    {
    title:'Breakfast',
    isDone:false,
    },
    {
    title:'Catch up bus',
    isDone:true,
    },
    {
    title:'Complete assignment',
    isDone:false,
    },
    {
    title:'Study',
    isDone:false,
    }
    ]
    const todo=newTodo.filter((param)=>param.isDone===false
    )
    for (let i = 0; i < todo.length; i++) {
    console.log(todo[i].title)
    }
    -----------------------------------------------------------------------------------------------------------------------------------------------------------

  • @manivelarung
    @manivelarung Před 4 lety +2

    //Object array
    const toDos = [{
    title: "Morning Gym",
    isDone: true
    },{
    title: "Morning Yoga",
    isDone: true
    },{
    title: "Meetings",
    isDone: false
    },{
    title: "Lunch meet",
    isDone: false
    },{
    title: "Assignments",
    isDone: true
    },{
    title: "UI design",
    isDone: false
    }]
    //Filter logic using Arrow function
    const notDone = toDos.filter((todo) => {
    if(todo.isDone === false)
    {
    console.log(todo.title)
    }
    });
    //Calling the method
    notDone;

  • @shahzadamr6193
    @shahzadamr6193 Před 6 lety +2

    you are awesome,if i visit to india the first person to meet will be you.
    thnks for videos.....................keep this on..

  • @indracahyadi4757
    @indracahyadi4757 Před 2 lety

    This really explain the arrow function is! Thanks Hitesh

  • @akashgujarathi6013
    @akashgujarathi6013 Před rokem

    Heres my code: todos.filter((todo) => todo.isDone == true).map((todo) => todo.title)
    I am a Java developer and want to learn Javascript. Your courses are super helpful.

  • @divyansh_dk
    @divyansh_dk Před 5 lety +1

    const findTrueTodo = myTodos.filter((todo) => {
    if( todo.isDone === true ){
    console.log(todo.title)
    }
    })
    Working code
    ps: Make changes in variable name according to your needs

  • @himanshuagarwal3451
    @himanshuagarwal3451 Před 6 lety

    Here's the full code ..
    const todos = [ {
    title:'Brush Teeth',
    status:"done",
    } , {
    title:'Bath',
    status:"done",
    } , {
    title:'Eat breakfast',
    status:"done",
    } , {
    title:'Eat Lunch',
    status:"notDone",
    } , {
    title:'Eat dinner',
    status:"notDone",
    } , {
    title:'Sleep',
    status:"notDone",
    } ]
    let thingsNotDone = todos.filter((todos) => { if(todos.status == "notDone" ){console.log(todos.title);}})

  • @sunilnarute3924
    @sunilnarute3924 Před 4 lety

    Your way of teaching style is so clear and easy

  • @pashtoonpk5899
    @pashtoonpk5899 Před 3 lety

    you are the best teacher as well as best programmer.The way of explaining coding concepts are very simple.... I have no words to say about you 🤔

  • @devsharma1788
    @devsharma1788 Před 6 lety +12

    Edited-
    const Todos=[{
    title: 'Title1',
    isDone: true,
    },{
    title: 'Title2',
    isDone: false,
    },{
    title: 'Title3',
    isDone: true,
    },{
    title: 'Title4',
    isDone: false,
    },{
    title: 'Title5',
    isDone: true,
    },{
    title: 'Title6',
    isDone: false,
    }]
    const result = Todos.filter((todo) => todo.isDone === false)
    result.forEach(todo => console.log(todo.title));

  • @reidwilliamson6477
    @reidwilliamson6477 Před 3 lety

    Your very likeable personality makes your videos easy and fun to learn! Blessings from D.C!

  • @nalinkumar1558
    @nalinkumar1558 Před 3 lety

    const result = todos.filter((todo) => todo.isDone == true ? console.log(todo.title) : false);
    Thanks, Hitesh for the wonderful basic videos. keep uploading!

  • @kal_eide
    @kal_eide Před 5 lety +4

    Trying to learn this while sick doesn't help, but had fun figuring it out.
    const todoDone = todos.filter((todos) => {if (todos.notDone === true) {console.log(todos.title)}})

  • @CodingWithDapo
    @CodingWithDapo Před 4 lety

    I am currently watching a react native tut online and I was totally lost, but thank God you posted this video. I wish I can link the video to the tut... thanks alot

  • @pankajjoshi547
    @pankajjoshi547 Před 4 lety

    const doneThings = function(todo, trueOrFalse)
    {
    const titleReturn = todo.filter((todo)=>todo.isDone === trueOrFalse);
    return titleReturn;
    }
    doneThings(newTodo,false).forEach((todo) => console.log(todo.title))

  • @aquere
    @aquere Před 5 lety

    Literally the hardest way possible to solve this, but it's good
    "use strict";
    let toDoList = [{
    title: "Have a Breakfast",
    isDone: false
    }, {
    title: "Smile:)",
    isDone: true
    }, {
    title: "Brush your teeth",
    isDone: false
    }, {
    title: "Go to the gym",
    isDone: false
    }, {
    title: "Have a good sleep",
    isDone: true
    }, {
    title: "Start learning plain js",
    isDone: true
    }];
    function leftToDoFilter(list) {
    let filtered = list.filter( (item) => item.isDone === false );
    let filteredTitle = [];
    filtered.forEach( item => filteredTitle.push(item.title) );
    return filteredTitle;
    }
    console.log(leftToDoFilter(toDoList));

  • @balanarsimharaotanneeru6979

    That's a great explanation. It would be amazing if you explain the purpose of arrow functions in the code.

  • @TechnoSaroha
    @TechnoSaroha Před 5 lety

    *Not able to print the Objects* inside the Array. It only printing ' [ ] ' . Not printing isDone Objects. Why it is so? I have used VSCode, console also.

  • @edwardspresume
    @edwardspresume Před 5 lety +9

    const completedTasks = todo.filter(task => task.isDone).map(task => task.title);

  • @sureshkumar-xd3ot
    @sureshkumar-xd3ot Před 6 lety

    nice explanation it helps very lot to beginners , I done u r assignment and can u share the difference b/w the "arrow function" and "js function" ,arrow function have more properties compare to js function
    var todo = [
    {title:"First",isDone:true},
    {title:"Second",isDone:false},
    {title:"Third",isDone:true},
    {title:"Fourth",isDone:false},
    {title:"Fiveth",isDone:true},
    {title:"Sixth",isDone:false}
    ];
    todo.filter((x)=>{ if(x.isDone === true){console.log(x.title)}});

  • @reluminopraha5948
    @reluminopraha5948 Před rokem

    Well explained ❤

  • @mdyounusahamed6668
    @mdyounusahamed6668 Před 4 lety

    I just love your content brother. Lots of love for you.

  • @tigerugby1996
    @tigerugby1996 Před 5 lety

    Thanks for the simple explanation of arrow functions appreciate it. Taking it nice and slow allowed me to understand it :)

  • @jason0ng
    @jason0ng Před 5 lety

    Great video. Nice and easy to follow and understand. Thank you Hitesh.

  • @prasannaacharya4507
    @prasannaacharya4507 Před 6 lety +1

    I think i m in love with Arrow functions 😂 #js love

  • @hardishah5419
    @hardishah5419 Před 3 lety

    Assignment:
    let thingsNotDone = things.filter((todo)=>{
    if(todo.isDone == false)
    console.log(todo.title);
    });

  • @vaibhavdangayachvd
    @vaibhavdangayachvd Před 5 lety

    //Create a tudo with 6 objects using filter to get things not done. Print only title of the job to do.
    const myTudos=[{name:'Play',done:false},{name:'Eat',done:false},{name:'Read',done:false},
    {name:'Talk',done:true},{name:'Walk',done:true},{name:'Sleep',done:true}];
    let find_not_done=function(tudos){
    const not_done=tudos.filter((tudo)=> tudo.done===false)
    not_done.forEach((nd)=>console.log(`You have not done : ${nd.name}`))
    }
    find_not_done(myTudos);

  • @tanujkalra7334
    @tanujkalra7334 Před 4 lety

    why aren't we using simple loop inside a function to check the true entries ?
    it will be easier that way around!

  • @suvamprasad2782
    @suvamprasad2782 Před 4 lety

    const todos = [{
    title: 'Wake up',
    isDone: true
    }, {
    title: 'breakfast',
    isDone: true
    }, {
    title: 'studying',
    isDone: false
    }, {
    title: 'go to park',
    isDone: false
    }, {
    title: 'lunch',
    isDone: true
    }, {
    title: 'go to gym',
    isDone: false
    }]
    let workNotDone = todos.filter( (todo) => todo.isDone === false).forEach((todo) => console.log(todo.title))

  • @rishikesharora8681
    @rishikesharora8681 Před 4 lety

    mySchedule.filter((mySchedule)=> mySchedule.isDone === true).forEach((objs)=> console.log(objs.title))

  • @NIPPONSAN92
    @NIPPONSAN92 Před 5 lety +2

    const notDone = todos2.filter((todo) => todo.isDone === false);
    for(var i = 0; i

  • @jeevithagowda4218
    @jeevithagowda4218 Před 3 lety

    Thanks for the video Hithen, Is there any performance difference between function declaration without using Fat Arrow function and the one with Fat Arrow function ?

  • @AbbasAli-kl8rl
    @AbbasAli-kl8rl Před 5 lety

    After creating the todo list, this one line will surely sort the titles out for notDone
    todo.filter( (eachTodo) => eachTodo.isDone === false ? console.log(eachTodo.title) : null )

  • @z.m.4331
    @z.m.4331 Před 5 lety

    Clear explanation and learned about the filter() function, thanks :D

  • @9791993447
    @9791993447 Před 6 lety

    Thank u buddy for your wonderful explanation in arrow function.Understood well.

  • @mohitkarkar8774
    @mohitkarkar8774 Před 6 lety +2

    //printing title using for loop
    const notDone = Todos.filter((todo) => todo.isDone === false)
    for (var i =0; i < 3; i++){
    console.log(notDone[i].title)

  • @balakrishnakadiyala1378

    I jus want to understand this, Why are you using CONST instead of Let? CONST is constants right? Please clarify.

    • @chorko696
      @chorko696 Před 5 lety

      const denote constants. They do not change their value during execution (try and change it, you'll get an error).

  • @nihalpandey6317
    @nihalpandey6317 Před 4 lety

    let taskDone = todos.filter(todo => !todo.isDone).map(todo => todo = todo.title)

  • @eufraniodiogo50
    @eufraniodiogo50 Před 4 lety

    const thingsNotDone = todos.filter(todo => todo.isDone == false).map(todo => todo.title)

  • @roman__saavedra
    @roman__saavedra Před 4 lety

    Thanks for the explanation! Good and clear video

  • @dishantrana341
    @dishantrana341 Před 5 lety

    there is only one parameter you are passing.... so you can remove those parentheses around name......
    instead of .. const sayHello = ( name ) => `hey there ${name}`
    you can write ... const sayHello = name => `hey there ${name}`

  • @andrealechenujnr1208
    @andrealechenujnr1208 Před 5 lety

    const notDone = myTodos. filter((todo) => todo.isDone === false )
    notDone.forEach((unDone) => console.log(unDone.title))

  • @vatsalmistry2477
    @vatsalmistry2477 Před 5 lety

    const todosNotDone = todos.filter((todo) => todo.isDone === false).map((todo) => todo.title);
    Combining filter and map method together.

  • @tiaeastwood8416
    @tiaeastwood8416 Před 4 lety

    Very clear explanation, thank you!

  • @rajshrisingh9378
    @rajshrisingh9378 Před 2 lety

    I am getting No debugger available, can not send 'variables' is error in my console

  • @gauravnagar3712
    @gauravnagar3712 Před 6 lety

    I always prefer arrow function and make code small but I hate when someone call it big fat arrow its
    disrespectful

  • @muhammadatiqulkabir1885

    Hi bro! Your way of explaining things is very easy to follow and understand. I occasionally see your clip and most of the time found what I was looking for. Your explanation about Arrow Function in JavaScript helped me to have a cleater understanding on the topic as I am a beginer of JavaScript. Thank you.

  • @Shruthi_CartoonVlogs
    @Shruthi_CartoonVlogs Před 4 lety

    Is arrow function and lamda function same

  • @reperxdzns5711
    @reperxdzns5711 Před 3 lety

    ASSIGNMENT
    const isNotDone = myTodos.filter((todos) => todos.isDone === false)
    const checkIfDone = isNotDone.forEach(todos => {
    console.log(todos.title)
    });

  • @aminbashanfar1914
    @aminbashanfar1914 Před 6 lety

    It's a really great video man I can't thank you enough It was for me really hard to understand this with arrow with function but now you make it really semple

    • @HiteshCodeLab
      @HiteshCodeLab  Před 6 lety +1

      Thanks

    • @bharatrbk2884
      @bharatrbk2884 Před 5 lety

      Thanks for all the things, what is the actual need of using *const* in starting of program....

  • @sineadward5225
    @sineadward5225 Před 4 lety

    Very helpful

  • @rishikesharora8681
    @rishikesharora8681 Před 4 lety

    Hey Hitesh....Is arrow funtion => is as same as lambda expression in Java8 ?

  • @dennypaul
    @dennypaul Před 5 lety

    Can someone tell me what is wrong with the below code. It returns undefined.
    const showToDo = toDoList.filter((todo)=>todo.isDone === true);
    const showToDoTitle = showToDo.forEach(todo=>todo.title);
    console.log(showToDoTitle);

  • @md.redwanhossain8822
    @md.redwanhossain8822 Před 2 lety

    Which font you are using?

  • @nitingupta1417
    @nitingupta1417 Před 4 lety

    enjoyed the video

  • @619frank
    @619frank Před 6 lety

    Wonderfull

  • @NinjaCoder472
    @NinjaCoder472 Před 6 lety

    todos.filter(todo => !todo.isDone).forEach(thing => console.log(thing.title))

  • @balachanderharivarsha9757

    let a=5,b=5;
    var sample=()=>
    console.log("hello");

    if(a==b){console.log(a+b);}
    console.log("hello");
    sample();
    output : 10 hello hello
    / let a=5,b=5;
    // var sample=function(){
    // console.log("hello");

    // if(a==b){console.log(a+b);}
    // console.log("hello");
    // }
    // sample();
    output: hello 10 hello
    how is posssible can anyone plz explain???

  • @prabulingam1039
    @prabulingam1039 Před 5 lety

    const notDone = todos.filter((todo) => todo.isDone === false)
    console.log(notDone.map(test=>test.title))

  • @deeproy7292
    @deeproy7292 Před 5 lety

    you never said about the binding of the "this" with the arrow function

  • @rabindrajoshi9258
    @rabindrajoshi9258 Před 6 lety +4

    There must be a better way, what is it?
    ------
    const thingsNotDone = todos.filter(todo => !todo.isDone)
    thingsNotDone.forEach(thing => console.log(thing.title))

    • @itarticles6338
      @itarticles6338 Před 4 lety

      You can run forEach on filter result itself, don't consider creating mid level variable. Just small enhancement
      todos
      .filter( todo => !todo.isDone )
      .forEach( todo => console.log( todo.title ));

  • @samplebuffer3065
    @samplebuffer3065 Před 5 lety

    const things = todo.filter ( function (ctr){
    if (ctr.done === false)
    return ctr.name
    })
    console.log(things)
    //This gives me the entire object within the array which is false, even though I'm returning ctr.name.
    Can anyone tell me why?

  • @ranjanrnj6864
    @ranjanrnj6864 Před 5 lety

    const lists = [{
    title : "Waked up in morning",
    isdone : true,
    },

    {
    title : "eat breakfast",
    isdone : true,
    },

    {
    title : "roam outside",
    isdone : false,
    },

    {
    title : "watch tv",
    isdone : false,
    },

    {
    title : "play cricket",
    isdone : true,
    },

    {
    title : "scored century",
    isdone : false,
    }];

    const result = lists.filter((list) => {
    return list.isdone === false;
    }); // stored in a variable
    result.forEach((value) => {
    console.log(value.title); // performing forEach in the stored variable and printing value with title.
    });

  • @rajatahuja2608
    @rajatahuja2608 Před 5 lety

    can anyone help me... thanks in advance
    const itemsTrue = [
    {title:'item1',isDone:false },
    { title:'item2', isDone:true},
    {title:'item3', isDone:true},
    { title:'item4', isDone:false},
    { title:'item5', isDone:false},
    { title:'item6', isDone:true},
    ]
    const things = itemsTrue.filter((i) => i.isDone === false )
    document.write(things);
    it show's o/p = nothing why
    2. when i change it to ( let things) variable ---- it show's = [object Object],[object Object],[object Object]

  • @pallavipujari
    @pallavipujari Před 4 lety

    const thingsDone = todo.filter(ele => ele.isDone=== false).map(ele=>ele.title);

  • @imaadi20
    @imaadi20 Před 5 lety

    Good Day Sir, screen recording ke liye konsi software use karte hai aap? Kya aap bata sakte hain..... please......

  • @aamirsayani7101
    @aamirsayani7101 Před 6 lety

    // My todo list
    const todos = [{
    title: 'Complete lecture list',
    isDone: false,
    }, {
    title: 'Practice lecture assignments',
    isDone: true,
    }, {
    title: 'Drink ice tea',
    isDone: false,
    }, {
    title: 'Practice little more',
    isDone: true,
    },{
    title: 'Do some fun things',
    isDone: false,
    }, {
    title: 'Morning exercise',
    isDone: true,
    }]
    //Filter will itterate through all todos and if function condition returns true //it will create new array for them and will return it
    const remainingWork = todos.filter(function (todo){
    if (!todo.isDone){
    return true;
    }
    });
    //It will log the remaining todos title
    remainingWork.forEach(function(todo){
    console.log(todo.title);
    });

  • @suryagowda3663
    @suryagowda3663 Před 4 lety

    I am learnt programs in CZcams n also practiced. When trying to write own programs I don't getting ideas. Please help me sir

  • @VisVichu
    @VisVichu Před 4 lety

    return 'hello ${name}!' is not returning the name i pass.. it just printing hello ${name} !

  • @rb4754
    @rb4754 Před 4 lety

    const todoDone = todos.filter((todo) => {
    return todo.isDone === true
    })
    console.log(todoDone.title)
    why is it wrong? Showing "undefined" error.

    • @abdulrahmanhamdan4355
      @abdulrahmanhamdan4355 Před 4 lety

      Because todoDone is a variable not an object
      (todoDone.title) in case you defined todoDone as an object.

  • @ashishranjanpatel4756
    @ashishranjanpatel4756 Před 6 lety

    is arrow function similar to the lemda expression in java or python.

  • @mdyounusahamed6668
    @mdyounusahamed6668 Před 4 lety

    const notDone = todos.filter((todo)=>todo.isDone === false)
    notDone.forEach((todo) => console.log(todo.title));

  • @rahulsingh-wj9cb
    @rahulsingh-wj9cb Před 6 lety

    Hi Hitesh, can we use lambda expression to return values as well in JS. I use to do such things in my C# using .Select. But is there something like that in JS (was working with assignment and trying to wrap up in single line).

  • @nirbhaiuppal7271
    @nirbhaiuppal7271 Před 4 lety

    When I use document.write(thingsDone) , the output shows word object , I did not understand why it does not print contents of objects

    • @itarticles6338
      @itarticles6338 Před 4 lety

      Hi Nirbhai, 'thingsDone', is an array, not plain text or number or bool. So when we say document.write it will say it's not object. You can console.log to print that array on console. Console API check it's that's array and will print every element inside array. Or if you want to print of document only, you need to convert the array to single string, that we can do by calling JSON.stringify.

  • @awaiszaki14
    @awaiszaki14 Před 4 lety

    const thinsAreDone = todos.filter( todo =>{
    if(todo.isDone === false){
    return todo.title
    }
    })

  • @viditkapil
    @viditkapil Před 6 lety

    let fil = todos.filter((todo) => !todo.isDone)
    fil.forEach ((todo) => console.log(todo.title))

  • @amantiwari3493
    @amantiwari3493 Před 3 lety

    const thingsNotDone = todos.filter((todo) =>
    {
    if(todo.isDone === false){
    console.log(todo.title);
    }
    })

  • @nudynoobie
    @nudynoobie Před 5 lety +1

    const notDone = todos.filter((todo)=>{
    if(todo.title===false)
    return console.log(todos.title);

  • @AshishKumar-oo1of
    @AshishKumar-oo1of Před 6 lety

    const thingsNotDone = todos.filter((todo)=> todo.isDone === false)
    thingsNotDone.forEach(todo =>console.log(todo.title) )

  • @royalenfieldmeteorrider7873

    const titleRun =ass.filter((ass)=>ass.isDone===true)
    titleRun.forEach(function(titleRun,index){
    console.log(titleRun.title)
    })

  • @gauravrawat8441
    @gauravrawat8441 Před 6 lety

    Using If
    const notDone = todos.filter((todo) => {
    if(todo.isDone === false){
    console.log(todo.title);
    }
    });

  • @HarshSharma-rb6su
    @HarshSharma-rb6su Před 6 lety

    I just cant't seem to run my javasript file in my terminal of MS code, tough I have installed node.js

  • @suryagowda3663
    @suryagowda3663 Před 4 lety

    Also provide me notes also sir

  • @sayalisawant1198
    @sayalisawant1198 Před 5 lety

    const thingsUndone =todo.filter((todo)=>
    {
    if(todo.isDone===false)
    console.log(todo.title)
    })

  • @shivamsehrawat7610
    @shivamsehrawat7610 Před 4 lety

    So we can call it a lambda function?

  • @DigoTv847
    @DigoTv847 Před 4 lety

    why u always decalre function as const ????????????????

  • @mrcoder7327
    @mrcoder7327 Před 5 lety

    Can I use the arrow function on forEach?
    And how do I write the arrow function without any parameters?

    • @itarticles6338
      @itarticles6338 Před 4 lety

      1. LiskOfTask.forEach(task=>console.log(task.tititle))
      2. let greeting = ()=> console.log('Hi there');

  • @patrykbunix241
    @patrykbunix241 Před 5 lety

    thanks!

  • @sivajisanapala8969
    @sivajisanapala8969 Před 4 lety

    console.log(thingsdone.map(({title})=> title))

  • @terrificrashmi
    @terrificrashmi Před 4 lety

    todos.filter((todo)=>{
    let a=todo.isDone;
    if(a===false){
    console.log(todo.Title)
    }
    } );

  • @gauravnagar3712
    @gauravnagar3712 Před 6 lety

    Quick question : react native android app is made in android studio or in something else sir?

    • @HiteshCodeLab
      @HiteshCodeLab  Před 6 lety +5

      Most on (Sublime/Atom/VScode) and for running the app you can use your phone with expo app.

  • @dishantrana341
    @dishantrana341 Před 5 lety

    Same as lemda function of Java

  • @bhuwansharma6508
    @bhuwansharma6508 Před 4 lety

    use if to do in simple way

  • @pranjalrawat6651
    @pranjalrawat6651 Před 4 lety

    const thingsNotDone = todos.filter((todo) => todos.isDone === false)
    console.log(thingsNotDone);
    can anyone please tell me why is this not working ?

  • @vishalkank6853
    @vishalkank6853 Před 5 lety

    //tried one more (this returns the array)
    //------------------------------------------------------------
    const thingsNotDone = (todo) =>{
    let result= [ ]

    todo.filter((e) => {
    if(!e.isDone) return result.push(e.title)
    //console.log(e.title);
    })
    //console.log(result)
    return result
    }
    thingsNotDone(myTodo).forEach(e=>console.log(e))