added auto-generated architecture docs and mental model#793
added auto-generated architecture docs and mental model#793rdmueller wants to merge 1 commit intojbake-org:masterfrom
Conversation
|
Wow, that's too much to review on phone (Browser only shows first file, app doesn't have a search button). I would like to read more about the rendering model. There's like no documentation about it. What goes in HOW, and how does it get accessible in the model? What I read so far looks really good! |
|
Documentation about metadata in content files, rendering model etc is here: https://jbake.org/docs/2.6.7/ |
| @@ -0,0 +1,703 @@ | |||
| = JBake Anti-Patterns: What NOT to Do | |||
|
|
|||
| This document catalogs common mistakes, anti-patterns, and pitfalls when working with or extending JBake. | |||
There was a problem hiding this comment.
I love this document (plus a few others), but this is soooooo much valuable!
| **Why wrong:** | ||
|
|
||
| * Parsing errors | ||
| * Dates not sortable | ||
| * Archive generation fails | ||
|
|
||
| **✅ Correct approach:** | ||
|
|
||
| * Use consistent format matching `date.format` config | ||
| * Default: `yyyy-MM-dd` | ||
| * Stick to ISO 8601 formats | ||
|
|
||
| **Code example:** | ||
|
|
||
| ```markdown | ||
| ❌ Wrong: | ||
| date=November 22, 2025 # Doesn't match default format! | ||
| date=22/11/2025 # Ambiguous! | ||
|
|
||
| ✅ Correct: | ||
| date=2025-11-22 # ISO 8601, matches default | ||
|
|
||
| # Or configure format: | ||
| # date.format=dd-MM-yyyy |
There was a problem hiding this comment.
This is a big problem related to java.util.Date. We need to think of a date parser which favours java.time related methods and only falls back on java.util.Date on special occasions (e.g. fallback mode, legacy mode, etc.)
|
|
||
| --- | ||
|
|
||
| === ❌ Antipattern: State Leakage Between Tests |
There was a problem hiding this comment.
I'd be happy to contribute a junit 5+ extension :)
|
@rdmueller here's a fork with hsqldb: |
No description provided.