Explorar o código

Update Electron documentation (20.0.0)

Simon Legner %!s(int64=3) %!d(string=hai) anos
pai
achega
3947238526
Modificáronse 1 ficheiros con 5 adicións e 0 borrados
  1. 5 0
      lib/docs/filters/electron/clean_html.rb

+ 5 - 0
lib/docs/filters/electron/clean_html.rb

@@ -12,6 +12,11 @@ module Docs
 
         css("footer").remove
 
+        css('pre').each do |node|
+          node.content = node.css('.token-line').map(&:content).join("\n")
+          node['data-language'] = 'javascript'
+        end
+
         doc
       end
     end