Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Broken with Nuxt 3.12.3 : _interopRequireDefault2 is not a function #227

Open
julbd opened this issue Dec 27, 2024 · 1 comment
Open

Broken with Nuxt 3.12.3 : _interopRequireDefault2 is not a function #227

julbd opened this issue Dec 27, 2024 · 1 comment

Comments

@julbd
Copy link

julbd commented Dec 27, 2024

Description

Since Nuxt 3.13.2 (which removed their interop helper), typesense-instantsearch-adapter throws the following error :

Uncaught TypeError: _interopRequireDefault2 is not a function

It seems that typesense-instantsearch-adapter is unable to find and use babel's runtime helpers. But I don't see how to make it work in the Nuxt 3 build context. showcase-guitar-chords-search-nuxt-js have the same issue once nuxt is updated.

Steps to reproduce

Reproduction steps using the showcase :

git clone https://github.com/typesense/showcase-guitar-chords-search-nuxt-js.git

cd showcase-guitar-chords-search-nuxt-js

npm i

npm run dev # works

npm i [email protected] # or any following version

npm run dev # error

Metadata

  • typesense-js: 1.8.2 / tested on multiples versions
  • typesense-instantsearch-adapter: 2.8.0 / tested on multiples versions
  • Firefox 133.0
  • macOS 15.2
@julbd
Copy link
Author

julbd commented Dec 27, 2024

Resolved with :

 // nuxt.config.js
  alias: {
    'typesense-instantsearch-adapter': 'typesense-instantsearch-adapter/src/TypesenseInstantsearchAdapter.js',
  },

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant