cordova: do not clean  

Do not use core/clean_html filter.
pull/2341/head
Simon Legner 2 months ago
parent e68269b3f4
commit 63dd3dce70

@ -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

@ -8,7 +8,6 @@ module Docs
xpath('./text()', './/text()[not(ancestor::pre) and not(ancestor::code) and not(ancestor::div[contains(concat(" ", normalize-space(@class), " "), " prism ")])]').each do |node|
content = node.content
next unless content.valid_encoding?
next if context[:clean_html_maintain_nbsp] && !content.index(" ").nil?
content.gsub! %r{[[:space:]]+}, ' '
node.content = content
end

@ -8,10 +8,10 @@ module Docs
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'
options[:clean_html_maintain_nbsp] = true
options[:skip] = %w(index.html)
options[:fix_urls] = ->(url) do

Loading…
Cancel
Save