Skip to content

Support "security" on @angular-devkit/build-angular:browser #29959

@SophieDefendi

Description

@SophieDefendi

Command

build, config

Description

In angular.json the builder @angular-devkit/build-angular:browser does not seem to currently support "autoCsp": true when passed as follows:

{
  "$schema": "./node_modules/@angular/cli/lib/config/schema.json",
  "version": 1,
  "newProjectRoot": "projects",
  "projects": {
    <project>: {
      ...
      "architect": {
        "build": {
          "builder": "@angular-devkit/build-angular:browser",
          "options": {
            ...
            "security": {
              "autoCsp": true
            }
          }
        }
      }
    }
  }
}

It impacts the builder @angular-devkit/build-angular:browser, which means is not possible to both have autoCSP and to extend webpack.

Describe the solution you'd like

No response

Describe alternatives you've considered

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions