mirror of
https://github.com/facebook/docusaurus.git
synced 2025-05-20 20:46:58 +02:00
fix(v2): allow using classic theme/preset without the docs plugin (#3382)
* deprecated nextVersionLabel option * useActivePlugin failfast option * remove deprecated option nextVersionLabel * routeBasePath: '' should be forbidden * routeBasePath: '' should be forbidden * Docs: do not show version badge if there is only 1 version: https://github.com/facebook/docusaurus/issues/3362 * allow sidebars file to not exist: fallback to empty sidebars https://githu.com/facebook/docusaurus/issues/3366 * Ability to use classic theme/preset while not using docs/pages without trouble. https://github.com/facebook/docusaurus/issues/3360 * fix netlify redirects * do not throw if useDocs do not load? * netlify deploy typo * try to fix useDocs * docs(v2): update Deploy to Vercel guide (#3344) * filter annoying useDocs conditional require warning * netlify deploy preview homepage * typo * try to trigger again CLA bot Co-authored-by: Sam Ko <sam@vercel.com>
This commit is contained in:
parent
a4769e3f30
commit
5359d61d9e
14 changed files with 223 additions and 27 deletions
|
@ -9,9 +9,21 @@ module.exports = function preset(context, opts = {}) {
|
|||
return {
|
||||
themes: [[require.resolve('@docusaurus/theme-bootstrap'), opts.theme]],
|
||||
plugins: [
|
||||
[require.resolve('@docusaurus/plugin-content-pages'), opts.pages],
|
||||
[require.resolve('@docusaurus/plugin-content-blog'), opts.blog],
|
||||
[require.resolve('@docusaurus/plugin-content-docs'), opts.docs],
|
||||
[
|
||||
opts.pages !== false &&
|
||||
require.resolve('@docusaurus/plugin-content-pages'),
|
||||
opts.pages,
|
||||
],
|
||||
[
|
||||
opts.blog !== false &&
|
||||
require.resolve('@docusaurus/plugin-content-blog'),
|
||||
opts.blog,
|
||||
],
|
||||
[
|
||||
opts.docs !== false &&
|
||||
require.resolve('@docusaurus/plugin-content-docs'),
|
||||
opts.docs,
|
||||
],
|
||||
],
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue