question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Missing vue-server-renderer/basic module on build

See original GitHub issue

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

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:5
  • Comments:13 (6 by maintainers)

github_iconTop GitHub Comments

23reactions
Skullbockcommented, Nov 6, 2020

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:

externals: {
    'vue-server-renderer/basic': 'vue-server-renderer/basic'
}

In a Laravel Mix configuration file you can do so like this:

mix.webpackConfig({
        externals: {
            'vue-server-renderer/basic': 'vue-server-renderer/basic'
        }
})
5reactions
saltymousecommented, Sep 2, 2020

I’m seeing a similar issue with the same vue-server-renderer/basic, but it’s only a warning, not an error:

warning  in ./node_modules/vue-instantsearch/dist/vue-instantsearch.esm.js

Module not found: Error: Can't resolve 'vue-server-renderer/basic' in '/Users/saltymouse/webdev/my-app/node_modules/vue-instantsearch/dist'

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

Read more comments on GitHub >

github_iconTop Results From Across the Web

`Module not found: 'vue-server-renderer'` - Stack Overflow
It seems that we have to install the two packages: the vue-server-renderer and then the @vue/server-test-utils .
Read more >
@vue/server-renderer | Yarn - Package Manager
Fast, reliable, and secure dependency management.
Read more >
@vue/compat - npm
Overview. @vue/compat (aka "the migration build") is a build of Vue 3 that provides configurable Vue 2 compatible behavior.
Read more >
Server-Side Rendering - Vite
Vite provides built-in support for server-side rendering (SSR). The Vite playground contains example SSR setups for Vue 3 and React, which can be...
Read more >
Rendering a list of Vue components - Learn web development
This is a built-in Vue directive that lets us include a loop inside of our template, repeating the rendering of a template feature...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found