instantsearch: Missing vue-server-renderer/basic module on build
Bug 🐞
What is the current behavior?
Currently after building my app, the vue cli shows the following error:
warning in ./node_modules/vue-instantsearch/dist/vue-instantsearch.esm.js
Module not found: Error: Can't resolve 'vue-server-renderer/basic' in 'C:\code\classpass\app\node_modules\vue-instantsearch\dist'
Does this happen only in specific situations? And What is the version you are using?
This only happened right after I upgraded dependencies for algolia related items:
- algoliasearch
- from 4.2.0 to 4.3.0
- vue-instantsearch
- from 2.7.0 to 3.1.0
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Reactions: 5
- Comments: 15 (7 by maintainers)
Hi, sorry to hijack this conversation but i think this could be helpful: The easiest way to solve this is by using webpack externals in your projects:
In a Laravel Mix configuration file you can do so like this:
I’m seeing a similar issue with the same
vue-server-renderer/basic
, but it’s only a warning, not an error:The resulting app bundle still seems to work, but it’s just showing this warning.
I’ve setup a minimal repo with Laravel Mix (same as my production setup) if this helps: https://github.com/saltymouse/algolia-vue-instantsearch-module-warning
Yup, just ran into this issue myself;
the workaround does not work though,
Adding the unused library fixes the issue:
Also having the same issue with webpack and could not solve it with
npm install vue-server-renderer/basic --save
as this triggers a permission denied issue, so I had to install the whole packagenpm install vue-server-renderer --save
@Kocal apologies - I thought you had all the information you needed above.
I’ve solved this by doing a
npm install vue-server-renderer/basic --save
but as someone said that installs a dependency I don’t need.Happy to give you all the details you need to debug this. Can you let me know what would help?