1
Hello, Someone could help me, I’m trying to remove the quotes from an array with two javascript positions. Something like:
["1", "2"]
Become:
[1, 2]
1
Hello, Someone could help me, I’m trying to remove the quotes from an array with two javascript positions. Something like:
["1", "2"]
Become:
[1, 2]
3
Do you want to convert all values into number? You can use the method map
of the array for this:
let lista = ["1", "2"].map( s => Number(s) );
Browser other questions tagged javascript
You are not signed in. Login or sign up in order to post.
Boa @bfavaretto!
– Pedro Costa