Commit graph

16 commits

Author SHA1 Message Date
Bharat Middha
09550b0535
feat: properly type-check the Docusaurus config of new sites (#5589)
* fix: makes types DocusaurusConfig optional to match docs

* add UserDocusaurusConfig with required keys for user config

* convert UserDocusaurusConfig to use util type

* Docusaurus website config should be type-checked by CI + fix all existing issues

* add doc for config typechecking

* Update template configs for TS autocompletion

* fix last config typechecking bugs

* reapply prettier

* reapply prettier-docs

* Fix TS doc: add missing ()

* fix some docu plugin types

* add "const config" for simpler jsdoc annotation

Co-authored-by: slorber <lorber.sebastien@gmail.com>
2021-09-30 17:49:44 +02:00
Paul O’Shannessy
8341527fc9
refactor: rename Git master branch to main (#5345)
* Prepare to renaming master branch to main

* Update CONTRIBUTING.md

* Update packages/docusaurus-migrate/src/__tests__/__fixtures__/missing_version_website/website/package.json

* Update packages/docusaurus-migrate/src/__tests__/__fixtures__/complex_website/website/package.json

* Update packages/docusaurus-migrate/src/__tests__/__fixtures__/simple_website/website/package.json

* missing master -> main replaces

* useless char

* For GH Pages org deploy, DEPLOYMENT_BRANCH env is now required

* fix versioning page

* fix vercel links

* update deployment.mdx

Co-authored-by: Sébastien Lorber <slorber@users.noreply.github.com>
Co-authored-by: slorber <lorber.sebastien@gmail.com>
2021-08-17 18:41:53 +02:00
Joshua Chen
4c246493ef
refactor(init): share common files between templates (#5315)
* Create shared folder & update init logic

Signed-off-by: Josh-Cena <sidachen2003@gmail.com>

* Restore needed links

Signed-off-by: Josh-Cena <sidachen2003@gmail.com>

* Prevent copying symlinks

Signed-off-by: Josh-Cena <sidachen2003@gmail.com>

* Reuse some FB files

Signed-off-by: Josh-Cena <sidachen2003@gmail.com>

* Minor tweak

Signed-off-by: Josh-Cena <sidachen2003@gmail.com>

* Minor refactors

Signed-off-by: Josh-Cena <sidachen2003@gmail.com>

* Fix bootstrap url

Signed-off-by: Josh-Cena <sidachen2003@gmail.com>

* Add path alias

Signed-off-by: Josh-Cena <sidachen2003@gmail.com>

* Handle facebook template more gracefully

Signed-off-by: Josh-Cena <sidachen2003@gmail.com>

* minor refactor: extract getTypeScriptBaseTemplate

Co-authored-by: slorber <lorber.sebastien@gmail.com>
2021-08-10 16:26:59 +02:00
LittleboyHarry
22e231904d
feat(v2): improve templates, use JSDoc type annotation, improve docusaurus.config.js autocompletion (#4098)
Co-authored-by: LittleboyHarry <LittleboyHarry@users.noreply.github.com>
2021-01-27 15:34:12 +01:00
iAmir
8f2d898f22
feat(v2): onBrokenMarkdownLinks config (#3658)
* refactor(v2): move `reportMessage` from `core/src/server/utils` to `utils` package

* feat(v2): handle broken markdown links by using onBrokenLinks prop from siteconfig

* feat(v2): add a new site config prop called `onBrokenMarkdownLinks`

works like onBrokenLinks, but only for markdown links

* feat(v2): add `onBrokenMarkdownLinks` to API docs

* some changes regarding test issues after adding `onBrokenMarkdownLink`

* Update website/versioned_docs/version-2.0.0-alpha.66/api/docusaurus.config.js.md

Co-authored-by: Sébastien Lorber <slorber@users.noreply.github.com>
2020-10-31 18:04:56 +01:00
Sébastien Lorber
0a33a52301
fix(v2): deprecate docs homePageId in favor of frontmatter "slug: /" (#3228)
* homePageId => deprecated

* docs prettier
2020-08-06 18:31:50 +02:00
Sébastien Lorber
8ff28e3fe4
feat(v2): broken links detection (#3059)
* add broken links checker

* polish

* finalize broken links detection feature

* note broken links is only for prod build

* fix broken link on template

* fix test snapshot

* fix bad merge
2020-07-21 19:13:34 +02:00
Sébastien Lorber
15e73daae7
feat(v2): global data + useGlobalData + docs versions dropdown (#2971)
* doc components initial simplification

* doc components initial simplification

* add docContext test

* Add poc of global data system + use it in the theme

* Revert "doc components initial simplification"

This reverts commit f657b4c4

* revert useless changes

* avoid loosing context on docs switch

* fix docs tests

* fix @generated/globalData ts declaration / es import

* typo

* revert bad commit

* refactor navbar in multiple parts + add navbar item types validation + try to fix remaining merge bugs

* add missing watch mode for plugin debug

* fix docs global data integration, move related hooks to docs plugin + convert to TS

* change versions link label

* fix activeClassName react warning

* improve docs global data system + contextual navbar dropdown

* fix bug preventing the deployment

* refactor the global data system to namespace automatically by plugin name + plugin id

* proper NavbarItem comp

* fix tests

* fix snapshot

* extract theme config schema in separate file + rename navbar links to navbar items

* minor typos

* polish docs components/api

* polish useDocs api surface

* fix the docs version suggestions comp + data

* refactors + add docsClientUtils unit tests

* Add documentation

* typo

* Add check for duplicate plugin ids detection

* multi-instance: createData plugin data should be namespaced by plugin instance id

* remove attempt for multi-instance support
2020-07-21 11:16:08 +02:00
Alexey Pyltsyn
c7baa125e6
chore(v2): mention about docs home page in init templates (#2763)
* chore(v2): mention about docs home page in init templates

* use home page id for docs

Co-authored-by: Yangshun Tay <tay.yang.shun@gmail.com>
2020-05-18 13:14:06 +08:00
Fanny
7e97d40075
feat(v2): bootstrap doc sidebar (#2735)
* feat(v2): add minor adjustements and footer component

* fix(v2): margin and spacing of footer

* feat(v2): add navbar component

* ádd collapse classname

* feat(v2): add dependencies

* feat(v2): remove unused code

* feat(v2): remove unused links

* feat(v2): add reactstrap components :|

* feat(v2): add brand and other nav componnets

* feat(v2): Add the layout tag

* feat(v2): bootstrap start doc components

* feat(v2: Add syntax highlight

* Ádd Page components

* feat(v2): Bootstrap MDX Componnets

* fix(v2): Fix layout height

* fix(v2): Fix spacings

* feat:(v2): Add the layout in doc content

* feat(v2): Start the pagination

* feat(v2): Finish pagination

* Fix margins in mobile

* feat(v2): Add the doc sidebar

* feat(v2): Add sidebar

* feat(v2): Makes sidebar responsive

* feat(v2): Add context

* feat(v2): Add new hook and docs to the template sidebar

* feat(v2): Add css modules

* feat(v2): add sidebar class

* feat(v2): add floating action button

* fix fab styles

* fix(v2): fix height

* feat(v2): Remove context

* feat(v2): Finish sidebar

* feat(v2): Add resize window hook

* feat(v2): Remove unsed fields

* feat(v2): Add theme

* feat(v2): improve sidebar definitions

* feat(v2): fix conflicts
2020-05-18 11:06:48 +08:00
Fanny
b91f02dee2
feat(v2): bootstrap doc paginator (#2734)
* feat(v2): add minor adjustements and footer component

* fix(v2): margin and spacing of footer

* feat(v2): add navbar component

* ádd collapse classname

* feat(v2): add dependencies

* feat(v2): remove unused code

* feat(v2): remove unused links

* feat(v2): add reactstrap components :|

* feat(v2): add brand and other nav componnets

* feat(v2): Add the layout tag

* feat(v2): bootstrap start doc components

* feat(v2: Add syntax highlight

* Ádd Page components

* feat(v2): Bootstrap MDX Componnets

* fix(v2): Fix layout height

* fix(v2): Fix spacings

* feat:(v2): Add the layout in doc content

* feat(v2): Start the pagination

* feat(v2): Finish pagination

* Fix margins in mobile

* feat(v2): Add theme
2020-05-17 22:51:03 +08:00
Fanny
7d8aeacf52
feat(v2): bootstrap layout navbar (#2668)
* feat(v2): add minor adjustements and footer component

* fix(v2): margin and spacing of footer

* feat(v2): add navbar component

* ádd collapse classname

* feat(v2): add dependencies

* feat(v2): remove unused code

* feat(v2): remove unused links

* feat(v2): add reactstrap components :|

* feat(v2): add brand and other nav componnets
2020-05-13 11:24:53 +08:00
Yangshun Tay
e1258baa77
chore(v2): add Privacy Policy and Terms of Use links to footer (#2638)
* chore(v2): add Privacy Policy and Terms of Services links to footer

* rename

* Shift to links
2020-04-22 12:30:03 +08:00
Fanny
ea5a50c4de
feat(v2): bootstrap theme blog post page (#2591)
* feat(v2): init the blog post card

* feat(v2): Update card design

* chore(v2): remove unused dependency

* feat(v2): add post list

* feat(v2): improve html tags

* chore(v2): run prettier

* feat(v2): remove old tag

* feat(v2): apply suggestions

* feat(v2): add tags for blog post

* feat(v2): add post content

* feat(v2): add tags

* feat(v2): add specific tag page

* feat(v2): fix tablet layout

* feat(v2): fix tablet layout

* feat(v2): add blog post page

* feat(v2): apply suggestions

* Update 2020-04-14-blog-plugin.md

* Update 2020-04-14-large-blog-post.md

Co-authored-by: Yangshun Tay <tay.yang.shun@gmail.com>
2020-04-15 10:03:23 +08:00
Fanny
f61b92d86a
feat(v2): bootstrap blog post page and card (#2584)
* feat(v2): init the blog post card

* feat(v2): Update card design

* chore(v2): remove unused dependency

* feat(v2): add post list

* feat(v2): improve html tags

* chore(v2): run prettier

* feat(v2): remove old tag

* feat(v2): apply suggestions
2020-04-12 22:41:34 +08:00
Fanny
434da1d7ea
feat(v2): bootstrap bootstrap (heh) theme, preset, template (#2557)
* feat(v2): Add bootstrap theme structure

* chore(v2): run prettier

* chore(v2): remove unused dependencies

* feat(v2): add bootstrap preset

* feat(v2): add bootstrap template

* remove unnecessary stuff

* --

Co-authored-by: Yangshun Tay <tay.yang.shun@gmail.com>
2020-04-09 12:58:01 +08:00