ts2esm icon indicating copy to clipboard operation
ts2esm copied to clipboard

`module.exports = { ... }` are stripped instead of being transformed

Open Lutymane opened this issue 10 months ago • 1 comments

Example:

const c0 = 0;
const c1 = 1;

module.exports = {
  c0,
  c1,
};

Incorrect result:

const c0 = 0;
const c1 = 1;

Expected:

const c0 = 0;
const c1 = 1;

export {
  c0,
  c1,
};

Lutymane avatar Feb 07 '25 06:02 Lutymane

Thanks for the hint! It's getting fixed with: https://github.com/bennycode/ts2esm/pull/166

bennycode avatar Aug 09 '25 19:08 bennycode