New Beginnings and Life Perspectives


When Opportunity Knocks...

Many-to-Many Relationships - The Power of Making the Right Connections

Of all the options Rails gives us to make associations between models, the ones that have intrigued me the most in recent weeks have been many-to-many relationships. There are two ways to declare many-to-many relationships - has_and_belongs_to_many and has_many :through. So, what’s the difference between the two methods? How do we choose one method over another?


Final Rails Project - Handling the Organized Chaos of Life and Code

As I complete my final Rails project, I reflect upon how far I’ve come. It took awhile to get here what with life sometimes getting in the way - I got sick, my kids got sick, my husband got sick. Then my house sustained extensive water damage, putting us through what seems like a very long restoration period (it’s been about 3.5 months and we’re not done yet). Basically anything that could have gone wrong, appeared to go wrong. And that’s not adding basic duties and events of life in general. Okay, now that I’ve gotten that out of my system let’s talk about my final project.


The `localhost` With the Most

In the process of creating my final Rails project, I encountered a situation that was unexpected. I thought I was on a roll while trying to implement omniauth authentication credentials for a Google strategy. My code was correct (confirmed by references found online), and all of my files from config/initializer/omniauth.rb to the route.rb file to the .env file, seemed to have lined up quite nicely. Then, I tried to log in to my application using omniauth authentication. Well, let’s just say my confidence took a nosedive.


Sinatra and the Magic of `params` - You Make Your Own Magic

When the methods we use seem to sprinkle a little bit of magic to make things happen, we become excited by the possibilities. For me, params is one of those things that seem to provide a certain level of je ne sais quoi. But, are params really magic?


Sinatra Final Project - Onward and Upward

For our final Sinatra project we were supposed to pick a collection of something we care about and build a CRUD (Create, Read, Update, Destroy) application that incorporates as many of the lessons that we learned in the SQL/Rack/ActiveRecord/Sinatra section. Since my daughter had a lot to do with my CLI Gem Project, this time I picked something that my son is obsessed with - CARS. Blame it on the Disney Cars Trilogy or the fact that he loves any and all cars, but I thought it would be cool to create an application that would allow users to create a collection of their vehicles. I would imagine that eventually this type of collection could be useful for someone in the rental car business or some kind of ride sharing service or someone that just likes to collect cars. In any case, this could be built upon if necessary and would give me a good foundation for a future project.