Skip to content

Commit

Permalink
Remove unnecessary :require option from Gemfile example
Browse files Browse the repository at this point in the history
`Bundler.require` automatically loads lib/rack/cors.rb even if there is no :require option.

This can be verified by the following code:

```rb
require "bundler/inline"

gemfile do
  source "https://rubygems.org"

  gem "rack-cors"
end

puts defined?(Rack::Cors)
```

```
$ ruby example.rb
constant
```

cf. https://guides.rubygems.org/name-your-gem/
  • Loading branch information
r7kamura authored and cyu committed Mar 25, 2019
1 parent 30f63a7 commit c62c484
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Install the gem:
Or in your Gemfile:

```ruby
gem 'rack-cors', require: 'rack/cors'
gem 'rack-cors'
```


Expand Down

0 comments on commit c62c484

Please sign in to comment.