droneshire / dealanalyzer

Analyze deals using in PA
0 stars 0 forks source link

Record types #17

Open jvandermey opened 1 year ago

jvandermey commented 1 year ago

https://github.com/droneshire/dealanalyzer/blob/42c14590838684bfc521270ac0ea08dae8c975ba/src/components/DealInput.tsx#L21

FYI, you can define this type with a builtin generic as Record<string, string>. That being said, if it were me (it's not) I'd probably enumerate all of the field names explicitly to get better type checking and editor auto-complete support.