How to fix Cannot use expression in template literal type in TypeScript | DevErrors