ng-packagr
ng-packagr copied to clipboard
Files loaded by the StylesheetProcessor are not added to the graph
Type of Issue
[x] Bug Report
[ ] Feature Request
Description
If a style file is loaded by the nodeSassTildeImporter it is not added to the build graph and if that file changes, a new build is not triggered.
How To Reproduce
Folder structure:
├───app
│ app.component.html
│ app.component.scss
│ app.component.ts
│ app.varibales.scss
│ index.ts
│
├───app-header
│ app-header.component.html
│ app-header.component.scss
│ app-header.component.ts
│ app-header.service.ts
│ index.ts
│
├───app-menu
│ app-menu.component.html
│ app-menu.component.scss
│ app-menu.component.ts
│ app-menu.service.ts
│ index.ts
app.variables.scss
$header-height: 60px;
$view-port-menu: 280px;
app-header.component.scss
@import '../app/app.varibales.scss';
.app-header {
height: $header-height;
}
app-menu.component.scss
@import '../app/app.varibales.scss';
.app-menu {
width: $view-port-menu;
}
If a change is made to the app.variables.scss file ( which is only used in import statements and not directly in styleUrls of a component ), a new build is not triggered.
Expected Behaviour
If a change is made to a file imported in a style file, then a new build should be triggered.
Version Information
ng-packagr: 11.2.0
@angular/*: 11.2.0
typescript: 4.1.5
rxjs: 6.3.3
node: 14.15.4
npm/yarn: 1.22.5