Is there any online tool/ js library which generates immutable expressions with Object.assign and array methods by taking input as mutable expression? Ex:
var obj = {a:1};
//Input
var obj2 = obj;
//Output
var obj2 = Object.assign({}, obj);
EDIT: I found immutablejs makes it easy to work with immutable objects. But the syntax looks a bit difficult to adapt.