Questions tagged as 'webpack'

1
answer

How to import an entire file (javascript) with WebPack?

I started to study WebPack now, I was able to use it normally, however, when I want to import something from another file I need to give: import {abc} from './my-file.js'; and the file that was imported: export function abc() { consol...
asked by 13.07.2018 / 09:27
1
answer

React build vs (?) Webpack?

I'm taking a React course. I have an understanding of what React is, and what problem it solves. However when I put CMD "create-react-app x" it shows some other commands that I can use in this project including "npm run build" which theoretic...
asked by 23.05.2018 / 16:14
1
answer

Webpack error with bootstrap-loader

I'm having trouble implementing the bootstrap-loader in the webpack. I get this error output on the console:    ERROR in   ./~/css-loader!/~/resolve-url-loader!/~/sass-loader?sourceMap!/~/bootstrap-loader/lib/bootstrap.styles.loader.js!./~/ b...
asked by 05.09.2016 / 17:52
0
answers

Webpack does not use Babel to transpile

Whenever I run the build of my project, the output is always the file generated by the webpack, with no signs that it has passed Babel. My settings look like this: package.json { "name": "webpack-test", "version": "1.0.0", "descriptio...
asked by 27.12.2018 / 11:31
0
answers

ASP.NET Core NPM and webpack / gulp

I created a project in asp.net core using the empty template ( dotnet new web ). As I researched, to add packages like Bootstrap or jquery , we have to use NPM, which basically adds package.json to the project root and keys ba...
asked by 20.03.2018 / 12:42
0
answers

How to set the images and fonts directory in Laravel-mix?

I'm using Laravel-mix in a personal project, however, without the presence of the Laravel Framework. When I command to generate the files, Laravel-mix reads the sass files and creates in the project root an images directory and a fonts. How d...
asked by 23.11.2017 / 03:44
1
answer

Dynamic Import with Webpack

In a VueJS application with template Webpack , I need to import a series of SVG's according to a user's parameters. SVG's are fixed files, but are loaded dynamically into the application. If I import all the files at once, the bundl...
asked by 13.10.2017 / 19:24
0
answers

Error in npm run watch - Can not read property 'install' of undefined

This error occurs when I do a "npm run watch". When I do a "npm run dev", it does not give this error. I have reinstalled all the npm and it did not solve ... any solution?     
asked by 18.07.2017 / 06:03
0
answers

Remove "dist" string from build with Webpack

I created a rule in my%% archives to be able to work with fonts within my webpack.config.js , but when I do scss to output build to load the file it stays as: /distfonts/minha_font.woff Since the folder is only...
asked by 18.07.2017 / 21:48
0
answers

Generate multiple .js files with webpack

I need to create several .js files for each .ts file, but I do not know how to configure webpack 2 to do this. var path = require('path'); var ExtractTextPlugin = require('extract-text-webpack-plugin'); var webpack = require('webpack'); var ht...
asked by 07.06.2017 / 16:53