Skip to content

@keyframes causes an ERROR in Cannot read property 'type' of undefined #19106

@aserputko

Description

@aserputko

🐞 bug report

Affected Package

The issue is caused by package @angular/compiler or @angular-devkit/build-angular

Is this a regression?

Yes, the previous version in which this bug was not present was: 8.2

Description

Command `ng build --prod` stopped working when angular was updated from v8.2 to v9.0.

🔬 Minimal Reproduction

StackBlitz

Steps to reproduce the issue:

  1. Create a new app (angular version 9.0 or 10.0): ng new myapp --style=scss
  2. Open app.component.scss and follow styles:
// app.component.scss
@keyframes rotate {
    from {
        transform: rotate3d(0);
    }
    to {
        transform: rotate3d(0, 0, 10, 5deg);
    }
}
  1. Execute ng build --prod

🔥 Exception or Error

ERROR in Cannot read property 'type' of undefined

Screenshot 2020-10-12 at 16 10 17

🌍 Your Environment

Angular Version:


Angular CLI: 10.0.8
Node: 14.13.0
OS: darwin x64

Angular: 10.0.14
... animations, common, compiler, compiler-cli, core, forms
... platform-browser, platform-browser-dynamic, router
Ivy Workspace: Yes

Package                           Version
-----------------------------------------------------------
@angular-devkit/architect         0.1000.8
@angular-devkit/build-angular     0.1000.8
@angular-devkit/build-optimizer   0.1000.8
@angular-devkit/build-webpack     0.1000.8
@angular-devkit/core              10.0.8
@angular-devkit/schematics        10.0.8
@angular/cli                      10.0.8
@ngtools/webpack                  10.0.8
@schematics/angular               10.0.8
@schematics/update                0.1000.8
rxjs                              6.5.5
typescript                        3.9.7
webpack                           4.43.0

Anything else relevant?
Please add an error trace to save time for debugging.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions