Giter Site home page Giter Site logo

Comments (12)

nebulousGirl avatar nebulousGirl commented on May 22, 2024 1

If I manually navigate to the file, it exists, but it doesn't load at all in the browser from the browserSync blob. I don't see the file in Network.

Sorry, for all those comments, I'm commenting as I debug and find new stuff.

from wp-webpack-script.

nebulousGirl avatar nebulousGirl commented on May 22, 2024

I've found that publicPath is undefined in my webpack config rules generated by wpackio.

from wp-webpack-script.

nebulousGirl avatar nebulousGirl commented on May 22, 2024

[ { loader: 'file-loader', options: { name: '[name]-[hash:8].[ext]', outputPath: 'web/assets/', publicPath: undefined } } ]

from wp-webpack-script.

Deejay-Ste avatar Deejay-Ste commented on May 22, 2024

Hi, I have the same issue. Any ETA on this ?

from wp-webpack-script.

swashata avatar swashata commented on May 22, 2024

Hi,

I will take a look.

from wp-webpack-script.

swashata avatar swashata commented on May 22, 2024

Hi,

Could you please give me a repo for reproduction? I have checked some asset files and they do seem to work.

from wp-webpack-script.

swashata avatar swashata commented on May 22, 2024

I have checked with specific .woff files and they do work. Please share a repro repo so that I can look into it.

Also make sure you are on version 3.5.0 or greater.

from wp-webpack-script.

Deejay-Ste avatar Deejay-Ste commented on May 22, 2024

Hi, I don't have time to make a repo for this but it's actually pretty simple to reproduce. You have to make a fresh WordPress install and apply the example theme of this repo (this one), then install npm and composer dependencies. After add some fonts in the assets directory and declare them in src/theme/main.scss. Then run npm run start and you'll end up with the Webpack dev server running but the fonts won't be loaded (as seen on the screenshot).
screenshot

from wp-webpack-script.

Deejay-Ste avatar Deejay-Ste commented on May 22, 2024

Although if you run npm run build they'll load correctly.
screenshot-2

from wp-webpack-script.

swashata avatar swashata commented on May 22, 2024

Maybe it had something to do with style-loader. Please upgrade to v4.1.0. I have removed style loader in favor of HMR from mini-css-extract-plugin.

from wp-webpack-script.

Deejay-Ste avatar Deejay-Ste commented on May 22, 2024

Thanks, I tested the v4.1.0 and it works now. Like you said it might be because of style-loader. You can close this issue.

from wp-webpack-script.

swashata avatar swashata commented on May 22, 2024

Great...

from wp-webpack-script.

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.