Rich-Harris/devalue

nodejs.TypeError: devalue_1.default is not a function

zhangciwu opened this issue · 1 comments

code:

import devalue from 'devalue';
...

devalue({a:1});

And got error: nodejs.TypeError: devalue_1.default is not a function

Env: Node 10.x, typescript 3.8

Looks like node picksdist/devalue.umd.js which has no default export

turning the esModuleInterop to true in tsconfig.json solves this.