Skip to content

Commit

Permalink
Merge pull request #2341 from thewheat/fix-cordova-indents
Browse files Browse the repository at this point in the history
Fix Cordova indents with new clean html option
  • Loading branch information
simon04 authored Nov 17, 2024
2 parents 002eb72 + 63dd3dc commit 1da0de9
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
11 changes: 11 additions & 0 deletions lib/docs/filters/cordova/clean_html_core.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
module Docs
class Cordova
class CleanHtmlCoreFilter < Filter
def call
css('script', 'style', 'link').remove
xpath('descendant::comment()').remove
doc
end
end
end
end
1 change: 1 addition & 0 deletions lib/docs/scrapers/cordova.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ class Cordova < UrlScraper
code: 'https://github.com/apache/cordova'
}

html_filters.replace 'clean_html', 'cordova/clean_html_core'
html_filters.push 'cordova/entries', 'cordova/clean_html'

options[:container] = '.docs'
Expand Down

0 comments on commit 1da0de9

Please sign in to comment.