title: convert a string to object in javascript like regular expression
body: <p>I have the following variable</p>
  
  <pre><code>var characters = /[-()&amp;]/
  </code></pre>
  
  <p>and i have a string like this</p>
  
  <pre><code>var characters_string = "/[-()&amp;]/"
  </code></pre>
  
  <p>this string is result from array and join, because i need to add news variables, so, i need to convert characters_string to a object like characters because is not working with characters_string
  because when i use in this line</p>
  
  <pre><code>var filter_d = info.split(/[.,%]/)
  </code></pre>
  
  <p>and i use it like this</p>
  
  <pre><code>var filter_d = info.split(characters_string)
  </code></pre>
  
  <p>but i get error</p>
  
  <p>thanks</p>