Sometimes it can be very useful to save previous values of props (or state) in a React component. Perhaps this is easier to be imagined
Continue readingTag: typescript
Using enum values as strictly typed object keys
In TypeScript, it’s often useful to define interfaces or complex (structured) types whose properties (or keys) may only be values of a previously defined enum
Continue reading