CommonJS module import failure when module.exports
has key containing escaped whitespace
#27422
Labels
bug
Something isn't working correctly
Version: Deno 2.1.4
I ran into an issue related to CommonJS modules that hit me while working with https://daisyui.com via this package: @matthiesenxyz/unocss-preset-daisyui / github. When I import a module that exports an object with a
\n
inside a key, an error is thrown. The same is true for\t
and\r
. When I put the same code in an ESM module it works without issues.Test script that imports two scripts,
works.js
is the ESM module,bang.cjs
the CommonJS module.test.js
:works.js
:bang.cjs
:Result:
The text was updated successfully, but these errors were encountered: