Grilling: New Post backing editor #62

Closed
opened 2026-10-02 15:46:37 +02:00 by AlexKucera · 1 comment
Owner

Part of #18

Question

#18's AC says the Post folder is created lazily on first write, not on New Post — but the editor core is #19–21 and the editor slot is still a placeholder. What backs the New Post button until then: a plain TextEditor stub whose ⌘S/autosave triggers the first write, lifecycle machinery only (New Post lands with #19), or reordering #19 first?

[Generated by AI]

Part of #18 ## Question #18's AC says the Post folder is created lazily on first write, not on New Post — but the editor core is #19–21 and the editor slot is still a placeholder. What backs the New Post button until then: a plain TextEditor stub whose ⌘S/autosave triggers the first write, lifecycle machinery only (New Post lands with #19), or reordering #19 first? [Generated by AI]
AlexKucera added the wayfinder:grilling label 2026-10-02 15:46:37 +02:00
AlexKucera self-assigned this 2026-10-02 15:46:37 +02:00
Author
Owner

Resolution

Stub editor. A plain SwiftUI TextEditor lands in the existing editor placeholder slot; ⌘S (plus autosave-on-pause if trivial) triggers the first write — lazy folder creation, slug naming, and the #59 frontmatter stamp all fire there.

  • The stub is explicitly throwaway at the view layer: #19's TextKit2 editor (ADR-0010) replaces it in place.
  • #18's real deliverable is the lifecycle machinery — slug function, first-write materialization, rename, trash, watcher — which sits below the view and survives the editor swap untouched.
  • New Post button: selects a fresh in-memory draft (no folder); the folder appears only on first save, per the AC.

[Generated by AI]

## Resolution **Stub editor.** A plain SwiftUI `TextEditor` lands in the existing editor placeholder slot; ⌘S (plus autosave-on-pause if trivial) triggers the first write — lazy folder creation, slug naming, and the #59 frontmatter stamp all fire there. - The stub is explicitly throwaway at the view layer: #19's TextKit2 editor (ADR-0010) **replaces it in place**. - #18's real deliverable is the lifecycle machinery — slug function, first-write materialization, rename, trash, watcher — which sits below the view and survives the editor swap untouched. - New Post button: selects a fresh in-memory draft (no folder); the folder appears only on first save, per the AC. [Generated by AI]
Sign in to join this conversation.