29th April, 2020 Output

Overview

The first hacking marathon was a tedious an interesting one. I have never seen a day that short. Though before the hackathon I have been playing around with ruby on rails but still, i learned some new stuff.

What I learned

  1. How simple creating both test and development database can be with the script below rake db:setup . this will run the migration for both the test and the development as well.

  2. How to disable CORS in rails application. This can be achieved by adding the following code into your application.rb file located right inside your config directory:

 config.middleware.insert_before 0, Rack::Cors do

      allow do

        origins '*'

        resource '*', :headers => :any, :methods => [:get, :patch, :put, :delete, :post, :options]

      end

    end

Challenges

  1. The time was too short for the application.

  2. I needed to upgrade my node before npm could work properly.

  3. I forgot to prevent form submission default and that took a lot of my time.

Previous
Previous

CORS -May 04

Next
Next

23rd April, 2020 Output.