Unified · Split
| @@ -45,6 +45,11 @@ module Docs · 44 unmodified lines | |||
| 45 | node.remove if node.content.include?('#[must_use]') | 45 | node.remove if node.content.include?('#[must_use]') |
| 46 | end | 46 | end |
| 47 | 47 | ||
| 48 | css('details').each do |node| | ||
| 49 | node.css('summary:contains("Expand description")').remove | ||
| 50 | node.before(node.children).remove | ||
| 51 | end | ||
| 52 | |||
| 48 | css('a.header').each do |node| | 53 | css('a.header').each do |node| |
| 49 | unless node.first_element_child.nil? | 54 | unless node.first_element_child.nil? |
| 50 | node.first_element_child['id'] = node['name'] || node['id'] | 55 | node.first_element_child['id'] = node['name'] || node['id'] |
| @@ -3,7 +3,7 @@ · 2 unmodified lines | |||
| 3 | module Docs | 3 | module Docs |
| 4 | class Rust < UrlScraper | 4 | class Rust < UrlScraper |
| 5 | self.type = 'rust' | 5 | self.type = 'rust' |
| 6 | self.release = '1.53.0' | 6 | self.release = '1.54.0' |
| 7 | self.base_url = 'https://doc.rust-lang.org/' | 7 | self.base_url = 'https://doc.rust-lang.org/' |
| 8 | self.root_path = 'book/index.html' | 8 | self.root_path = 'book/index.html' |
| 9 | self.initial_paths = %w( | 9 | self.initial_paths = %w( |