nolanlawson/blob-util

undefined

Aleksey-Danchin opened this issue · 3 comments

Hi. In nodejs project add blob-util through :~$ npm install blob-util --save. ES6 module work, import finds module, it's ok. But blobUtil is undefined.

import blobUtil from 'blob-util'
console.log(blobUtil) // undefined

How are you using ES6 imports? Babel, esm, Webpack, --experimental-modules, something else? Node doesn't natively support ES6 modules. Also blob-util does not support Node, only the browser. :)

You might also try import * as blobUtil from 'blob-util'.

I updated the installation instructions after playing around with TypeScript and esm. https://github.com/nolanlawson/blob-util#install I'm pretty sure you want to use import * as blobUtil, please reopen if I'm wrong.