Update Flow documentation (0.33)

pull/501/head
Thibaut Courouble 8 years ago
parent d42f30c86a
commit 6765343d13

@ -8,7 +8,7 @@ module Docs
at_css('h1').content = context[:root_title]
end
css('.docs-prevnext', '.hash-link', '.edit-page-link', '.edit-github').remove
css('.docs-prevnext', '.hash-link', '.edit-page-link', '.edit-github', 'a.hash', '.edit-page-block', 'a.show', 'a.hide').remove
css('table h1', 'table h2', 'table h3').each do |node|
table = node
@ -16,15 +16,15 @@ module Docs
table.replace(node)
end
css('a.anchor').each do |node|
node.parent['id'] = node['name']
css('a.anchor', 'a.hashref').each do |node|
node.parent['id'] = node['name'] || node['id']
end
css('.highlight').each do |node|
node.name = 'pre'
node.css('.gutter').remove
node['data-language'] = node.at_css('[data-lang]').try(:[], 'data-lang') || 'js'
node.content = node.content
node.content = node.content.strip
end
css('table.highlighttable').each do |node|

@ -9,6 +9,7 @@ module Docs
REPLACE_TYPES = {
'Quick Start' => 'Guides',
'User Guide' => 'Guides',
'The Basics' => 'Getting Started',
'apis' => 'APIs',
'components' => 'Components'

@ -1,18 +1,17 @@
module Docs
class Flow < React
self.type = 'react'
self.release = '0.22'
self.base_url = 'http://flowtype.org/docs/'
self.root_path = 'about-flow.html'
self.release = '0.33'
self.base_url = 'https://flowtype.org/docs/'
self.root_path = 'getting-started.html'
self.links = {
home: 'http://flowtype.org/',
home: 'https://flowtype.org/',
code: 'https://github.com/facebook/flow'
}
options[:container] = '.content'
options[:root_title] = 'Flow Documentation'
options[:only_patterns] = nil
options[:skip] = %w(coming-soon.html)
options[:attribution] = <<-HTML
&copy; 2013&ndash;2016 Facebook Inc.<br>

Loading…
Cancel
Save