title: Javascript Link in Laravel
body: <p>I am passing a form via Javascript to a view in Laravel. However, the resulting link is useless. How I can implement the route using Javascript such as the result is <code>localhost:8000\products.search</code> not the literal <code>{{ route('products.search') }}</code>?</p>
  
  <pre><code>var msg ='&lt;form class=\"navbar-form navbar-right\" action=\"{{ 
  route(\'products.search\') }}\" method=\"get\"&gt;';
  </code></pre>