title: Can I import packages into a Svelte Component?
body: <p>I'm trying to write a front-end for an app that I've built. Having just learned about Svelte, I thought it would give me reason to explore the framework further. The Svelte boilerplate that I use leverages rollup as a way to compile the code.</p>
  
  <p>When I attempt to import the "coinbase-pro" npm package into one of my Components, rollup keeps throwing an error in the browser console along the lines of "coinbasePro is not defined". </p>
  
  <p>I've spent countless errors now scouring google and tweaking my rollup config but to no avail. I've added plugins, altered the rollup globals and externals, and just about anything else you can think of. </p>
  
  <p>When the bundle.js file is created, it tries to pass the "coinbasePro" reference into the parameter of the outside app function. </p>
  
  <p>Getting back to my original question, is there a way to import packages into a Svelte component?</p>
  
  <p>Update Rollup JS Config for Globals and Externals. 
  Imported the Package into other JS files.</p>
  
  <p>I get a console reference error in my browser that says the NPM package is not defined.</p>