Q:

Rails 3 + Google Maps without a gem

I'm trying to integrate Rails 3 with Google Maps. I do not want to use a gem -- I just want to generate the array (hash?) used by the JavaScript API. I have this working manually, but not dynamically. I am using Haml, so the ERB examples are throwing me off.
Right now, my info comes out of Redis and is stuffed into a Ruby array in the JavaScript format Google Maps expects. I then try to access the array in my View. It almost-works, but there are no new lines -- it's one giant blob.
How do I fix it? Or what's a better way to do it?
Thanks in advance!

A:

This isn't really rails question. The gamps api is javascript - you do it on the client in javascript. 
It seems you have some data in redis, i'm assuming it's places you want to map. One way to get that data from redis on the server to javascript on the client is to deserialize it as a JSON string. Then serialize it on the client from the JSON string. Then you would just enumerate though the array of points and plot then using google provided maps api. 

