FIX: CRLF & Switch to Dynamic Data Loading for Product Files (ref PR: #14 #15 #16) #21
+943
−168
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
import.meta.globwith runtimefetch()for product data filesRelated PRs
This PR consolidates and extends the CRLF fixes from:
All three PRs address the same Windows line ending issue but only in
product-loader.ts. This PR applies the fix across all loaders and adds hot-reload support.Problem
Product markdown files (roadmap, overview, data model, etc.) were loaded at build time using Vite's
import.meta.glob. This caused two issues:product/directory required restarting the dev server to see updates\r\n) failed to parse correctly, causing "No Roadmap Defined Yet" even when the file existedSolution
fetch()with cache-busting in dev modeuseProductDatahook for consistent async loading patternChanges
src/lib/product-loader.tsfetchProductData()src/lib/data-model-loader.tssrc/lib/design-system-loader.tssrc/lib/shell-loader.tssrc/lib/use-product-data.tssrc/components/*Page.tsxuseProductDatahook with loading statessrc/components/PhaseNav.tsxsrc/components/PhaseWarningBanner.tsxTesting
product/*.mdfilesBreaking Changes
None. The async loading is handled internally with loading states.