[devdocsgjs/main: 1123/1867] angular: add version 11




commit 539e7b9cf8afc0ac57193d86710346040057fff4
Author: Simon Legner <Simon Legner gmail com>
Date:   Sat Nov 14 11:25:13 2020 +0100

    angular: add version 11

 lib/docs/scrapers/angular.rb | 20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)
---
diff --git a/lib/docs/scrapers/angular.rb b/lib/docs/scrapers/angular.rb
index 7775623c..0c4b9f43 100644
--- a/lib/docs/scrapers/angular.rb
+++ b/lib/docs/scrapers/angular.rb
@@ -59,6 +59,26 @@ module Docs
     end
 
     version do
+      self.release = '11.0.0'
+      self.base_url = 'https://angular.io/'
+      self.root_path = 'docs'
+
+      html_filters.push 'angular/clean_html', 'angular/entries'
+
+      options[:follow_links] = false
+      options[:only_patterns] = [/\Aguide/, /\Atutorial/, /\Aapi/]
+      options[:fix_urls_before_parse] = ->(url) do
+        url.sub! %r{\Aguide/}, '/guide/'
+        url.sub! %r{\Atutorial/}, '/tutorial/'
+        url.sub! %r{\Aapi/}, '/api/'
+        url.sub! %r{\Agenerated/}, '/generated/'
+        url
+      end
+
+      include Docs::Angular::Common
+    end
+
+    version '10' do
       self.release = '10.2.3'
       self.base_url = 'https://v10.angular.io/'
       self.root_path = 'docs'


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]