DekGenius.com
Home
(current)
Dictionary
BOOKS
LYRICS
CHORD
SCRIPT & CODE EXAMPLE
Karaoke language
Search
Go
SCRIPT & CODE EXAMPLE
CODE EXAMPLE FOR JAVASCRIPT
js pass object property as a function parameter
let a = { foo: 123 }; a.foo // 123 a['foo'] // 123 let str = 'foo'; a[str] // 123
Source by stackoverflow.com #
PREVIOUS
NEXT
Tagged:
#js
#pass
#object
#property
#function
#parameter
ADD COMMENT
Topic
COMMENT
Name
9+2 =
Submit