Skip to content

Commit aefa90b

Browse files
committed
fix(mkdocs): Correct pattern navigation paths to subdirectories
- Fix pattern navigation to point to actual files in subdirectories - Change from non-existent .md files to nested structure: - patterns/sliding_window/intuition.md - patterns/sliding_window/templates.md - patterns/two_pointers/intuition.md - patterns/two_pointers/templates.md - patterns/backtracking_exploration/intuition.md - patterns/backtracking_exploration/templates.md - Update MKDOCS_CONTENT_GUIDE.md to reflect correct path structure
1 parent 3df08d1 commit aefa90b

File tree

2 files changed

+53
-24
lines changed

2 files changed

+53
-24
lines changed

docs/MKDOCS_CONTENT_GUIDE.md

Lines changed: 44 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -23,23 +23,30 @@ Based on the `nav` configuration in `mkdocs.yml`, the following content is inclu
2323
|:-----|:------------|:------------|
2424
| `docs/index.md` | Homepage (includes README.md content) | `https://lufftw.github.io/neetcode/` |
2525
| `docs/index_zh-TW.md` | Traditional Chinese homepage | `https://lufftw.github.io/neetcode/index_zh-TW/` |
26-
| `docs/patterns/*.md` | Pattern documentation | `https://lufftw.github.io/neetcode/patterns/...` |
26+
| `docs/patterns/*.md` | Pattern documentation overview | `https://lufftw.github.io/neetcode/patterns/` |
27+
| `docs/patterns/*/intuition.md` | Pattern intuition guides | `https://lufftw.github.io/neetcode/patterns/.../intuition/` |
28+
| `docs/patterns/*/templates.md` | Pattern template guides | `https://lufftw.github.io/neetcode/patterns/.../templates/` |
2729
| `docs/mindmaps/*.md` | All mind map Markdown files | `https://lufftw.github.io/neetcode/mindmaps/...` |
2830
| `docs/pages/mindmaps/*.html` | Interactive mind map HTML files | `https://lufftw.github.io/neetcode/pages/mindmaps/...` |
2931
| `docs/SOLUTION_CONTRACT.md` | Solution file specification | `https://lufftw.github.io/neetcode/SOLUTION_CONTRACT/` |
3032
| `docs/GENERATOR_CONTRACT.md` | Generator file specification | `https://lufftw.github.io/neetcode/GENERATOR_CONTRACT/` |
3133
| `docs/ARCHITECTURE_MIGRATION.md` | Architecture migration guide | `https://lufftw.github.io/neetcode/ARCHITECTURE_MIGRATION/` |
3234
| `docs/GITHUB_PAGES_SETUP.md` | GitHub Pages deployment guide | `https://lufftw.github.io/neetcode/GITHUB_PAGES_SETUP/` |
3335
| `docs/BUILD_DOCS_MANUAL.md` | Local documentation build (manual method) | `https://lufftw.github.io/neetcode/BUILD_DOCS_MANUAL/` |
36+
| `docs/LOCAL_DOCS_BUILD.md` | Local docs build options | `https://lufftw.github.io/neetcode/LOCAL_DOCS_BUILD/` |
3437
| `docs/ACT_LOCAL_GITHUB_ACTIONS.md` | Run GitHub Actions locally with act | `https://lufftw.github.io/neetcode/ACT_LOCAL_GITHUB_ACTIONS/` |
38+
| `docs/ONTOLOGY_DESIGN.md` | Ontology design documentation | `https://lufftw.github.io/neetcode/ONTOLOGY_DESIGN/` |
39+
| `docs/MKDOCS_CONTENT_GUIDE.md` | MkDocs content guide (this file) | `https://lufftw.github.io/neetcode/MKDOCS_CONTENT_GUIDE/` |
3540

3641
### 📝 Special Notes
3742

3843
- **README.md** and **README_zh-TW.md**: These files do **NOT** appear as separate pages on the website. Instead, they are included in `docs/index.md` and `docs/index_zh-TW.md` via the `include-markdown` plugin.
3944
- **docs/patterns/**: ✅ Now configured in `nav` and available on the website.
4045
- **docs/GITHUB_PAGES_SETUP.md**: ✅ Now configured in `nav` and available on the website.
41-
- **Local build guides**: ✅ `BUILD_DOCS_MANUAL.md` (recommended) and `ACT_LOCAL_GITHUB_ACTIONS.md` (optional) are now configured in `nav`.
42-
- **Reference docs**: ✅ `SOLUTION_CONTRACT.md`, `GENERATOR_CONTRACT.md`, and `ARCHITECTURE_MIGRATION.md` are now configured in `nav`.
46+
- **Local build guides**: ✅ `BUILD_DOCS_MANUAL.md` (recommended), `LOCAL_DOCS_BUILD.md`, and `ACT_LOCAL_GITHUB_ACTIONS.md` (optional) are now configured in `nav`.
47+
- **Reference docs**: ✅ `SOLUTION_CONTRACT.md`, `GENERATOR_CONTRACT.md`, `ARCHITECTURE_MIGRATION.md`, and `ONTOLOGY_DESIGN.md` are now configured in `nav`.
48+
- **Guides**: ✅ `MKDOCS_CONTENT_GUIDE.md` is now configured in `nav`.
49+
- **Patterns**: ✅ `backtracking_exploration` pattern is now available in `nav` alongside `sliding_window` and `two_pointers`.
4350
- **Tools docs**: Developer tools documentation is in [`tools/README.md`](https://github.com/lufftw/neetcode/blob/main/tools/README.md) (not on website, GitHub only).
4451

4552
---
@@ -72,22 +79,11 @@ The following directories and files **do NOT** appear in the MkDocs website and
7279

7380
### 📚 Documentation (Not in nav)
7481

75-
| File | Description | GitHub Link Format |
76-
|:-----|:------------|:-------------------|
77-
| `docs/ONTOLOGY_DESIGN.md` | Ontology design documentation | `https://github.com/lufftw/neetcode/blob/main/docs/ONTOLOGY_DESIGN.md` |
78-
| `docs/MKDOCS_CONTENT_GUIDE.md` | This file | `https://github.com/lufftw/neetcode/blob/main/docs/MKDOCS_CONTENT_GUIDE.md` |
82+
**Note**: All major documentation files are now configured in `nav` and available on the website. See [Content Included in Website](#content-included-in-website) section above for the complete list.
7983

80-
**Note**: The following docs are now configured in `nav` and available on the website:
81-
82-
- `docs/patterns/` - Pattern documentation
83-
- `docs/GITHUB_PAGES_SETUP.md` - GitHub Pages setup guide
84-
- `docs/BUILD_DOCS_MANUAL.md` - Local documentation build (manual method, recommended)
85-
- `docs/ACT_LOCAL_GITHUB_ACTIONS.md` - Run GitHub Actions locally with act (optional, advanced)
86-
- `docs/SOLUTION_CONTRACT.md` - Solution file specification
87-
- `docs/GENERATOR_CONTRACT.md` - Generator file specification
88-
- `docs/ARCHITECTURE_MIGRATION.md` - Architecture migration guide
89-
90-
See [Content Included in Website](#content-included-in-website) section above.
84+
The following files are **intentionally NOT** in the website navigation (GitHub only):
85+
- Internal development notes and drafts
86+
- Temporary documentation files
9187

9288
### 🔧 Maintainer Documentation
9389

@@ -139,13 +135,19 @@ When linking to content in README.md, follow these strategies:
139135

140136
```markdown
141137
<!-- Document in nav - can use relative paths -->
142-
- [📐 Patterns](docs/patterns/) — Pattern documentation
138+
- [📐 Patterns](docs/patterns/) — Pattern documentation overview
139+
- [Sliding Window Intuition](docs/patterns/sliding_window/intuition.md) — Sliding window intuition guide
140+
- [Sliding Window Templates](docs/patterns/sliding_window/templates.md) — Sliding window templates
141+
- [Two Pointers Intuition](docs/patterns/two_pointers/intuition.md) — Two pointers intuition guide
142+
- [Two Pointers Templates](docs/patterns/two_pointers/templates.md) — Two pointers templates
143+
- [Backtracking Exploration Intuition](docs/patterns/backtracking_exploration/intuition.md) — Backtracking intuition guide
144+
- [Backtracking Exploration Templates](docs/patterns/backtracking_exploration/templates.md) — Backtracking templates
143145
- [GitHub Pages Setup](docs/GITHUB_PAGES_SETUP.md) — Deployment guide
144146
- [Build Documentation Locally](docs/BUILD_DOCS_MANUAL.md) — Manual build method (recommended)
147+
- [Local Docs Build Options](docs/LOCAL_DOCS_BUILD.md) — Build options guide
145148
- [Run GitHub Actions Locally](docs/ACT_LOCAL_GITHUB_ACTIONS.md) — Act method (optional, advanced)
146-
147-
<!-- Document NOT in nav - use GitHub URLs -->
148-
- [`docs/ONTOLOGY_DESIGN.md`](https://github.com/lufftw/neetcode/blob/main/docs/ONTOLOGY_DESIGN.md) — Ontology design documentation
149+
- [Ontology Design](docs/ONTOLOGY_DESIGN.md) — Ontology design documentation
150+
- [MkDocs Content Guide](docs/MKDOCS_CONTENT_GUIDE.md) — Content guide (this file)
149151
```
150152

151153
#### 3. For Code Files (Not in Website)
@@ -194,9 +196,26 @@ A: ✅ Yes! The "📚 Reference" section is now configured in `nav` and includes
194196
- Solution Contract at `https://lufftw.github.io/neetcode/SOLUTION_CONTRACT/`
195197
- Generator Contract at `https://lufftw.github.io/neetcode/GENERATOR_CONTRACT/`
196198
- Architecture Migration at `https://lufftw.github.io/neetcode/ARCHITECTURE_MIGRATION/`
199+
- Ontology Design at `https://lufftw.github.io/neetcode/ONTOLOGY_DESIGN/`
197200

198201
**Note**: Tools documentation is in [`tools/README.md`](https://github.com/lufftw/neetcode/blob/main/tools/README.md) (GitHub only, not on website).
199202

203+
### Q: What patterns are available on the website?
204+
205+
A: ✅ The following patterns are now configured in `nav`:
206+
207+
- **Sliding Window**
208+
- Intuition: `https://lufftw.github.io/neetcode/patterns/sliding_window/intuition/`
209+
- Templates: `https://lufftw.github.io/neetcode/patterns/sliding_window/templates/`
210+
- **Two Pointers**
211+
- Intuition: `https://lufftw.github.io/neetcode/patterns/two_pointers/intuition/`
212+
- Templates: `https://lufftw.github.io/neetcode/patterns/two_pointers/templates/`
213+
- **Backtracking Exploration**
214+
- Intuition: `https://lufftw.github.io/neetcode/patterns/backtracking_exploration/intuition/`
215+
- Templates: `https://lufftw.github.io/neetcode/patterns/backtracking_exploration/templates/`
216+
217+
Each pattern includes both Intuition and Templates documentation as separate pages in the navigation.
218+
200219
### Q: Do links in README.md work in both GitHub and the website?
201220

202221
A: It depends on the link type:
@@ -229,6 +248,9 @@ If you need to access these documents, use the GitHub absolute URLs provided in
229248
- **2025-12-12**: Added "📚 Reference" section to nav with Solution Contract, Generator Contract, Architecture Migration
230249
- **2025-12-12**: Moved Tools documentation from `docs/TOOLS.md` to `tools/README.md` (developer docs belong with code)
231250
- **2025-01-XX**: Added local documentation build guides - `BUILD_DOCS_MANUAL.md` (recommended) and `ACT_LOCAL_GITHUB_ACTIONS.md` (optional) to Guides section
251+
- **2025-12-XX**: Added `ONTOLOGY_DESIGN.md` to Reference section
252+
- **2025-12-XX**: Added `MKDOCS_CONTENT_GUIDE.md` and `LOCAL_DOCS_BUILD.md` to Guides section
253+
- **2025-12-XX**: Added `backtracking_exploration` pattern to Patterns section
232254
- Check `mkdocs.yml` `nav` configuration for the latest list
233255

234256
---

mkdocs.yml

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,8 +104,15 @@ nav:
104104
- 繁體中文: index_zh-TW.md
105105
- 📐 Patterns:
106106
- Overview: patterns/README.md
107-
- Sliding Window: patterns/sliding_window.md
108-
- Two Pointers: patterns/two_pointers.md
107+
- Sliding Window:
108+
- Intuition: patterns/sliding_window/intuition.md
109+
- Templates: patterns/sliding_window/templates.md
110+
- Two Pointers:
111+
- Intuition: patterns/two_pointers/intuition.md
112+
- Templates: patterns/two_pointers/templates.md
113+
- Backtracking Exploration:
114+
- Intuition: patterns/backtracking_exploration/intuition.md
115+
- Templates: patterns/backtracking_exploration/templates.md
109116
- 🧠 Mind Maps:
110117
- Overview: mindmaps/index.md
111118
- AI Analysis (English): mindmaps/neetcode_ontology_ai_en.md

0 commit comments

Comments
 (0)