History

Update webpack documentation (2.3.3)

Thibaut Courouble committed 9 years ago

Commit 8a0aaec1 parent 2572ddc2 files · +5 −6Browse files

Unified · Split

2 files
  1. lib/docs/filters/webpack/entries.rb +3 −3
  2. lib/docs/scrapers/webpack.rb +2 −3
lib/docs/filters/webpack/entries.rb+3−3
@@ -8,7 +8,6 @@ module Docs · 7 unmodified lines
88 end
99
1010 TYPE_BY_DIRECTORY = {
11− 'get-started' => 'Getting Started',
1211 'concepts' => 'Concepts',
1312 'guides' => 'Guides',
1413 'api' => 'API',
@@ -23,8 +22,9 @@ module Docs · 8 unmodified lines
2322
2423 def additional_entries
2524 if slug.start_with?('configuration')
26− css('h2[id] code').map do |node|
27− [node.content, node.parent['id']]
25+ css('h2[id] code').each_with_object [] do |node, entries|
26+ next if node.previous.try(:content).present?
27+ entries << [node.content, node.parent['id']]
2828 end
2929 elsif slug.start_with?('api')
3030 css('.header[id] code').each_with_object [] do |node, entries|
lib/docs/scrapers/webpack.rb+2−3
@@ -4,9 +4,9 @@ module Docs · 3 unmodified lines
44 self.type = 'webpack'
55
66 version '2' do
7− self.release = '2.2.0'
7+ self.release = '2.3.3'
88 self.base_url = 'https://webpack.js.org/'
9− self.root_path = 'get-started/'
9+ self.root_path = 'guides/get-started/'
1010 self.initial_paths = %w(
1111 concepts/
1212 guides/
@@ -25,7 +25,6 @@ module Docs · 12 unmodified lines
2525 options[:container] = '.page'
2626 options[:trailing_slash] = true
2727 options[:only_patterns] = [
28− /\Aget-started\//,
2928 /\Aconcepts\//,
3029 /\Aguides\//,
3130 /\Aapi\//,