Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Should I make my next app in Ruby on Rails or Node.js (meteor)? [closed]

I am conflicted. I haven't worked very much with ruby on rails or node.js (meteor.js/express.js) in the past, but have primarily used php. I'm moving away from it gradually but don't know if i should focus on working with either node or ruby more. Any ideas/opinions if I were starting out which language will be the future or more prominent over time and easier to develop productively? My apologies if i seem a bit rushed, but I am looking to make general web apps that can deploy to mobile as well. I see that meteor.js has this feature built in... but I am obviously open to recompiling for ruby on rails app to work on ios/android as well. Please don't criticize me, i'm just starting out with these two!

Thanks!

like image 875
George Avatar asked Dec 12 '22 00:12

George


2 Answers

I would put it down to what you want to achieve.

If your priority is on SEO stick to RoR. Meteor is still young and isn't reliable when it comes to SEO. There is an option to use PhantomJS to render web pages but its not very reliable, in the sense PhantomJS will crash often. The alternative is server side rendering which isn't officially supported yet.

That said, If your goal is to make a Company web app, or Mobile app or anything else really Meteor is the sure way to go.

You can pretty much achieve the same apps as on RoR with the slightly better UX since everything is based on one page. Npm packages can be used on Meteor as well as the atmospherejs repository which unbounds most limitations you could seek to accomplish.

Its also said that its fast to make apps on RoR. The same could be said for Meteor since its even faster (I've used both). The development experience is also smoother owing to

  • Hot code reloads when you change files
  • Reactive data sources (no meddling with ajax/get requests or sockets)
  • Isomorphic code - helps you create server and client side data models with one file instead of a ruby server file and a js client file. The same file can be shared on the client & the server
  • An extension of the isomorphism: easier handling of data between the client and server since both sides are javascript. No serialising or deserialising data back and forth. Very helpful with dates in particular (as with other data types too)
  • Easy user login system owing to the atmosphere packages.
  • Can easily convert a Meteor app into a mobile app for Android or iOS due to the official cordova support.
  • No trouble with setting up databases during the development phase as it runs together with the meteor dev environment per-app
  • Easier to test in a collaborative environment due to the free meteor deploy infrastructure (could argue Heroku does the same for RoR on this one - but it does need a bit of setup with the SSH keys whereas the meteor one doesn't even need you to visit a website to set it up)
  • Works on Windows, Linux and OS X. If you have a team project you can share code easily. Meteor also autoinstalls (no gem install) the packages and their dependencies automatically (yup no looking for libiconv as you would for certain gem headers). Most binaries are prebuilt on atmosphere.
  • No 'callback-hell' on the server side with Meteor owing to it using fibers. So you can have asynchronous or synchronous code.
  • Built on NodeJS so you can use NodeJS code/community support from answers like on Stackoverflow in your Meteor app. Best of both worlds.

Ruby is certainly nice and clean & easy to write. But so is Meteor. RoR is a bit more mature so more IDEs support it with autocompletion.

like image 68
Tarang Avatar answered Apr 09 '23 10:04

Tarang


I think you should try a little bit of both and go with the one that gets easier to you or feels more natural. Also, take into consideration, if there are people around you who can help you with one or another.

(There is a joke: the best Linux distro is the one that is running on the computer of your closest Linux-fan friend.)

I must say that Meteor is much younger than Rails, which means a smaller community (but still very active and supportive) and less number of developed 3rd party modules (but Meteor still offers more than 4000 3rd party packages on Atmosphere).

The development environment is very fleshed out for Meteor. Also tooling, like WebStorm, support Meteor. I personally developed multiple Meteor-related extensions for Vim and Sublime Text, too.

like image 34
imslavko Avatar answered Apr 09 '23 08:04

imslavko