Skip to content

Latest commit

 

History

History
29 lines (24 loc) · 1.04 KB

README.md

File metadata and controls

29 lines (24 loc) · 1.04 KB

deep-freeze-es6

deep freeze, works with Map and Set

Quick example

import { deepFreeze } from 'deep-freeze-es6';

const obj = deepFreeze({
  map: new Map([
    [1, 1],
    [2, 2],
  ]),
});
obj.map.clear(); // Error: map is read-only