No video

Javascript Nuggets - Reduce (object example)

  Рет қаралды 33,576

Coding Addict

Coding Addict

Күн бұрын

Пікірлер: 73
@thutanyan1381
@thutanyan1381 2 жыл бұрын
You are the best in React and Javascript. Thanks, Sir for your teaching.
@Shakeel714
@Shakeel714 3 жыл бұрын
Quality series from an awesome teacher to get really confident in web dev topics
@vscodeaddict6607
@vscodeaddict6607 Жыл бұрын
u r my kinda teacher i wanna learn more and more from u thank you
@vscodeaddict6607
@vscodeaddict6607 Жыл бұрын
your channel is very under-appreciated.
@CodingAddict
@CodingAddict Жыл бұрын
Oh, well. It is what it is :)
@PetroCAD
@PetroCAD 2 ай бұрын
You are the best teacher ....
@vishant898
@vishant898 3 жыл бұрын
you explain very well .2nd Example is complicated i will be watch again... make videos on slice ,splice and split
@christopherak4656
@christopherak4656 3 жыл бұрын
create a small sample of array objects for different languages and go over it again! it works. For the else statement it initialises the value to 1 before the count for the language if has not been counted yet that it why there is an empty object to set all the values to 1 before the count begins
@cesmorf5398
@cesmorf5398 2 жыл бұрын
you are a genius in teaching this, believe me, i see many people claiming to be the best course but the transmission method is far behind you
@emekaokonkwo626
@emekaokonkwo626 10 ай бұрын
Man your explanation is stellar.... most examples of reduce are using numbers... this is really helpful sir.. cheers
@likojhyu
@likojhyu 2 жыл бұрын
This vídeo is really good 👍 Reduce's power is amazing, we can implement very interesting tasks. Thank you.
@jydev8073
@jydev8073 3 жыл бұрын
Waiting for next.js tutorial from Coding Addcit :)
@pitbul67204
@pitbul67204 3 жыл бұрын
Another great JS nugget thanks for all the great tutorials
@anandhinamasu9138
@anandhinamasu9138 10 ай бұрын
Thank you so much Jhon, to make it every topics so easy to grap using real time project example, you are my best coach❤
@eq6P6jW4bM8
@eq6P6jW4bM8 3 жыл бұрын
As always, amazing content, thank you so much! :)
@queerly__coded
@queerly__coded 2 жыл бұрын
Hey thanks for this John. I've been working on a kata for a while trying to figure out how I could use reduce to return only unique values from an array of objects into a new object and even though I had to fandangle this a bit in my logic, your direction gave me the first part of the solution to my puzzle. I got such a rush when my console.log returned what I had hope for. tyvm ~Hope
@leonbelokopytov
@leonbelokopytov Жыл бұрын
On 10:19 its also possible to use the + operator to convert a string to a number like so +cartTotal.toFixed(2) Great video, thank you (:
@CodingAddict
@CodingAddict Жыл бұрын
Great tip!
@lukaszszmyd8767
@lukaszszmyd8767 2 жыл бұрын
Thank's John, great content
@Auditor1337
@Auditor1337 2 жыл бұрын
This one was so cool, I learnt a ton
@CodingAddict
@CodingAddict 2 жыл бұрын
Thank you!
@ferhatsunaycansev106
@ferhatsunaycansev106 3 жыл бұрын
perfect videos if we want async await and promise videos maybe they are also unclear : ) thanks again
@bit.blogger
@bit.blogger 3 жыл бұрын
I get fetch is not defined can you help me?
@khushiujjawal3668
@khushiujjawal3668 3 жыл бұрын
global.fetch = require("node-fetch");
@irsyadrdp
@irsyadrdp 2 жыл бұрын
@@khushiujjawal3668 Thank you !!!
@lifeisbeautifu1
@lifeisbeautifu1 2 жыл бұрын
Thank you❤
@AnkitPatel04
@AnkitPatel04 2 ай бұрын
Can you tell me what is this syntax "total[language]" I am confused
@ozankurucu6261
@ozankurucu6261 2 жыл бұрын
Thank you!!
@sayalikandhare7294
@sayalikandhare7294 Жыл бұрын
Excellent video!!! I was wondering how you got the console.log() output to show up in your VS CODE?
@CodingAddict
@CodingAddict Жыл бұрын
it's vs code extension called quokka.js (free version)
@CoderDmitri
@CoderDmitri 3 жыл бұрын
John.... JOHN... Notice MEEEEE! You are MY HERO... !
@furyofonethousandgods2926
@furyofonethousandgods2926 2 жыл бұрын
Hey John, do you know why I keep getting "fetch is not defined in VSCODE". I even copy pasted your code and still says fetch is not defined. It's like I'm missing a package or something but I thought fetch was built in
@CodingAddict
@CodingAddict 2 жыл бұрын
It's probably something to do with your settings.
@shellbot972
@shellbot972 2 жыл бұрын
got it resolved by installing node-fetch version 2 : npm install node-fetch@2
@brutalv4
@brutalv4 3 жыл бұрын
Great video! By the way, what's the extension for VS Code that shows the function results? Thank you!
@CodingAddict
@CodingAddict 3 жыл бұрын
quokka.js
@olegg1082
@olegg1082 3 жыл бұрын
This must be trolling at this point. This question is being asked and answered under literally every video and often multiple times.
@brutalv4
@brutalv4 3 жыл бұрын
@@olegg1082 no trolling at all =)
@deveighteen6302
@deveighteen6302 2 жыл бұрын
@@olegg1082 you meant "trending" ?
@deveighteen6302
@deveighteen6302 2 жыл бұрын
I guess he meant "trending"
@spondoolie6450
@spondoolie6450 Жыл бұрын
I came for the tacos and burritos
@olegg1082
@olegg1082 3 жыл бұрын
Hi, thanks for another amazing video! Can you maybe clarify what you mean by "dynamic functionality". When you talk about the input array you also said it's not going to be dynamic. Could you explain how dynamic would work? Or do you cover that in some other videos?
@CodingAddict
@CodingAddict 3 жыл бұрын
Hi, it means that in this case we have a static value of cart. In react project cart value is changing when we click buttons but the functionality to count the totals is still the same (our function)
@sairfan06
@sairfan06 3 ай бұрын
What vscode extension was used here to show result on each row?
@abelmarkos5753
@abelmarkos5753 3 жыл бұрын
great video it will be realy amayzing if you could find time to do some back end tuttorial like node.js and mongodb it will help in increasing the coding addict community and i hope the day come when this chaneal hit the 1million subscriber
@piotrszczesniak
@piotrszczesniak Жыл бұрын
Hello! Thank you for this tutorial. Really useful. I am just wondering how to count number of items and "bundle" them when they are the same increasing amount...
@user-ct5oo3do7b
@user-ct5oo3do7b 2 жыл бұрын
response.json() / res.json() // Despite the method being named json(), the result is not JSON but is instead the result of taking JSON as input and parsing it to produce a JavaScript object. "Parse as JSON" means analyze it in JSON format - but JS is returned
@RokSlana
@RokSlana Жыл бұрын
Nice!
@aliss14
@aliss14 2 жыл бұрын
Man, How didn't I know you earlier ;(
@ivanyosifov2629
@ivanyosifov2629 3 жыл бұрын
Can we also go over *forEach* in this series just for the sake of completeness?
@CodingAddict
@CodingAddict 3 жыл бұрын
Hey Ivan, emm we will see, at the moment I have only one more planned
@Fatima-ie5kj
@Fatima-ie5kj 3 жыл бұрын
What if i want to get unique object key's from arrays of objects is it possible to do this in reduce method? Kindly guide me thankyou
@mrkhoros
@mrkhoros 3 жыл бұрын
what extension are you using for the alarts?
@CodingAddict
@CodingAddict 3 жыл бұрын
If you mean console.log - quokka
@cornel9651
@cornel9651 2 жыл бұрын
Hey man! Thanks for sharing this...also whats that adon that shows in vscode what a function rerurns or console.logs? Thanks
@CodingAddict
@CodingAddict 2 жыл бұрын
extension quokka.js
@sharku111
@sharku111 2 жыл бұрын
|| 1 ? It is very clever.
@great9640
@great9640 Жыл бұрын
this is a pretty difficult topic for me to grasp
@relationtips4725
@relationtips4725 3 жыл бұрын
hey what is that const{amount, price} can u explain me to please
@askarp6485
@askarp6485 2 жыл бұрын
Thanks sir, it’s a great video, what extension are you using to show the console log output?
@CodingAddict
@CodingAddict 2 жыл бұрын
quokka.js
@charmz973
@charmz973 3 жыл бұрын
woow!!!
@SeniorJuniorDeveloper
@SeniorJuniorDeveloper 2 жыл бұрын
When you add parseFloat() at 10:18 it breaks toFixed(2) and makes cartTotal = 5599.9 (line 43): cartTotal = parseFloat(cartTotal.toFixed(2)) But if I do 'cartTotal = parseFloat(cartTotal).toFixed(2)' then cartTotal = 5599.90 in fact, passing any number into parseFloat(cartTotal.toFixed(number)) from 1 - 11 will result in 5599.9, while passing any number greater than 12 will result in 5599.90 Why is that?
@CodingAddict
@CodingAddict 2 жыл бұрын
Hmm. I'm really not sure :)
@Do-qr3jt
@Do-qr3jt Жыл бұрын
Hi, what kind of extension which shows answer ,,, please,,,
@CodingAddict
@CodingAddict Жыл бұрын
quokka.js
@aatomaszewski
@aatomaszewski 3 жыл бұрын
cart array, just to not rewrite it :) ``` const cart = [ { title: "Samsung Galaxy S7", price: 599.99, ammount: 1 }, { title: "google pixel", price: 499.99, ammount: 2 }, { title: "Xaiomi Redmi Note 2", price: 699.99, ammount: 4 }, { title: "Xaiomi Redmi Note 5", price: 399.99, ammount: 3 }, ]; ```
@MultiAlifarooq
@MultiAlifarooq 3 жыл бұрын
The one who dislike the video will be surely from your family.
@CodingAddict
@CodingAddict 3 жыл бұрын
why?
@olegg1082
@olegg1082 3 жыл бұрын
What do you mean?
@MultiAlifarooq
@MultiAlifarooq 3 жыл бұрын
It was a sarcasm....You will not get because mostly in Asian countries family members like cousin don't appreciate your efforts..I m learning a lot from you...
@CodingAddict
@CodingAddict 3 жыл бұрын
Ha ha. Thank you for info
Жыл бұрын
Killer language decision: language && (total[language] = total[language] + 1 || 1); //
Javascript Nuggets - Array.from
16:52
Coding Addict
Рет қаралды 23 М.
Javascript Nuggets - Async / Await
16:46
Coding Addict
Рет қаралды 24 М.
Kind Waiter's Gesture to Homeless Boy #shorts
00:32
I migliori trucchetti di Fabiosa
Рет қаралды 15 МЛН
Javascript Nuggets - Filter and Find
15:14
Coding Addict
Рет қаралды 34 М.
Javascript Nuggets -  Promises Example
13:19
Coding Addict
Рет қаралды 18 М.
Reduce: 10 Different Examples. JavaScript Fundamentals.
26:57
Leigh Halliday
Рет қаралды 28 М.
Billionaire Bill Gates Guesses Grocery Store Prices
4:20
TheEllenShow
Рет қаралды 40 МЛН
I Never Want To Build Authentication Any Other Way
2:03:20
Elliott Chong
Рет қаралды 20 М.
Javascript Nuggets - Callback Functions
13:00
Coding Addict
Рет қаралды 23 М.
Learn Blazor: Build an Inventory Management System in .NET 8
2:17:34
Object keys, values, and entries methods
7:15
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 96 М.