Skip to content

Unable to use styles/scripts inside Angular Libraries #11443

@rpasechnikov

Description

@rpasechnikov

I would like to be able to use styles/scripts and hopefully other NPM modules inside of Angular 6.0 Libraries. I am able to do so in standard Angular projects but not inside of libraries as they do not contain a relevant angular.json file and the ng-package.json file provided does not contain the desired:

"styles": [ "src/styles.css" ], "scripts": []

I am not sure if this is a missing feature, currently in development or whether there are no plans to support this. It seems like this is an extremely basic feature to have for a module application design.

Hopefully I'm just missing something obvious! 😸

Bug Report or Feature Request (mark with an x)

- [ ] bug report -> please search issues before submitting
- [x ] feature request

Area

- [x ] devkit
- [ ] schematics

Versions

Angular CLI: 6.0.8
Node: 8.11.1
OS: win32 x64
Angular: 6.0.7
NPM: 6.0.0

Repro steps

The log given by the failure

N/A

Desired functionality

I should be able to use NPM packages, styles and scripts inside of angular library projects.

Mention any other details that might be useful

N/A

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions