Congelar objetos con javascript para evitar la mutación ['ESP','ENG']
En javascript se puede utilizar métodos de los objetos para realizar ciertas mutaciones una de las ventajas que tiene javascript es que los valores internos de los objetos puede ser fácilmente editables pero en algunos casos no deseamos que se usan ese tipo de cosas por suerte existe un método nativo de objetos para congelarlos.
In javascript you can use object methods to perform certain mutations. One of the advantages that javascript has is that the internal values of the objects can be easily edited, but in some cases we do not want that type of thing to be used, luckily there is a method native objects to freeze them.
![](https://images.hive.blog/DQmeVWxCh6Ytx3YKh3fCDr3LEoooRsDwdHhc6fscS7aRimT/freze.jpg)
The only thing this method does is freeze the object so that none of that internal data can be altered. The only way to be able to edit this object again is from where it was initially created where its primitive values are or by unfreezing this object with the method assign.
![](https://images.hive.blog/DQmXgWewMRWsJRfiX3nHM877DCsSeT7unSTUXPbNqayDjfh/freze1.jpg)
0
0
0.000
Nice blog, you must be pretty experience at this friend 🤔💯
I love be a developer and share My knowledge with others too
That's so thoughtful brother
Congratulations @dobro2020! You have completed the following achievement on the Hive blockchain And have been rewarded with New badge(s)
Your next target is to reach 21000 upvotes.
You can view your badges on your board and compare yourself to others in the Ranking
If you no longer want to receive notifications, reply to this comment with the word
STOP