[LRUG] opal-rails
Riccardo Tacconi
rtacconi at gmail.com
Sat May 4 04:33:19 PDT 2013
Thanks for your reply,
What you say makes sense. I am not much interested of querying a DB from
the views, but I think that web development is becoming more complex since
we write applications using a backend framework, Rails, and a frontend JS
framework. Using the same language could make things easier, but I fear
Opal could bring more cons than pros.
ClojureScript is an interesting option, I will have a look. I was looking
for an equivalent of CoffeScript and I found Opal, but it does not seems
the same thing.
Ideally I would like to see in the future another letter added to MVC,
where we could have a declarative code to make our apps having similar
features of frontend frameworks. It is a bit difficult to me to explain
what I mean in a clear way.
On 4 May 2013 11:34, Steven Deobald <steven at c42.in> wrote:
> Hi Riccardo,
>
> I haven't used Opal in anger but I would caution you against the holy
> grail of shared client/server code. I have written a reasonable amount of
> Clojure/ClojureScript, which in theory makes this possible, but it's really
> never come up as an attractive solution to any problem I've had. The sort
> of code I've shared between the client and server in the past tends to be
> small data-formatting functions, aggregations, and transformations -- all
> of which are functional.
>
> I've never used Meteor, so a grain of salt is required, but I'm not sure I
> understand the appeal of accessing the database or other services directly
> from your views.
>
> On a weirdly related note, if you want to combine ClojureScript and Rails
> instead, there exist a couple projects for getting ClojureScript into the
> Rails asset pipeline:
>
> https://github.com/yokolet/clementine
> https://github.com/nicholasbs/clojurescript-rails
>
> My reasons for choosing ClojureScript over CoffeeScript in the past are
> simply due to the power and functional nature of the language. Obviously
> there's still a mental gap between server and client code.
>
>
> Steven Deobald
> C42 -- www.c42.in -- www.rubymonk.com
>
>
> On 3 May 2013 16:24, Riccardo Tacconi <rtacconi at gmail.com> wrote:
>
>> Hi guys,
>>
>> Have you every thought to use Ruby in your Rails project instead of
>> CoffeeScript to write your Javascript? I just found opal-rails which allows
>> to develop Javascript with Ruby:
>>
>> https://github.com/opal/opal-rails
>>
>> I am not sure about the maturity of the project but this could allow us
>> to extend Rails to work, if needed, as the Meteor Framework:
>>
>> client? do
>> # use jquery
>> # use angular.js
>> end
>>
>> server? do
>> # back end stuff
>> end
>>
>> What do you think?
>>
>> I see that is also possible to use Ruby on node.js:
>> https://github.com/opal/opal-node#readme.
>>
>> Cheers,
>>
>> --
>> Riccardo Tacconi
>> Ruby on Rails and PHP development - System Administration
>> VIRTUELOGIC LIMITED <http://www.virtuelogic.net/>
>>
>> http://github.com/rtacconi
>> http://riccardotacconi.blogspot.com
>> http://twitter.com/rtacconi
>>
>> _______________________________________________
>> Chat mailing list
>> Chat at lists.lrug.org
>> http://lists.lrug.org/listinfo.cgi/chat-lrug.org
>>
>>
>
--
Riccardo Tacconi
Ruby on Rails and PHP development - System Administration
VIRTUELOGIC LIMITED <http://www.virtuelogic.net/>
http://github.com/rtacconi
http://riccardotacconi.blogspot.com
http://twitter.com/rtacconi
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lrug.org/pipermail/chat-lrug.org/attachments/20130504/58a46b34/attachment-0003.html>
More information about the Chat
mailing list