Комментарии:
I didn't understand why below code was used?
setCountries(typeof value === "string" ? value.split(",") : value);
why not just this?
setCountries(value);
Many thanks. Great explanation.
ОтветитьMuito bom, Parabéns pelos seus vídeos.
ОтветитьCan someone tell me how the line executes?
typeof value === "string" ? value.split(",") : value
I didn't understand the execution. If I select option India, I get object as 0:"IN". Now it compares typeof value === string which is false. Now it assigns the second option value into countries. but how the value appends to the string array here? As far as I know to add new element into an array arr, we do setArr([...arr, value]); Why aren't we doing the same over here? What is the use of split(",") here?
How to make dropdown list sticky when i scroll up and down, it moves ?
Ответитьyour first option was india.. thanks
Ответитьif i need treeselect, how to custom it,thanks
ОтветитьHow will I work with onFocus event in select input? İt is not working with select input while working with others type of input.
ОтветитьAmazing job!
Ответитьhow to add search filter ???
Ответитьhow if select using optgroup?
ОтветитьHow we can make this field searchable? please tell !!
ОтветитьHello, Your tutorials are excellent.
I follow the same steps shown in the video, but in the console, logs country is printing twice.
What is the reason behind this?
Amazing job love your work. Why did you choose to go with TexField over Select component?
Ответитьas long as typescript is not necessity to learn mui, it is better to use react in tutorial.
ОтветитьHow to implement this in a react class component?
Ответитьis there a way to make cascading select fields?
ОтветитьsetCountries(typeof value === "string" ? value.split(",") : value);
Why giving value in else condition?
setCountries(typeof value === "string" && value.split(","));
Why we can't use this?
What is the difference between the Select component and the TextField field component used like this?
ОтветитьHI there , i want to a know how to set dynamic value in select button using map and fetch that data which is selected using event how could i can do this could you explain
Ответить