V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX 提问指南
uudaoshi
V2EX  ›  问与答

Nuxtjs3 resolveComponent 参数无法使用变量的问题

  •  
  •   uudaoshi · 197 天前 · 110 次点击
    这是一个创建于 197 天前的主题,其中的信息可能已经有所发展或是发生改变。
    引入了 element-plus,使用了 @element-plus/nuxt

    resolveComponent 的参数想要使用后端返回的 ElButton 或 ElSelect,生成动态组件,但是后端返回的必定是变量,
    所以无法使用

    必须将 element-plus 所有的组件在 nuxt.config 里的 components 配置成 global: true,
    但是只看到配当前项目里目录的,如'~/components' 没有配 node_module 包里的,请问该如何做,各位大佬


    相关 issue
    https://github.com/nuxt/nuxt/issues/14036#issuecomment-1397340463
    目前尚无回复
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   2879 人在线   最高记录 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 24ms · UTC 13:32 · PVG 21:32 · LAX 06:32 · JFK 09:32
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.