Exam4Training

Which method should be used to execute this business requirement?

A developer creates an object where its properties should be immutable and prevent properties from being added or modified.

Which method should be used to execute this business requirement?
A . Object.const()
B . Object.eval()
C . Object.lock()
D . Object.freeze()

Answer: D

Exit mobile version