Creating and Using JavaScript Symbols
ฝัง
- เผยแพร่เมื่อ 26 ก.พ. 2020
- In this tutorial we will look at how to create them, how to refer to them and for what purposes you might use a symbol that you have created.
Would you like to help keep this channel going?
allthingsjavascript.com/contri...
Access to EVERY course for one low price: allthingsjavascript.teachable...
Access to EVERY course (get 2 months free): www.skillshare.com/r/profile/...
Courses offered on Udemy at a discount (access from my site): allthingsjavascript.com/course...
For more resources on JavaScript:
www.allthingsjavascript.com
#javascript #AllThingsJavaScriptLLC
This explanation of symbols finally made click. Thanks!
Mr, thank you Very much!
Thank you so much for making a video on symbols.. I have only requested for symbols few weeks ago..
I also remember reading that request in comments section.
Well explained. Thank you, sir.
Perfect explanation! This is the video that helped me grasp the very concept of symbols and their main usage. Thank you!
Glad it was helpful!
Great explanation and examples!
Thank you Steve! 🚀
Glad it helped!
Salut et merci pour TOUT :)
Thank you for this perfect video
Glad you liked it!
thank you so much for this thorough explanation! Liked & sub'd!
thanks Steve for putting these together.. i have quick query... why do keys in objects/dictionaries(Python) need to be hashable. what does that mean... would you pls, when you can, create a video that speaks to this subject of hash maps. thank you once again.
Will add it to the list.
I like the pace of this. I am confused by the common variable name of 'symb1' at line 1 and [symb1] inside object on line 6. Do you first have to make a symbol before you can use it as an object property, or is it just coincidence you named them the same.
In other words, could you have just the same done [dog] inside of the object, or do you have to explicitly create it first? ... const dog = Symbol();
At line 1 I create a symbol and store it in symb1. Then I use that symbol inside the object as the key for that key/value pair.
does uuid and symbols both are same?
Not sure if symbols use uuid, but it is the same idea.
Simple Q where we can use it?give me idea.
You would use a symbol as the property for an object similar to how you use a string for that purpose.
If interviwer ask me why you would use it give me an scanerio requirement.
Okay I need more help I'm just teaching myself. I don't know if I'm asking the right question...by symbols. I mean a video explaining these ( ) and " " and [ ] and //.
These can be used for different things in JavaScript. For example, () can be used to group, to invoke a function, to define a method. So it depends on where it is used in the code. [] also have multiple applications. I would approach it by learning how to do different things with JavaScript.
What is your next coding video? Keep it up! Would you like to be TH-cam friends?
spammer
thanks, i think this must be one of the most useless programming functions i've ever encountered
Well, the point is: its worthless waste your time in it hahaha
What a bad name for this useless function