What's the difference between Object.seal and Object.freeze methods?
The difference between these two methods is that when we use the Object.freeze
method to an object, that object's properties are immutable meaning we can't change or edit the values of those properties. While in the Object.seal
method we can change those existing properties.