Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Nov 12 23:03
    mattp94 edited #9942
  • Nov 12 23:02
    mattp94 edited #9942
  • Nov 12 22:58
    mattp94 review_requested #9942
  • Nov 12 22:58
    webpack-bot labeled #9942
  • Nov 12 22:58
    mattp94 synchronize #9942
  • Nov 12 18:09
    sokra synchronize #7075
  • Nov 12 18:09

    sokra on v5.0.0-beta.4

    (compare)

  • Nov 12 18:09

    sokra on master

    5.0.0-beta.4 (compare)

  • Nov 12 17:45
    sokra synchronize #7075
  • Nov 12 17:45

    sokra on ci-azure-pipelines-cache

    (compare)

  • Nov 12 17:45

    sokra on master

    ci: azure-pipelines cache Merge pull request #9962 from w… (compare)

  • Nov 12 17:45
    sokra closed #9962
  • Nov 12 17:45
    webpack-bot labeled #9962
  • Nov 12 17:45
    webpack-bot unlabeled #9962
  • Nov 12 17:39
    sokra synchronize #7075
  • Nov 12 17:39

    sokra on master

    feat: support caching in Source… fix review use SyncHook for afterFinishAss… and 5 more (compare)

  • Nov 12 17:39
    sokra closed #9839
  • Nov 12 16:28
    evilebottnawi reopened #9962
  • Nov 12 16:28
    evilebottnawi closed #9962
  • Nov 12 16:25
    webpack-bot labeled #9962
deAtog
@deAtog
@harshit786 I think this is a case where you are simply using Webpack wrong. Just because you can reference Webpack outputs from the dist folder doesn't mean you should. Doing so is often discouraged because it creates a client-side caching issue. I.e. the browser caches the page and it's assets separately. However, if the page has not been modified, the browser may not check if the assets have been. If you want to continue using static pages.. then I would recommend making your html files your Webpack entrypoints and using the html-loader in combination with the extract-loader. Encore doesn't support processing of HTML files so you would have tell it to load the additional loaders required to do so.
Rogan Louwrens
@hallucinarium
Can anybody tell me how to get the hashed filename of a font imported in a CSS file? This issue is infuriating me
deAtog
@deAtog
@hallucinarium Why not use Encore since you are already using Symfony?
Rogan Louwrens
@hallucinarium
@deAtog Oh, I'm not using Symfony. I'm building a Gridsome site, which afaik uses vanilla webpack?
deAtog
@deAtog
@hallucinarium Sorry, my mistake.. mistook you for someone else..
deAtog
@deAtog
@hallucinarium have you tried using the url-loader?
Rogan Louwrens
@hallucinarium
Yes, I'm using the url-loader. I just don't know which variable holds the path of the font after import
Jake
@jakeacooley
I'm getting a strange Webpack issue where a file is being imported and it's not being recognized within the file. Whenever I refresh it is imported and read perfectly fine. Could this be a code-splitting issue?
John Marinelli
@johnmarinelli
@deAtog I see, thanks for the input. funny that you bring the externals issue up - i have been configuring our webpack config and have been spending a lot of time with the externals option (and this plugin https://github.com/liady/webpack-node-externals), so i can cherry-pick which modules i want to include for a given entry point
my company was considering migrating to Encore but we have a 10 year old project with lots of code, so we are continuing with our custom config
@jakeacooley can you post a config. what do you mean "when i refresh" - you refresh the page?
is this file being dynamically imported?
Stephen Hendricks
@z1haze
when running webpack --mode=development and then checking process.env.WEBPACK_MODE in the webpack.config.js is always undefined? how do we actually use that flag to do things in the config?
Chris
@ipatch
hello, i'm using style-loader with css-loader and i'm trying to add some styles to a class I've added via JS using the DOM, and have imported my styles.css within my index.js but i'm still nto seeing the styles being applied to my custom class. however if i change the style of something like body then the style is applied.
sdyalor
@sdyalor
.
Chris
@ipatch
ohh wow my webpack is hashing my classnames
sdyalor
@sdyalor
I'm new in webpack
;c
Hope i could help you in a couple of years
but there is a property in configuration file
Captura.PNG
Răzvan Idomir
@tsuby
Hi there, is there a way to simulate '[contenthash]' in webpack 3? I need it to basically have a library exposed with a static file name (where the '[contenthash]' would function as a lib version)
For just one file, for the others I still need to use '[hash]'
Peter Müller
@Munter
It's just a string, you can put anything in there. For example libname.${require('./package.json').version}.js
Erwann Mest
@kud
hey
I've got a weird thing in the shell
 Entrypoint undefined = index.html
My code
    entry: ["react-hot-loader/patch", `${SRC_DIR}/index.js`],
It doesn't break anything, my webpack works like a charm, but why I've got this undefined?
Răzvan Idomir
@tsuby
@Munter Using [contenthash] would've also been a mechanism to automatically update the "version" number whenever necessary without additional hassle. Thank you for your suggestion, I'll use it :)
ronaklalwaniii
@ronaklalwaniii
Any good tutorial out there to learn webpack? I am a newbie
Diego Gullo
@bizmate
ronaklalwaniii
@ronaklalwaniii
Thanks, @bizmate i'll check it out.
Peter Müller
@Munter
@tsuby So you just want all files to be content addressable? I highly recommend upgrading your webpack version to opt into those new things
Asim KT
@asimqt
Hi, Can I run my webpack configuration sequentially?.
module.exports = [
  {
    ...webpackConfig,
    ...resolveConfig,
    ...{
      entry: customEntry,
      plugins: enhancedPlugin,
      output: customOutput
    },
    externals
  },
  {
    ...webpackConfig,
    ...resolveConfig,
    ...{
      entry: customEntry,
      plugins: enhancedPlugin,
      module: { ...webpackModule, ...{ rules: enhancedRules } }
    }
  }
];
I actually want one normal bundling for all files and one special library bundling for one specific file. Now things are working in my favor. (It's not perfect) But I want the order to be specified.
Asim KT
@asimqt
Anyone? :)
John Marinelli
@johnmarinelli
@asimqt here is the entrypoint for Multi-config webpack: https://github.com/webpack/webpack/blob/master/lib/webpack.js#L35
it looks like order should be whatever you have in module.exports
Asim KT
@asimqt
mm.. I tried that. In my local system, the order is fine and it's building in different order. Is there a chance that the compiler.run(callback) code will run it in parellel?
@johnmarinelli
Thanks.
John Marinelli
@johnmarinelli
@asimqt i'm not sure because I didn't dig too deep in the code
i think it does though. we use a multi config, but it's an Object, not an Array. the order is the same each time and is alphabetical
Peteris Erins
@Pet3ris

I'm using css-loader to import CSS files while also doing css-in-js using bs-css after the css-loader import has been loaded.

The problem - it seems like the css order between the two files is not deterministic. Sometimes one loads ahead, other times it's the other. Are there any ways to control where styles will be loaded onto the page?

M Xu
@mx2323
hey everyone
ive spent the last few days trying to get my CRA app ported to electron :(
between webpack, babel and eslint issues im really confused.