Giter Site home page Giter Site logo

Comments (13)

fengxianqi avatar fengxianqi commented on August 10, 2024

图片没上传成功,再上传来看看

from qiankun-example.

yousmellnice avatar yousmellnice commented on August 10, 2024

image

subVue 被拒绝访问了,

from qiankun-example.

yousmellnice avatar yousmellnice commented on August 10, 2024

fetch失败,查了下说是跨域?但是我看sub-vue中也是配了'Access-Control-Allow-Origin': '*',百思不得解

from qiankun-example.

fengxianqi avatar fengxianqi commented on August 10, 2024

这不是跨域,可能是sub-vue子应用没有启动成功,你单独访问一下sub-vue子应用看看能正常吗

from qiankun-example.

yousmellnice avatar yousmellnice commented on August 10, 2024

oooo,子应用app是可以单独访问的
image

from qiankun-example.

fengxianqi avatar fengxianqi commented on August 10, 2024

demo项目有增删什么代码吗?看看有没第三方资源啥的,参考这里: umijs/qiankun#1331

from qiankun-example.

yousmellnice avatar yousmellnice commented on August 10, 2024

难搞哦,没有修改过源代码;demo中也没见有什么第三方资源。。。。。。。

from qiankun-example.

lucky-zouzou avatar lucky-zouzou commented on August 10, 2024

这个看起来不像是跨域,会不会是你的webpack版本比较新,我今天遇到了类似的报错,把子应用里config.js里的jsonpFunction改成chunkLoadingGlobal

from qiankun-example.

daoliang avatar daoliang commented on August 10, 2024

如果说我要加一个外部的子应用,应该怎么加啊

我是直接在micro-app.js

{
name: 'text',
entry: '//localhost:8080/',
activeRule: '/text'
}

一直提示Uncaught TypeError: Failed to fetch

这个外部的子应用,跟qiankun 不是同一目录

from qiankun-example.

XiaoYT avatar XiaoYT commented on August 10, 2024

如果说我要加一个外部的子应用,应该怎么加啊

我是直接在micro-app.js

{ name: 'text', entry: '//localhost:8080/', activeRule: '/text' }

一直提示Uncaught TypeError: Failed to fetch

这个外部的子应用,跟qiankun 不是同一目录

子项目run了没,你还要去main文件下的.env声明一下你添加的子应用的端口号

from qiankun-example.

XiaoYT avatar XiaoYT commented on August 10, 2024

image
跨域问题应该是像我这样的吧,我是真的遇到跨域问题了,主应用我配置了proxy但是没有起作用,怎么搞呢

from qiankun-example.

daoliang avatar daoliang commented on August 10, 2024

我大概知道问题在哪了,我应该是跨域的问题,子项目run 起来了。我看下,怎么解决这个跨域的问题。

from qiankun-example.

guxuerui avatar guxuerui commented on August 10, 2024

本地的话, 把 127.0.0.1 改成 localhost 就不跨域了

import { registerMicroApps, start } from 'qiankun'

registerMicroApps([
  {
    name: "vue-app", // 必须与微应用注册名字相同
    entry: "http://localhost:5174", // 入口路径,开发时为微应用所启本地服务,上线时为微应用线上路径
    container: "#vue-app-container", // 微应用挂载的节点
    activeRule: "/micro-vue", // 当访问路由为 /micro-vue 时加载微应用
    props: {
      msg: "我是来自主应用的值-vue", // 主应用向微应用传递参数
    },
  },
  {
    name: "react-app",
    entry: "http://localhost:5175",
    container: "#react-app-container",
    activeRule: "/micro-react",
    props: {
      msg: "我是来自主应用的值-react",
    },
  }
]);

from qiankun-example.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.