Sunday, April 5, 2020

Opinion: Rails vs. Django

 Opinion: Rails vs. Django


Disclaimer: This is an ongoing piece. I'm probably going to be adding to it as time goes on.

So I spent 9 weeks at LeWagon Coding Boot Camp learning Rails. It's a wonderful framework that is easy to learn on. However, prior to my time at LeWagon my experience in coding has all been from a mathematical perspective. Because of that I'm much more comfortable writing in Python, not because of the language syntax (though I do like Python syntax better), but because there are a lot of math abilities built into Python that don't exist in Ruby. Anyway, this is my breakdown of the differences between Rails and Django, even though I might be a novice in both.

Ruby on Rails and Python + Django are very similar. They both pretty much have an MVC model (Django is technically Model - View - Template, but not much different there), and both Python and Ruby are high level, dynamically typed, scripting languages that share a lot of common syntax.

MUCH faster to get started. I only need one terminal command to get started. This one command sets up the database, installs webpacker, and installs all the gems I might need. For this I like to use Le Wagon's boiler plate.

Django is much slower at getting started. It took me a good long while to figure out how to get my databases set up.

Django is also much more "segmented" than Rails. When you start a project you also need to create Apps. In most smaller projects you probably only use one app, but bigger projects should be using multiple apps. These apps are simply ways to organize your code better.

While Django may be more complicated to start off with, one thing that really impresses me is the Admin site. If you go to [your url]/admin you get a nice pre-made site to take care of the administration of the website. Here you can manage users, create posts, and other administrative tasks (not related to coding).

These are just my preliminary thoughts, I'll be adding more soon.

No comments:

Post a Comment

Opinion: Rails vs. Django

 Opinion: Rails vs. Django Disclaimer: This is an ongoing piece. I'm probably going to be adding to it as time goes on. So I spent ...