Skip to content

Conversation

EdJoPaTo
Copy link
Contributor

@EdJoPaTo EdJoPaTo commented Mar 17, 2023

Adds two type safe utils to work with JS builtins in a more type safe way.

Also prefer using Object.entries (or typedEntries) over Object.keys(obj) with manual access of the value obj[key] as indexed access could return undefined and TypeScript knows that (with noUncheckedIndexedAccess). Using entries there will contain the value so no need for another check.

(Part of #106)

EdJoPaTo and others added 2 commits May 8, 2023 07:46
the new syntax works but is transpiled into usable code which is not so easy to read in JS

Co-authored-by: maxlath <[email protected]>
@maxlath maxlath merged commit ec4cd5f into maxlath:main May 8, 2023
@EdJoPaTo EdJoPaTo deleted the typesafe-utils branch July 18, 2023 10:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants