Site reorg: Remove site/ subpath (#306)

Unfortunately, for proper package pathing, need to remove the `site/`
subpath. This includes:
- Moving everything back into root
- Adding a `copy-site.sh` script to copy resources into `mkdocs/site/`
before building the site with mkdocs.
- Also update examples to ensure all are loading the local sw.js / ui.js
- Consolidate examples in `docs/examples`
- Consolidate assets under src/assets/
- Move `favicons` to root
- Reformat and relint
- Tests: update playwright tests to use mkdocs output, add test for
embed in docs
- bump to 2.0.0-beta.2
This commit is contained in:
Ilya Kreymer
2024-04-09 23:07:23 -07:00
committed by GitHub
parent fcd59b634b
commit 92343d59f7
82 changed files with 181 additions and 139 deletions
+22 -24
View File
@@ -1,18 +1,16 @@
site_name: ReplayWeb.page Docs
docs_dir: ../site/
docs_dir: ./site/
watch:
- ../site/
- ./site/
site_dir: _genhtml/
repo_url: https://github.com/webrecorder/replayweb.page
repo_name: ReplayWeb.page
edit_uri: edit/main/site/docs/
extra_css:
- docs/stylesheets/extra.css
extra_javascript:
- docs/js/sw.js
- docs/stylesheets/extra.css
theme:
name: material
custom_dir: ../site/docs/overrides
custom_dir: ./site/docs/overrides
features:
- navigation.sections
- navigation.tabs
@@ -52,18 +50,18 @@ theme:
nav:
- docs/index.md
- Embedding:
- docs/embedding/index.md
- docs/embedding/cors-settings.md
- docs/embedding/index.md
- docs/embedding/cors-settings.md
- User Guide:
- docs/user-guide/index.md
- docs/user-guide/loading.md
- docs/user-guide/locations.md
- docs/user-guide/exploring.md
- docs/user-guide/sharing.md
- docs/user-guide/offline-use.md
- docs/user-guide/index.md
- docs/user-guide/loading.md
- docs/user-guide/locations.md
- docs/user-guide/exploring.md
- docs/user-guide/sharing.md
- docs/user-guide/offline-use.md
markdown_extensions:
- toc:
- toc:
toc_depth: 3
permalink: true
- pymdownx.highlight:
@@ -73,7 +71,7 @@ markdown_extensions:
emoji_generator: !!python/name:material.extensions.emoji.to_svg
options:
custom_icons:
- ../site/docs/overrides/.icons
- ./site/docs/overrides/.icons
- admonition
- pymdownx.inlinehilite
- pymdownx.details
@@ -100,11 +98,11 @@ plugins:
- search
- redirects:
redirect_maps:
'docs/cors-settings.md': 'docs/embedding/cors-settings.md'
'docs/usage.md': 'docs/user-guide/index.md'
'docs/loading_online.md': docs/user-guide/loading.md
'docs/loading_offline.md': docs/user-guide/offline-use.md
'docs/exploring.md': 'docs/user-guide/exploring.md'
'docs/sharing.md': 'docs/user-guide/sharing.md'
'docs/locations.md': 'docs/user-guide/locations.md'
'docs/formats.md': 'docs/user-guide/index.md#supported-formats'
"docs/cors-settings.md": "docs/embedding/cors-settings.md"
"docs/usage.md": "docs/user-guide/index.md"
"docs/loading_online.md": docs/user-guide/loading.md
"docs/loading_offline.md": docs/user-guide/offline-use.md
"docs/exploring.md": "docs/user-guide/exploring.md"
"docs/sharing.md": "docs/user-guide/sharing.md"
"docs/locations.md": "docs/user-guide/locations.md"
"docs/formats.md": "docs/user-guide/index.md#supported-formats"