Category "webpack"

How to add custom font in react-pdf/pdf

Can anyone say how to add custom font with @react-pdf/pdfkit in react.js? I tried to use doc.registerFont(path, font_family) But its showing an error like Unhan

Angular 13 and Karma: ReferenceError: global is not defined

i know there are many posts on this subject but nothing has helped so far. Such things like (window as any).global = window in polyfills.ts didn't work Angular:

React native web storybook react-native-vector-icons problem icon

I'm developing a react native component on storybook, which uses react-native-paper and react-native-vector-icons. The problem is that I can't see the icons, I

VueLoaderPlugin Error: No matching use for vue-loader is found

I am using webpack within a Laravel Mix project. When my webpack.config.js looks like this, Webpack works without error: module.exports = { module: {

esbuild-loader not finding any imported module

I am trying to change from ts-loader/babel-loader to esbuild-loader As per doc, I did the swap from both to: { test: /\.tsx?$/, loader: 'esbuild-loader'

Angular:.Invalid configuration object. Webpack has been initialized using a configuration object that does not match the API schema

I just startred programing and in my first project on Angular i tried to use ng serve an then this error come out: initialized using a configuration object that

The token '&&' is not a valid statement separator in this version

On the way of installing Webpack on my React Project, the following problem hinders my progress: last step to configure the Webpack npm run build && nod

Typescript issue during compilation around `webpack/HashedModuleIdsPlugin`

I am getting compilation issue around HashedModuleIdsPlugin and typescript :( When compiling a TS project that allow JS, requires HashedModuleIdsPlugin and expo

webpack-dev-server app doesn't render my html instead I get Cannot GET /

I am trying to run my javascript app with webpack dev server and I don't get my index.html back, instead I get Cannot GET / with this error inside the console G

webpack.code build is broken after update postcss-loader from 3.0.0 to 4.1.0

I'm using lates webpack 4 (not 5) with latest CkEditor 5 and postcss-loader. Everything is fine, when I use postcss-loader 3.0.0. After update it to 4.1.0 I got

How to configure react-app-rewired to add a postcss plugin

How can I customize react-app-rewired config in CRA v5 to add a postcss plugin, for example this one? I checked react-app-rewired documentation and github issue

loadable-components: failed to asynchronously load component

I have created module A which is a component library for my React App. Which I plan on using on module B which is my actual React App. I have an index.js whereb

Error: Cannot find module 'webpack/lib/rules/DescriptionDataMatcherRulePlugin' Require stack:

I have webpack-cli installed on my laravel project. I don't know why first of all we need it to run my vue app but this is causing an error: When I run npm run

Cannot find module 'gifsicle' for loading image -webpack

I've created a webpack project. In that my project works on my machine, but in all of my teammates laptop who has ubuntu installed on their machine(mine is zori

How to fix webpack resolve-url-loader not working?

Resolve-url-loader is not resolving images/fonts in my css files. My folder structure is like this: src public images -banner-bg.jpg

Unable to set property 'wrap' of undefined or null reference

I'm building a bundle with webpack + babel for browser, targeting it to ES5. When I try to use it, an error Unable to set property 'wrap' of undefined or null r

How to Polyfill node core modules in webpack 5

webpack 5 no longer do auto-polyfilling for node core modules. How to fix it please? PS: I'm a beginner in development so solution must be well described fo me.

Webpack: How to export directly to global (without .default) containing stylesheet imports?

Context I have a webpack.config.js like this: /* Something here */ module.exports = { entry: { main: './src/index.js' }, output: { library: 'MyCl

How to avoid duplication of module "bn.js" in webpack production build?

I used webpack 4 for my app. Somehow, bn.js package takes up a lot in production build. The image shows that it takes up 594.22 KB of data. Is there any way to

Log current time during webpack watch

I'm trying to improve developer experience with webpack, and I want to log the current time when running watch command, so I know when an error occurs behind th