【问题标题】:Using Syncfusion FileManager with NuxtJS将 Syncfusion FileManager 与 NuxtJS 一起使用
【发布时间】:2021-10-10 07:43:48
【问题描述】:

我正在尝试将Syncfusion Vue FileManager 与 NuxtJS 一起使用。

<template>
  <div>
    <h1>Test Page</h1>
    <ejs-filemanager></ejs-filemanager>
  </div>
</template>

<script>
import Vue from 'vue';
import { FileManagerPlugin } from '@syncfusion/ej2-vue-filemanager';

Vue.use(FileManagerPlugin);
export default {
  auth: false,
};
</script>

<style scoped>
@import '../node_modules/@syncfusion/ej2-base/styles/material.css';
@import '../node_modules/@syncfusion/ej2-icons/styles/material.css';
@import '../node_modules/@syncfusion/ej2-inputs/styles/material.css';
@import '../node_modules/@syncfusion/ej2-popups/styles/material.css';
@import '../node_modules/@syncfusion/ej2-buttons/styles/material.css';
@import '../node_modules/@syncfusion/ej2-splitbuttons/styles/material.css';
@import '../node_modules/@syncfusion/ej2-navigations/styles/material.css';
@import '../node_modules/@syncfusion/ej2-layouts/styles/material.css';
@import '../node_modules/@syncfusion/ej2-grids/styles/material.css';
@import '../node_modules/@syncfusion/ej2-vue-filemanager/styles/material.css';
</style>

这是我的示例页面,我想在其中使用 FileManager。不幸的是,在启动服务器时导入FileManagerPlugin 会导致图片中的错误。

我已将以下依赖项添加到我的package.json

"@syncfusion/ej2-vue-filemanager": "^19.2.48",
"vue-class-component": "^7.2.6",

我也收到错误:

in ./node_modules/@syncfusion/ej2-vue-filemanager/src/file-manager/filemanager.component.js                                           friendly-errors 11:49:40  

"export 'Options' was not found in 'vue-class-component'

但如果不安装vue-class-component,它根本不会启动。

【问题讨论】:

  • 我们已经在 Nuxt 中使用最新的 Syncfusion Vue 软件包遇到了类似的 Vue 问题,并认为这是一个错误。我们预计它将在 8 月中旬之前包含在我们的 2021 年第 2 卷 SP 版本中。

标签: nuxt.js syncfusion ej2-syncfusion


【解决方案1】:

看这个Github issue,看来你需要安装(至少)
vue-class-component : 8.0.0-rc.1

【讨论】:

    【解决方案2】:

    上述问题已在我们最新的 NuGet 19.2.55 中得到解决。请更新软件包以解决问题。

    【讨论】:

    • 您能否使用发布页面等来源编辑您的答案?
    • 第 2 卷 SP 的下载链接是 here
    猜你喜欢
    • 2018-06-10
    • 2020-02-24
    • 2019-12-28
    • 2021-08-18
    • 1970-01-01
    • 2023-03-07
    • 2021-02-18
    • 2021-02-12
    • 2019-05-18
    相关资源
    最近更新 更多