Update webpack documentation (3.0.0)

pull/647/head
Thibaut Courouble 8 years ago
parent c34dbc0b16
commit 4bc31ad41f

@ -118,7 +118,8 @@
migrateDocs: ->
for slug in @settings.getDocs() when not @docs.findBy('slug', slug)
needsSaving = true
doc = @disabledDocs.findBy('slug_without_version', slug)
doc = @disabledDocs.findBy('slug', 'webpack') if slug == 'webpack~2'
doc ||= @disabledDocs.findBy('slug_without_version', slug)
if doc
@disabledDocs.remove(doc)
@docs.add(doc)

@ -357,7 +357,8 @@ class App < Sinatra::Application
'angular~1.4' => 'angularjs~1.4',
'angular~1.3' => 'angularjs~1.3',
'angular~1.2' => 'angularjs~1.2',
'codeigniter~3.0' => 'codeigniter~3'
'codeigniter~3.0' => 'codeigniter~3',
'webpack~2' => 'webpack'
}
get %r{/([\w~\.%]+)(\-[\w\-]+)?(/.*)?} do |doc, type, rest|

@ -29,7 +29,7 @@ module Docs
elsif slug.start_with?('api')
css('.header[id] code').each_with_object [] do |node, entries|
next if node.previous.try(:content).present?
entries << ["#{self.name}: #{node.content.sub(/\(.*\)/, '()')}", node.parent['id']]
entries << ["#{self.name.split(':').first}: #{node.content.sub(/\(.*\)/, '()')}", node.parent['id']]
end
else
[]

@ -3,10 +3,10 @@ module Docs
self.name = 'webpack'
self.type = 'webpack'
version '2' do
self.release = '2.6.1'
version do
self.release = '3.0.0'
self.base_url = 'https://webpack.js.org/'
self.root_path = 'guides/get-started/'
self.root_path = 'guides/'
self.initial_paths = %w(
concepts/
guides/
@ -23,7 +23,7 @@ module Docs
html_filters.push 'webpack/clean_html', 'webpack/entries'
options[:container] = '.page'
options[:trailing_slash] = true
options[:trailing_slash] = false
options[:only_patterns] = [
/\Aconcepts\//,
/\Aguides\//,

Loading…
Cancel
Save