My final goal is to create an app in xdk that interacts with rails. If nobody knows exactly how it works but give a light on how to access sqlite with ruby and javascript already helps a lot. I have some doubts about the correct way to do this. For example the ideal is to create an initialize in rails? Can not access just with javascript because of the right security? Is there gem for this? Thank you.