Can I use search vue widget in nuxt.js?

Hi @ggavrilov

I found a solution: I’m not a Webpack expert, so it’s hard for me to say exactly where the blocking error is coming from, but if I define a couple of aliases for the clients modules, I finally have the project working with no errors:

const path = require('path');

export default {
  build: {
    extend(config) {
      config.resolve.alias["@datocms/cma-client"] =
        path.resolve(__dirname, 'node_modules/@datocms/cma-client/dist/cjs')
      config.resolve.alias["@datocms/cma-client-browser"] =
        path.resolve(__dirname, 'node_modules/@datocms/cma-client-browser/dist/cjs')
      
      config.module.rules.push({
        test: /\.mjs$/,
        include: /node_modules/,
        type: 'javascript/auto',
      })
    },
  },
}

With that Webpack config in place, I’m able to build a working page similar to the one available in this example. :slight_smile: