Delete all occurrences of a character in javascript code


I have a problem with the code that I am working on, what happens is that it has bars that were previously placed for the security of the company.

Now we are updating some details of the page but delete one by one the



Is it a bit delayed, is there a tool that allows you to remove that character from the code?

!function(a,b){\"object\"==typeof module&&\"object\"==typeof module.exports?module.exports=a.document?b(a,!0):function(a)

Manually it would be something like this:

!function(a, b) {
    "object" == typeof module && "object" == typeof module.exports ? module.exports = a.document ? b(a, !0) : function(a) {
        if (!a.document)
            throw new Error("jQuery requires a window with a document");
        return b(a)

What command / tool can I use to remove "/" ?

asked by Jhosselin Giménez 02.05.2017 в 03:36

1 answer


Based on the comments, in this case we have the git tool, regardless of the version of Windows git contains variants of many of the GNU / Linux commands.

For this case, we can then use the sed command, which is used to find and replace data in a file.


You have to reach the directory where your code is located:

cd c:\directorio\de\archivo\


We proceed to execute the sed command, like this:

sed -i 's/\"/"/g' archivo.js

What we are indicating to the command, we can divide it into 3 parts:

  • -i this parameter indicates that the change to be made must be saved in the same file.
  • 's/\"/"/g' this is the search / replacement pattern, that is, search for all occurrences of \ and replace them with " .
  • archivo.js this is the file on which the change will be made.
  • More information regarding the use of thirst: here .

    answered by 02.05.2017 / 04:28