The Difference Between load, autoload, require, and require_relative in Ruby 📖

Uncategorized

The Difference Between load, autoload, require, and require_relative in Ruby 📖

URL: https://www.akshaykhot.com/difference-between-load-autoload-require-in-ruby/
Type: article
Domain: akshaykhot.com

Excerpt: An oldy but goodie source of confusion in Ruby. Author says: "Loading external files can get tricky in Ruby, but it doesn't have to be. This post explains the usage of Ruby's load, require, and require_relative methods, and when to use each."