@@ -31,6 +31,112 @@ Ideas and improvements to implement in future versions.
3131
3232---
3333
34+ ### Fix Date Parsing Logic
35+ ** Issue** : Current regex-based date parsing breaks on common formats, causing incorrect dates in timeline and displays.
36+
37+ ** Problems** :
38+ - ` "May 2025" ` → parses as ` "January 2025" ` (month information lost)
39+ - ` "Oct 2023 — Dec 2023" ` → fails to parse (em-dash not handled)
40+ - Date ranges with en-dash/em-dash (` – ` , ` — ` ) cause parsing failures
41+ - No validation or error messages for unparseable formats
42+
43+ ** Current Implementation** (` client/src/hooks/useTerminal.ts:23-39 ` ):
44+ ``` typescript
45+ const parseDate = (dateStr : string ): Date => {
46+ const cleanDate = dateStr .replace (/ [^ \d -] / g , ' ' ).trim ();
47+ // This strips ALL non-digit chars, losing "May" in "May 2025"
48+ if (cleanDate .includes (' -' )) {
49+ const [year, month] = cleanDate .split (' -' );
50+ return new Date (parseInt (year ), month ? parseInt (month ) - 1 : 0 );
51+ }
52+ return new Date (parseInt (cleanDate ), 0 );
53+ };
54+ ```
55+
56+ ** Solution** : Use ` date-fns ` library (already in package.json) to support multiple formats:
57+ - ISO formats: ` "2023-03-28" ` , ` "2022-06" ` , ` "2021" `
58+ - Month-Year: ` "May 2025" ` , ` "Jan 2024" ` , ` "Sep 2021" `
59+ - Date ranges: ` "Jul 2025 – Present" ` , ` "Oct 2023 — Dec 2023" `
60+ - Add proper validation and error handling
61+
62+ ** Work Required** :
63+ 1 . Implement multi-format parser using ` date-fns.parse() ` with format detection
64+ 2 . Add date range parser to handle separators (` – ` , ` — ` , ` - ` , ` to ` )
65+ 3 . Handle "Present" keyword for ongoing dates
66+ 4 . Add validation and fallback for unparseable dates
67+ 5 . Test against all date formats currently in ` resume.yaml `
68+
69+ ** Estimated effort** : 5-7 hours
70+
71+ ** Benefits** :
72+ - Fixes timeline display bugs for projects and experience
73+ - Supports flexible date formats like RenderCV
74+ - Better error messages help users debug date issues
75+ - No new dependencies needed (date-fns already included)
76+
77+ ---
78+
79+ ### Fix PDF Section Ordering
80+ ** Issue** : Reordering sections in ` resume.yaml ` doesn't change the section order in the generated PDF resume.
81+
82+ ** Current Behavior** :
83+ - Sections appear in a fixed order in PDF regardless of YAML order
84+ - Users cannot customize section ordering for their career stage
85+ - Students cannot prioritize education/projects over limited experience
86+ - Professionals cannot lead with experience over education
87+
88+ ** Root Cause** (Investigation needed):
89+ Likely causes in ` scripts/generate-resume.js ` :
90+ 1 . ** js-yaml sortKeys** : ` yaml.load() ` might be using ` sortKeys: true ` (alphabetical sorting)
91+ 2 . ** RenderCV Template** : The classic template might have hardcoded section order
92+ 3 . ** Data Transformation** : The script might be reconstructing objects in fixed order when filtering projects
93+
94+ ** How RenderCV Should Handle This** :
95+ - Section order in YAML input should equal section order in PDF output
96+ - Python's dict preserves insertion order (Python 3.7+)
97+ - RenderCV uses ` ruamel.yaml ` which preserves YAML order
98+
99+ ** Solution** : Ensure order preservation throughout the pipeline
100+
101+ ** Work Required** :
102+ 1 . ** Fix js-yaml loading** (scripts/generate-resume.js):
103+ ``` javascript
104+ const fullData = yaml .load (yamlContent, {
105+ sortKeys: false // Preserve YAML order
106+ });
107+ ```
108+
109+ 2 . ** Investigate object reconstruction** (scripts/generate-resume.js:163-187):
110+ - When filtering projects, ensure sections object is rebuilt in original order
111+ - Use ` Object.entries() ` and reduce to maintain order
112+ - Avoid object spread which might reorder keys
113+
114+ 3 . ** Verify RenderCV template** : Check if classic template respects input order
115+ - May need to switch template or configure section order
116+ - Check RenderCV documentation for section ordering options
117+
118+ 4 . ** Add validation** :
119+ - Log section order before writing temp YAML
120+ - Verify order preservation after each transformation
121+
122+ 5 . ** Add tests** :
123+ - Create test resume with unusual order (education first, then experience)
124+ - Verify PDF matches YAML order
125+
126+ 6 . ** Document the feature** once working:
127+ - Add examples to README.md and docs/ADVANCED.md
128+ - Show different orderings for students vs professionals
129+
130+ ** Estimated effort** : 4-6 hours (investigation + implementation + testing)
131+
132+ ** Benefits** :
133+ - Users can customize resume structure for their career stage
134+ - Students can prioritize education and projects over limited experience
135+ - Professionals can lead with experience and achievements
136+ - Better alignment with RenderCV's flexible philosophy
137+
138+ ---
139+
34140## Medium Priority
35141
36142### ✅ Neofetch Auto-Fallback (COMPLETED)
@@ -106,6 +212,87 @@ Users no longer need to manually create neofetch files.
106212
107213---
108214
215+ ### Make Schema More Flexible (Inspired by RenderCV)
216+ ** Issue** : Current schema is too rigid - doesn't allow custom sections or extra fields like RenderCV does.
217+
218+ ** Current Limitations** (in ` shared/schema.ts ` ):
219+ 1 . ** Fixed Section Names** : Only supports hardcoded sections (` intro ` , ` technologies ` , ` experience ` , etc.)
220+ - Cannot add custom sections like "Certifications" or "Awards" without modifying schema
221+ 2 . ** Strict Field Requirements** : Many fields are required even when not applicable
222+ - Experience requires ` location ` (problematic for remote-first roles)
223+ - Projects require ` highlights ` array (should be optional)
224+ 3 . ** No Custom Fields** : Cannot add extra fields to entries
225+ - Cannot add ` company_logo_url ` or ` github_repo ` to projects
226+ - Cannot add ` relevance_score ` or custom metadata
227+
228+ ** How RenderCV Handles This** :
229+ - ** Flexible Sections** : "Section titles are arbitrary" - use any section names
230+ - ** Minimal Requirements** : Only truly essential fields are required
231+ - ** Extra Fields Supported** : "RenderCV allows the usage of any number of extra keys in the entries"
232+ - ** Graceful Handling** : Custom fields don't break output, can be used in custom designs
233+
234+ ** Solution** : Make schema progressive and extensible
235+
236+ ** Work Required** :
237+ 1 . ** Add ` .passthrough() ` to All Schemas** (2 hours):
238+ ``` typescript
239+ export const experienceSchema = z .object ({
240+ company: z .string (),
241+ position: z .string (),
242+ // ... other fields
243+ }).passthrough (); // Allow extra fields
244+ ```
245+
246+ 2 . ** Make More Fields Optional** (2 hours):
247+ - ` location ` in experience (already done in education)
248+ - ` highlights ` in projects/experience (use ` .default([]) ` )
249+ - Consider making ` company ` /` position ` optional for freelance cases
250+
251+ 3 . ** Support Dynamic Section Names** (3 hours):
252+ ``` typescript
253+ // Instead of fixed keys, allow any section name
254+ sections : z .record (
255+ z .string (), // section name (e.g., "Certifications")
256+ z .array (z .union ([/* all entry types */ ]))
257+ ).optional ()
258+ ```
259+
260+ 4 . ** Update Type Handling** (1 hour):
261+ - Update ` client/src/hooks/useTerminal.ts ` to handle dynamic sections
262+ - Add fallback rendering for unknown section types
263+ - Update TypeScript types to reflect new flexibility
264+
265+ ** Estimated effort** : 6-8 hours total
266+
267+ ** Benefits** :
268+ - Users can add custom sections without modifying code
269+ - Support for non-traditional career paths (freelancers, consultants)
270+ - Better alignment with RenderCV's philosophy
271+ - Future-proof for new field requirements
272+ - More inclusive for diverse backgrounds
273+
274+ ** Breaking Changes** : None if done carefully
275+ - Existing resume.yaml files continue to work
276+ - New features are opt-in via custom fields
277+
278+ ** Example Use Cases** :
279+ ``` yaml
280+ sections :
281+ certifications : # Custom section!
282+ - name : " AWS Certified Solutions Architect"
283+ issuer : " Amazon Web Services"
284+ date : " 2024"
285+ credential_id : " ABC123" # Custom field!
286+
287+ experience :
288+ - company : " Acme Corp"
289+ position : " Senior Engineer"
290+ github_team : " acme-corp/platform" # Custom field!
291+ stack : ["TypeScript", "React"] # Custom field!
292+ ` ` `
293+
294+ ---
295+
109296## Low Priority
110297
111298### Voice Commands
0 commit comments