Property descriptors, freeze and seal
Comes up in: JavaScript
This concept is being written. It gets the full five steps — explanation, predict, interview angle, practice with tests, and review cards. Here is exactly what it will cover, so you can study it elsewhere in the meantime.
What it covers
- writable/enumerable/configurable
- accessor properties
Object.definePropertyfreeze(shallow) vssealvspreventExtensions- property order rules (integer keys first)
Words you will know
What you will practise
- deepFreeze
- predict key order
Interview questions this answers
- Does
Object.freezemake an object deeply immutable? - In what order are object keys iterated?