DEV Community


Discussion on: Thoughts on migrating to TypeScript and improving the overall quality of the frontend DEV codebase

nickytonline profile image
Nick Taylor (he/him)

I've just freed up from some other TypeScript OSS, so I'm going to start jamming on this to provide a POC.

For those interested, this is what has been taking most of my OSS bandwidth.

Enable strict-mode for TypeScript #1783

Basically going with the non-null assertion operator in almost all places, because as mentioned in, the assumption with the extension is that the DOM nodes referenced in most cases are expected to be there. If they aren't, the extension breaks, a bug is filed and it's fixed.

One thing to note @bfred-it, is currently dom-chef types need to handle JSX (Element and IntrinsicElements) or we import @types/react.