-
Notifications
You must be signed in to change notification settings - Fork 12k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(@angular-devkit/build-angular): support autoprefixer/tailwind CS…
…S with Less/Sass in esbuild builder When using the esbuild-based browser application builder, Sass and Less stylesheets will now be post-processed with autoprefixer and/or Tailwind CSS when applicable. CSS stylesheets were already processed by these tools. Autoprefixer is queried based on the configured browserslist to determine if any processing is required and is not added to the build pipeline if no transformations are required. Likewise for Tailwind, if no Tailwind configuration file is present, Tailwind CSS will also not be added to the build pipeline. If both autoprefixer and Tailwind are not required, `postcss` (the tool used to post-process the stylesheets) itself is not added to the build pipeline. This removes the potential for unneeded build time overhead for projects that do not require these post-processing steps. The default browserslist currently does require the use of autoprefixer based on autoprefixer's prefix analysis.
- Loading branch information
Showing
7 changed files
with
377 additions
and
329 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 15 additions & 0 deletions
15
...ges/angular_devkit/build_angular/src/builders/browser-esbuild/stylesheets/css-language.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
/** | ||
* @license | ||
* Copyright Google LLC All Rights Reserved. | ||
* | ||
* Use of this source code is governed by an MIT-style license that can be | ||
* found in the LICENSE file at https://angular.io/license | ||
*/ | ||
|
||
import { StylesheetLanguage } from './stylesheet-plugin-factory'; | ||
|
||
export const CssStylesheetLanguage = Object.freeze<StylesheetLanguage>({ | ||
name: 'css', | ||
componentFilter: /^css;/, | ||
fileFilter: /\.css$/, | ||
}); |
191 changes: 0 additions & 191 deletions
191
packages/angular_devkit/build_angular/src/builders/browser-esbuild/stylesheets/css-plugin.ts
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.