Is it possible to call a ruby method inside javascript? One way of implementing it is via ajax calls, but is there a way I can embed that ruby function inside the js file and call it just like calling any other js function?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
No. Not without using Silverlight Dynamic Languages (or similar plugin) to act as a vessel for the language.
Even then, it’s not embedding into JS, it’s just adding another possible language to the
<script>tag.