|
|
|
@ -1,9 +1,7 @@
|
|
|
|
|
module Docs
|
|
|
|
|
class Relay < UrlScraper
|
|
|
|
|
self.type = 'simple'
|
|
|
|
|
self.release = '10.1.0'
|
|
|
|
|
self.base_url = 'https://relay.dev'
|
|
|
|
|
self.root_path = 'index.html'
|
|
|
|
|
self.root_path = 'introduction-to-relay'
|
|
|
|
|
self.links = {
|
|
|
|
|
home: 'https://relay.dev/',
|
|
|
|
|
code: 'https://github.com/facebook/relay'
|
|
|
|
@ -11,19 +9,7 @@ module Docs
|
|
|
|
|
|
|
|
|
|
html_filters.push 'relay/entries', 'relay/clean_html'
|
|
|
|
|
|
|
|
|
|
options[:only] = [
|
|
|
|
|
'/docs/en/graphql-in-relay',
|
|
|
|
|
'/docs/en//relay-environment',
|
|
|
|
|
'/docs/en/network-layer',
|
|
|
|
|
'/docs/en/query-renderer',
|
|
|
|
|
'/docs/en/fragment-container',
|
|
|
|
|
'/docs/en/refetch-container',
|
|
|
|
|
'/docs/en/pagination-container',
|
|
|
|
|
'/docs/en/mutations',
|
|
|
|
|
'/docs/en/subscriptions',
|
|
|
|
|
'/docs/en/relay-store',
|
|
|
|
|
'/docs/en/fetch-query'
|
|
|
|
|
]
|
|
|
|
|
options[:skip] = %w(videos)
|
|
|
|
|
|
|
|
|
|
options[:attribution] = <<-HTML
|
|
|
|
|
© 2020–present Facebook Inc.<br>
|
|
|
|
@ -34,5 +20,21 @@ module Docs
|
|
|
|
|
get_latest_github_release('facebook', 'relay', opts)
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
version '10' do
|
|
|
|
|
self.release = '10.1.0'
|
|
|
|
|
self.base_url = "https://relay.dev/docs/en/"
|
|
|
|
|
# For some reason, the most-recent version isn't available at a versioned URL
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
version '9' do
|
|
|
|
|
self.release = '9.1.0'
|
|
|
|
|
self.base_url = "https://relay.dev/docs/en/v#{self.release}/"
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
version '8' do
|
|
|
|
|
self.release = '8.0.0'
|
|
|
|
|
self.base_url = "https://relay.dev/docs/en/v#{self.release}/"
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
end
|
|
|
|
|
end
|
|
|
|
|