README.md in onebox-1.5.20 vs README.md in onebox-1.5.21

- old
+ new

@@ -85,11 +85,11 @@ Adding Support for a new URL ============================ 1. Check if the site supports [oEmbed](http://oembed.com/) or [Open Graph](https://developers.facebook.com/docs/opengraph/). - If it does, you can probably get away with just whitelisting the URL in `Onebox::Engine::WhitelistedGenericOnebox`. + If it does, you can probably get away with just whitelisting the URL in `Onebox::Engine::WhitelistedGenericOnebox` (see: [Whitelisted Generic Onebox caveats](#user-content-whitelisted-generic-onebox-caveats)). If the site does not support open standards, you can create a new engine. 2. Create new onebox engine ``` ruby @@ -174,24 +174,40 @@ # in lib/onebox/engine.rb require_relative "engine/name_onebox" ``` +Whitelisted Generic Onebox caveats +================================== + +The Whitedlisted Generic Onebox has some caveats for it's use, beyond simply whitelisting the domain. + + 1. The domain must be whitelisted + 2. The URL you're oneboxing cannot be a root url (e.g. `http://example.com` won't work, but `http://example.com/page` will) + 3. If the oneboxed URL responds with oEmbed and has a `rich` type: the `html` content must contain an `<iframe>`. Responses without an iframe will not be oneboxed. + + Installing ========== Add this line to your application's Gemfile: - gem "onebox", "~> 1.2" + gem "onebox" And then execute: $ bundle Or install it yourself as: $ gem install onebox + +Issues / Discussion +=================== + +Discussion of the Onebox gem, its development and features should be done on +[Discourse Meta](https://meta.discourse.org). Contributing ============ 1. Fork it