this plugin replace file content instead of import path.
{
"compilerOptions": {
"plugins": [
{
"transform": "typescript-plugin-file-replacement",
"replacements": [
{
"replace": "src/dev.env.ts",
"with": "src/prod.env.ts"
}
]
}
]
}
}