DEV Community

loading...

Discussion on: Using Typescript string enums? Consider string literals!

Collapse
juliang profile image
Julian Garamendy • Edited

Yes, but I don't think they work when using the --isolatedModules compiler option.

I mean they work but only within a module. You can't export a const enum.

Thread Thread
michaeljota profile image
Michael De Abreu

If you have types imports and exports, most of the type checking won't work when you use isolated modules.

Forem Open with the Forem app