Merge pull request #2076 from freeCodeCamp/astro

Update Astro documentation (3.2.0)
pull/2077/head
Simon Legner 1 year ago committed by GitHub
commit 2a8f7745b4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -8,14 +8,16 @@ module Docs
end end
def get_type def get_type
return 'Guides' if slug.start_with?('contribute/')
return 'Guides' if slug.start_with?('guides/')
aside = at_css('aside') aside = at_css('aside')
a = aside.at_css('a[aria-current="page"]', 'a[data-current-parent="true"]') a = aside.at_css('a[aria-current="page"]', 'a[data-current-parent="true"]')
a.ancestors('details').at_css('summary').content a.ancestors('details').at_css('summary').content
end end
def additional_entries def additional_entries
return if slug.start_with?('guides/deploy') return [] if slug.start_with?('guides/deploy')
return if slug.start_with?('guides/integrations-guide') return [] if slug.start_with?('guides/integrations-guide')
at_css('article').css('h2[id], h3[id]').each_with_object [] do |node, entries| at_css('article').css('h2[id], h3[id]').each_with_object [] do |node, entries|
type = node.content.strip type = node.content.strip
type.sub! %r{\s*#\s*}, '' type.sub! %r{\s*#\s*}, ''

@ -16,7 +16,7 @@ module Docs
options[:skip_patterns] = [/tutorial/] options[:skip_patterns] = [/tutorial/]
self.release = '2.9.7' self.release = '3.2.0'
self.base_url = 'https://docs.astro.build/en/' self.base_url = 'https://docs.astro.build/en/'
self.initial_paths = %w(getting-started/) self.initial_paths = %w(getting-started/)

Loading…
Cancel
Save