All Questions
1,652
questions
0
votes
0
answers
19
views
SassError: Can't find stylesheet to import. - while importing styles from external package
I have a React application which use custom Webpack config. I want to add library for components, specifically @carbon/react in version 1.62.1, the newest available.
My application uses React 18, ...
0
votes
1
answer
36
views
Imported styles from scss module are undefined
I am using CSS Module and SCSS as my styling in my app, but when I import my styles as:
import styles from './landing.module.scss'
The imported styles is undefined.
I am using:
"css-loader":...
0
votes
1
answer
40
views
Avoid url resolution in scss files in Angular
I did a css -> scss migration on an existing Angular project using schematics-scss-migrate. Everything works fine except the URL's, if any, in scss files. So I found out that in scss files the URL'...
0
votes
0
answers
26
views
How could I profile a sass-loader compilation?
I'm using embedded-sass in an Angular custom webpack monorepo. One of my libraries with sass takes a significant amount of time just in sass-loader during the build and I'd like to figure out what I ...
0
votes
0
answers
11
views
Webpack not watching SCSS glob imported files
I am using webpack to compile my scss files which works fine when initially running npx webpack or npx webpack --watch.
When using npx webpack --watch, only my declared SCSS file (app.scss) in my ...
0
votes
1
answer
59
views
How can I prevent minify of CSS in Production using WebPack?
This may seem like a strange request but I am working on a site in HubSpot which will automatically minify my CSS and JS files for me before serving them to the browser.
I do my development using SCSS ...
0
votes
0
answers
26
views
How to split a css from a .scss mobile first using Webpack and Laravel Mix
Good morning. This is the code in my webpack.mix.js:
let mix = require("laravel-mix");
require("laravel-mix-compress");
mix.setPublicPath("assets");
mix
.sass("...
0
votes
0
answers
29
views
I am getting error while angular version updating (./src/main.ts - Error: Module build failed)
./src/main.ts - Error: Module build failed (from ./node_modules/@ngtools/webpack/src/ivy/index.js): Error: Transform failed with 1 error: C:/Users/WCR/Desktop/WhiteCrow/ATS/ats-crm-frontend/src/app/...
0
votes
0
answers
11
views
scss fonts files not laoded in webpack 5
The fonts which used in "styles/fonts" not loaded into app. the fonts imported into styles/base/fonts.scss file and fonts.scss imported into main.scss file directly.
But when running app in ...
0
votes
0
answers
18
views
Keep CSS in the bundle and extract it into a separate file simultaneously with webpack
Your webpack is currently set up as follows:
const path = require('path')
const TerserPlugin = require('terser-webpack-plugin');
const BundleAnalyzerPlugin = require('webpack-bundle-analyzer')....
2
votes
1
answer
194
views
Angular: Module parse failed: Unexpected token (1:0) importing scss variables
In our project we had a palette that we used to import styles across our project. It worked in Angular 13, but after going to Angular 14 it doesn't work anymore. Here are the details on it.
Error: ...
0
votes
1
answer
104
views
How to Override Bootstrap 5 Navbar Font Family Using SASS Variables?
I'm working with Bootstrap 5 in a sass project handled by webpack and I want to customize the font family of the navbar using SASS variables. I've tried various approaches, but I can't seem to get it ...
0
votes
0
answers
147
views
Tailwind classes are not generated or not added to css file
I have a react project, that is configured using webpack (no vite or create-react-app), uses scss for styling and electron.
I tried to integrate tailwind to it using official guides.
Created tailwind....
0
votes
0
answers
19
views
Differ style files from module style files
I'm writing webpack config for my React/TypeScript application. I want to generate unique names for classes and ids only if file name ending with .module.scss or .module.css
So I wrote these rules:
{
...
0
votes
1
answer
69
views
How do I configure webpack to ignore my non-existing resource in scss?
I receive an error when compiling my scss file.
In the .scss file I have:
body {
background-image: url("/static/background.webp");
}
This is the error I get:
error in ./...