Is it possible to remove code between special comments with grunt uglify in javascript?
For example js code like this:
Source code:
var that = this;
var x=y;
//REMOVE-BEGIN
that.someCodeToBeRemoved();
that.someMoreCodeToBeRemoved();
//REMOVE-END
that.someFunctionCall();
What should be removed:
//REMOVE-BEGIN
that.someCodeToBeRemoved();
that.someMoreCodeToBeRemoved();
//REMOVE-END
You can use grunt-strip-code for this.
I don't think grunt uglify can do it.