2

Webpack is throwing this error: Module not found: Error: Can't resolve '@/utils/index'.

enter image description here

So, here's the nippy rundown:

  • This failing import above is made within the node library vue2-datepicker.

  • This date picker is used in a component, which is in turn registered to Vue in the entry script using require.context('base^/components/', true, /\.vue$/i).

  • This was working before when the entry script wasn't using require.context: import Component from "base^/components/component".

I have tried changing the ./webpack.config.js @ alias but without effect. Any ideas what's wrong?

Cheers, Matt


Here's the rundown of imports:

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.