Git Product home page Git Product logo

Comments (6)

AHopes avatar AHopes commented on May 23, 2024 1

/* global webpack_public_path:writable */
可以试着加下这个,我的解决了,是eslint不允许访问变量

from micro-frontends-practice.

AHopes avatar AHopes commented on May 23, 2024

请问下解决了吗

from micro-frontends-practice.

liuxuzxx avatar liuxuzxx commented on May 23, 2024

运行了下react_也是报这个错误

from micro-frontends-practice.

liuxuzxx avatar liuxuzxx commented on May 23, 2024

/* global webpack_public_path:writable */
可以试着加下这个,我的解决了,是eslint不允许访问变量

这个是注释加到public-path.js文件当中?

from micro-frontends-practice.

AHopes avatar AHopes commented on May 23, 2024

是的

from micro-frontends-practice.

easy11 avatar easy11 commented on May 23, 2024

还可以在public-path.js里面写一行注释 // eslint-disable-next-line no-undef 即可解决eslint的这个报错。public-path.js的完整代码如下

if (window.__POWERED_BY_QIANKUN__) {
  // eslint-disable-next-line no-undef
  __webpack_public_path__ = window.__INJECTED_PUBLIC_PATH_BY_QIANKUN__;
}

qiankun官方文档里有这段代码,不要随便改或者删掉那行注释,是有用的~

from micro-frontends-practice.

Related Issues (6)

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.