Code Monkey home page Code Monkey logo

Comments (9)

QingWei-Li avatar QingWei-Li commented on March 28, 2024

是用 webpack 打包的?看起来是字体文件的 loader 没有配置对

from element.

perfectyang avatar perfectyang commented on March 28, 2024

我刚提了个pr ,看能不能通过,因为公司正在用这套ui

from element.

perfectyang avatar perfectyang commented on March 28, 2024

{
test: /.(woff2?|eot|ttf|otf)(?.*)?$/,
loader: 'url',
query: {
limit: 20000,
name: 'fonts/[name].[ext]?[hash:7]'
}
}
这是我的webpack配置, 我在vue文件里面直接将@import 'element-ui/lib/theme-default/index.css';引进去

from element.

QingWei-Li avatar QingWei-Li commented on March 28, 2024

http://localcaiwu.soouya.com 是啥?你用 nginx 之类的做代理的?有配置 fonts/ 目录 rewrite 么

from element.

perfectyang avatar perfectyang commented on March 28, 2024

nginx 作转发, 在nginx配置如下:

server {
    listen       80;
    server_name  localcaiwu.soouya.com;

    location ~ ^/redwood/.*\.do {
        proxy_set_header Host devhongshan.soouya.com;
        proxy_pass http://devhongshan.soouya.com; #开发
        #proxy_set_header Host testcaiwu.soouya.com;
        #proxy_pass http://testcaiwu.soouya.com;
    }
    location / {
        proxy_pass http://localhost:3070;
        #proxy_set_header Upgrade $http_upgrade;
        #proxy_set_header Connection "upgrade";
        #proxy_set_header Host $host;
    }
}

from element.

QingWei-Li avatar QingWei-Li commented on March 28, 2024

那你并没有 rewrite 静态资源文件啊,我也没配过,不过肯定漏了些配置 🌚

from element.

perfectyang avatar perfectyang commented on March 28, 2024

奇怪的是,在mac开发,就不会报这个问题

from element.

QingWei-Li avatar QingWei-Li commented on March 28, 2024
location ~ ^/(?:fonts)/ {
  break;
}

maybe

from element.

perfectyang avatar perfectyang commented on March 28, 2024

我试试

from element.

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.