Questions tagged [web-compiler]

A Visual Studio extension that compiles LESS, Sass Stylus, JSX, ES6 and CoffeeScript files.

https://marketplace.visualstudio.com/items?itemName=MadsKristensen.WebCompiler

Features

  • Compilation of LESS, Scss, Stylus, JSX, ES6 and (Iced)CoffeeScript files
  • Saving a source file triggers re-compilation automatically
  • Specify compiler options for each individual file
  • Error List integration MSBuild support for CI scenarios
  • Minify the compiled output
  • Minification options for each language is customizable
  • Shows a watermark when opening a generated file
  • Shortcut to compile all specified files in solution
  • Task Runner Explorer integration Command line interface
  • Integrates with Web Analyzer
56 questions
246
votes
27 answers

Browserslist: caniuse-lite is outdated. Please run next command `npm update caniuse-lite browserslist`

Recently, when I compile my scss files I get an error. The error message says: Browserslist: caniuse-lite is outdated. Please run next command npm update caniuse-lite browserslist First, as the message says, I ran npm update caniuse-lite…
Nick Mehrdad Babaki
  • 11,560
  • 15
  • 45
  • 70
30
votes
5 answers

Blazor CSS Isolation not working and not adding scope identifiers after migrating to .NET 5.0 and using SASS

I've recently migrated a pet project from Blazor .NET 3.1 to .NET 5.0 and am trying to switch to using css isolation. I've created a scss file (which compiles to a css file using the webcompiler extension) with the same prefix as my component: I've…
Matthew Conradie
  • 990
  • 2
  • 8
  • 17
10
votes
8 answers

"Web Compiler" compile on save not working

I am using web compiler but it will not compile my SASS structure unless I right-click on "compilerconfig.json" and select "Web-compiler" --> "Re-compile all files". When I use the other methods to trigger compile... When I save a SCSS-file (most…
Jesper Wilfing
  • 11,157
  • 5
  • 29
  • 32
10
votes
1 answer

How to create new compilerconfig.json Web compiler (Extension)?

I have project with a lot of less files, I'm used in Web compiler (developer Mads Kristensen) Extension for visual studio 2015. my way to create compilerconfig.json is to compile single file and then edit manually the file, to work with all the…
Liran Patimer
  • 101
  • 1
  • 1
  • 4
8
votes
2 answers

Why does @use not work in Web Compiler Visual Studio extension?

I'm running Visual Studio 2019 (16.3.9) using the Web Compiler extension (1.12.394) to compile scss files. Here is a simple case that works. I have a file - test.scss: $color: blue; .button { background-color: $color; } This gets compiled to…
gmeister_99
  • 221
  • 1
  • 3
  • 8
8
votes
2 answers

VS 2015 Web Compiler won't auto-compile .less files on save

I have installed Visual Studio 2015 and, since Web Essentials won't compile .less files anymore, I installed the Web Compiler add-on for compiling .less files. The issue is that I can't seem to set it up to auto-compile the .less file into .css on…
kerki
  • 125
  • 2
  • 5
8
votes
1 answer

Razor editor formatting not working after installing Web Essentials and Web Compiler

I've just rebuilt my machine with a fresh install of Visual Studio 2015. I've also installed the extensions for Web Essentials and Web Compiler but these seem to have caused a problem Say for example, prior to installing Web Essentials and Web…
Matthew Layton
  • 39,871
  • 52
  • 185
  • 313
7
votes
1 answer

Sass - Web Compiler replaces Url as relatives urls

I have a problem with Web Compiler with VS2015 Update 1 and Sass. In my Scss file, i declared some images as background. Example : .example { background-image: url(images/ex.jpg); } In the file compilerconfig.json, the outPutFile is not in the…
Zysce
  • 1,200
  • 1
  • 10
  • 35
6
votes
0 answers

I want to compile all my *.scss files residing in a folder using web compiler in VS2019

Is it possible to compile all .scss files residing in a folder using web compiler in Visual Studio 2019? I don't want to specify each and every file. I tried something like this. [ { "outputFile": "wwwroot/assets/css/pages/", "inputFile":…
Gaurav Chavan
  • 301
  • 3
  • 6
5
votes
0 answers

How to minify multiple JavaScript files using WebCompiler in Visual Studio?

I'm using Web Compiler for Visual Studio 2017. Compiling a single file is easy since the help is right there. However, I want to minify multiple JavaScript files in my project, and I can't find how. Here's the list of the files I…
4
votes
3 answers

Using .sass extension files on Visual Studio 2019

I am using Web Compiler extension to compile from scss files to css on Visual Studio 2019, and it works fine. However, when trying to incorporate bulma css framework that uses .sass extension files it seems not to recognize these files. Do you know…
lsh
  • 41
  • 1
  • 2
4
votes
0 answers

SCSS Compiler Extension for Visual Studio

I would like to compile SCSS into CSS in my Visual Studio Community 2015 and 2017 projects. The extensions I have come across are: Web Compiler (1 million downloads) Mindscape Web Workbench (282k downloads) just VS 2015 Sam Rueby's CompileSass The…
Mike Poole
  • 1,958
  • 5
  • 29
  • 41
4
votes
0 answers

VS 2015 WebCompiler - How to turn off 'use strict' in JS generated from JSX

The output JS file contains 'use strict' at the top of the file. Is it possible to turn this off?
Phil Haselden
  • 2,876
  • 3
  • 30
  • 25
4
votes
1 answer

Web Compiler generated an empty css from less file

Visual Studio generates an empty .css file when I compile a .less file. I have this problem in both Visual Studio 2015 and 2017. The file is being compiled because I just wrote something and I can see that it removes the text and overrides it with…
Liron Harel
  • 10,819
  • 26
  • 118
  • 217
4
votes
1 answer

Web Compiler: JavaScript file > 100KB minification error

I'm having a hard time finding out what options are available for different file types with Mads Kristensen's Web Compiler extension. Am I missing a list somewhere? We're having an issue with this error coming up: The code generator has deoptimised…
1
2 3 4