I am trying to pass a rails array to a javascript function. The function will then use the array values in javascript so I need to keep it an array.
Here is how I am
If you're using HAML, you can just do this:
var js_array = #{object};