DEV Community

Pacharapol Withayasakpunt
Pacharapol Withayasakpunt

Posted on

req.query (or req.params / req.body) to TypeScript enum

I don't get how this is possible. I have always been using 'A' | 'B' | 'C', but this is not enum.

However, I want to map to an ORM that supports enum.

Otherwise, why would you bother using an enum?

Thanks.

Top comments (0)