title: Javascript - Import not found
body: <p>I'm trying to make a text-mask GitHub repository work with my laravel project, With this, I want to use a certain addon which allows me to mask an input field as a price. The GitHub repository I'm talking about is <a href="https://github.com/text-mask/text-mask/" rel="nofollow noreferrer">linked here</a></p>
  
  <p>The addon is called <code>createNumberMask</code> and on their github page it says the following in their documentation: </p>
  
  <pre><code>import createNumberMask from 'text-mask-addons/dist/createNumberMask'
  
  // First, you need to create the `numberMask` with your desired configurations
  const numberMask = createNumberMask({
     prefix: '',
     suffix: ' $' // This will put the dollar sign at the end, with a space.
  })
  
  // ...then pass `numberMask` to the Text Mask component as the mask
  </code></pre>
  
  <p>Now when I try to implement this into my own project it gives me the error saying that the import cannot be found. What is causing this?</p>
  
  <p>I have a blade file which has script tags at the bottom of it. The blade file looks like this,</p>
  
  <pre><code>@section('content')
  &lt;div class="row " style="color: white; width: 100%; margin: 0;" id="showEffect"&gt;
      &lt;div class="col-md-12 text-center" style="margin-top: 10rem"&gt;
          &lt;div class="row justify-content-md-center"&gt;
              &lt;div class="col-md-2"&gt;
                  &lt;input type="text" class="myInput form-control depth-5"&gt;
              &lt;/div&gt;
          &lt;/div&gt;
  
      &lt;/div&gt;
  &lt;/div&gt;
  
  
  &lt;script type="module"&gt;
  
      import createNumberMask from '/node_modules/text-mask-addons/dist/createNumberMask'
  
      const numberMask = createNumberMask({
          prefix: '€',
          suffix: '',
          allowDecimal: true,
      });
  
      var myInput = document.querySelector('myInput');
  
      var maskedInputController = vanillaTextMask.maskInput({
          inputElement: document.querySelector('myInput'),
          mask: numberMask
      });
  
  
  &lt;/script&gt;
  
  @endsection
  </code></pre>
  
  <p>Why is the import not working? The js file is inside the node_modules folder.</p>
  
  <p>APP.JS</p>
  
  <pre><code>require('./bootstrap');
  
  import TextMask from 'vanilla-text-mask/dist/vanillaTextMask';
  import createNumberMask from 'text-mask-addons/dist/createNumberMask';
  
  window.Vue = require('vue');
  
  window.events = new Vue();
  
  window.flash = function (message) {
      window.events.$emit('flash', message);
  };
  
  
  Vue.component('flash', require('./components/Flash.vue'));
  
  // Vue.component('product-view', require('./components/Products.vue'));
  // Vue.component('wysiwyg', require('./components/Wysiwyg.vue'));
  
  const app = new Vue({
  el: '#app',
  });
  
  const numberMask = createNumberMask({
  prefix: '€',
  suffix: '',
  allowDecimal: true,
  });
  
  var myInput = document.querySelector('myInput');
  
  var maskedInputController = vanillaTextMask.maskInput({
      inputElement: document.querySelector('myInput'),
      mask: numberMask
  });
  </code></pre>