title: How to print a variable from js file in console?
body: <p>I am new to js and started using it with rails. I want to check what variable value is getting passed. I looked on internet and found the we have to use <code>console.log(var_name);' and it gets displayed in console window in</code>browser window` (<kbd>ctrl</kbd> + <kbd>shift</kbd> + <kbd>j</kbd>) in firefox. But when checked, nothing is displayed. Below is my code:</p>
  
  <p><code>customer.js.erb file</code></p>
  
  <pre>
  
  console.log(@customer);
  
  </pre>
  
  <p>But the above is not displaying anything in the console.</p>
  
  <p>Is it the right syntax? And the output is to be displayed in <code>browser window/console</code> or somewhere else?</p>