title: How to import npm module in JavaScript stimulus
body: <p>I want to use <code>imageToZ64()</code> from <a href="https://www.npmjs.com/package/zpl-image" rel="nofollow noreferrer">zpl-image</a> module </p>
  
  <p>I have installed it using: <code>npm install zpl-image</code></p>
  
  <p>and then I import it: <code>import './../../../node_modules/zpl-image';</code></p>
  
  <p>but when I use the fucntion like this  <code>let res = imageToZ64(canvas);</code>
   i'm getting : Uncaught (in promise) ReferenceError: imageToZ64 is not defined</p>
  
  <p>I tried to import it like this: <code>import { imageToZ64 } from  './../../../node_modules/zpl-image/zpl-image';</code> </p>
  
  <p>but the problem is this function uses other functions from pako.js which is another js file in the zpl-image.
  my question is how to import the module in a way that I can be able to access all the functions?</p>