Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

constant values javascript

Constant values can be mutated, they just can't be reassigned

const arr = [1,2,3]

// doesn't work:
arr = [1,2,3,4]

// works:
arr.push(4)
 
PREVIOUS NEXT
Tagged: #constant #values #javascript
ADD COMMENT
Topic
Name
5+6 =