nuxt / framework

Old repo of Nuxt 3 framework, now on nuxt/nuxt
https://nuxt.com
10.64k stars 1.05k forks source link

vue-easytable does not provide an export named 'default' #6254

Closed BITRU closed 2 years ago

BITRU commented 2 years ago

Environment


Reproduction

yarn add vue-easytable

plugins/vue-easytable.client.ts - if not .client will fail

import VueEasytable from 'vue-easytable'
export default defineNuxtPlugin((nuxtApp) => {
  nuxtApp.vueApp.use(VueEasytable)
})
defineNuxtConfig({  build: {
    transpile: ['vue-easytable'],
  },})

Describe the bug

fail to run with error

Uncaught SyntaxError: The requested module '/_nuxt/node_modules/vue-easytable/libs/main.js?v=e7b2d731' does not provide an export named 'default' (at vue-easytable.client.ts:1:1)

Additional context

No response

Logs

No response

danielroe commented 2 years ago

Looks like you might also need to add to vite.optimizeDeps.include: https://vitejs.dev/config/dep-optimization-options.html#optimizedeps-include.