docusaurus/packages/docusaurus-theme-common
Alexey Pyltsyn 237d1a31f5
fix(v2): introduce useCollapsible to fix collapsible animation perf issues (#5116)
* fix(v2): avoid slowdown transition with huge sidebar items

* move useCollapsible to theme-common

* @docusaurus/theme-classic => watch mode should include type-checking

* refactor useCollapsible => encapsulate more behavior / state / ref inside it, making code simpler for component using it

* useCollapseAnimation => animate DOM properties directly instead of using React inline styles => optimize perf from 4 render per click to 1 render per click

* add missing items in deps array

* rename ref to collapsibleRef

* lint

Co-authored-by: slorber <lorber.sebastien@gmail.com>
2021-07-07 18:50:13 +02:00
..
src fix(v2): introduce useCollapsible to fix collapsible animation perf issues (#5116) 2021-07-07 18:50:13 +02:00
package.json chore(v2): prepare v2.0.0-beta.3 release (#5098) 2021-06-30 16:05:49 +02:00
README.md docs(v2): Add READMEs to v2 packages (#4034) 2021-01-14 17:16:26 +01:00
tsconfig.json feat(v2): Allow customization of js loader, replace babel by esbuild in Docusaurus website (#4766) 2021-05-14 11:30:34 +02:00

@docusaurus/theme-common

Common code for Docusaurus themes.