Community Workshop Planner
Part of the Routing and State section of Coddy's Vue journey. Lesson 55 of 55.
Build this checkpoint of the Community Workshop Planner.
Finish the Community Workshop Planner while preserving all earlier features and filenames. Add protected note editing at /edit/:id, reached through each detail view. Detail p#note shows the store note. The editor copies it into input#draft locally; Save note trims and commits a nonempty value only to that workshop, then normalizes the draft to the saved value. Blank saves do nothing. Discard changes restores the current saved note. Show Saved or Unsaved in p#dirty and block leaving the editor while dirty. After saving or discarding, navigation works. Notes and reservations remain independent across workshops and survive route changes.
Keep the supplied route readout and bootstrap files.
Keep the supplied Navigation examples links. On My plan, display query tab or overview in p#plan-tab. The Plan notes link must return to the same query after sign-in; invalid return examples and the plain Sign in link use the fallback.
Render the stored note in brackets in p#note, and the current draft in brackets in p#draft-check. A padded successful save must leave no padding inside these brackets. Trying to edit Code while signed out must resume /edit/code after sign-in.
Challenge
HardFinish the Community Workshop Planner while preserving all earlier features and filenames. Add protected note editing at /edit/:id, reached through each detail view. Detail p#note shows the store note. The editor copies it into input#draft locally; Save note trims and commits a nonempty value only to that workshop, then normalizes the draft to the saved value. Blank saves do nothing. Discard changes restores the current saved note. Show Saved or Unsaved in p#dirty and block leaving the editor while dirty. After saving or discarding, navigation works. Notes and reservations remain independent across workshops and survive route changes.
Keep the supplied route readout and bootstrap files.
Keep the supplied Navigation examples links. On My plan, display query tab or overview in p#plan-tab. The Plan notes link must return to the same query after sign-in; invalid return examples and the plain Sign in link use the fallback.
Render the stored note in brackets in p#note, and the current draft in brackets in p#draft-check. A padded successful save must leave no padding inside these brackets. Trying to edit Code while signed out must resume /edit/code after sign-in.
Try it yourself
<!doctype html><html><head><meta charset="UTF-8"><title>Routing practice</title></head><body><div id="app"></div><script type="module" src="./main.js"></script></body></html>This lesson includes a short quiz. Start the lesson to answer it and track your progress.
All lessons in Routing and State
4Query State
Reading Query ValuesCommitting Search QueriesPreserving Other FiltersNormalizing Query NumbersRecap: Catalog Filters2Navigation Actions
Navigation from HandlersReplacing HistoryHistory TravelCurrent Navigation LinksRecap: Save and Review5Nested Layouts
Parent and Child OutletsDefault Child ViewsRelative Child PathsAncestor Navigation StateRecap: Library Workspace8Store Design
Setup Store StructurePatching Related StateResetting Store StateComposing Related StoresRecap: Trip Pack11Workshop Planner Project
Planner RoutesShared Reservations