This same concept is also part of the nodejs module resolution. Thats nor pretty but i cant call that a antipattern considering the is very common and is the default resolution from the biggest js runtime out there. Anyway, you can just rename the output as part of your build step. Personally, im using the ESBuild bundle, so i just ask to output a .mjs file, but i can understand that other bundlers may need a rename. Anyway, i do think that request can be made on the wrangler github issues section, appear to be a simple adjustment.