You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+6-1Lines changed: 6 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1164,7 +1164,12 @@ No Existe = false
1164
1164
Podemos eliminar un elemento con la propiedad DELETE */
1165
1165
console.log(carrito.delete('Producto A'));
1166
1166
1167
-
1167
+
/*TRANSFORMAR LISTA A ARRAY
1168
+
Si tenemos la necesidad de transformar nuestra LISTA a un ARRAY utilizaremos el ITERADOR ... , el cual simplifica la transformación.
1169
+
*/
1170
+
constarrayCarrito= [...carrito];
1171
+
console.log(arrayCarrito);
1172
+
/* Ya tenemos nuestro array con su respectivo 'key' 'value', podemos ver que al imprimir el array en sus funciones de __proto__ ya cuenta las que le corresponden por ser un array a diferencia de cuando es un SET*/
0 commit comments