title: Efficient way to Pass variables from PHP to JavaScript
body: <p>From time to time I have to pass some variables from PHP to JS script.
  For now I did it like this:</p>
  
  <pre><code>var js-variable = "&lt;?php echo $php-variable; ?&gt;";
  </code></pre>
  
  <p>But this is very ugly and I can't hide my JS script in .js file because it has to be parsed by PHP. What is the best solution to handle this? </p>