js-object-to-json
js-object-to-json copied to clipboard
Remove "var/const/let myObject = " and ";" at end of object.
Lets say this is your JS object
constmyObject = {
"myPropertyA": "myValue",
"myPropertyB": "myValue"
};
The JS object minified
const myObject={"myPropertyA":"myValue","myPropertyB":"myValue"};
When I use this package, it does not remove the "constmyObject = " or the ";" linebreak at the end of the object.
Please allow for the automatic removal of the object name and the line break at the end of the object.