# Dynamically Load CSS with the Angular CLI

DevFeed: [Dynamically Load CSS with the Angular CLI](<https://devfeed.tech/articles/dynamically-load-css-with-the-angular-cli-21350.md>)

Original publisher: [Read original article](<https://juri.dev/blog/2019/08/dynamically-load-css-angular-cli/>)

Published: 2019-08-22T00:00:00Z

Content type: tutorial

Language: en

Sources: [Juri Strumpflohner](<https://devfeed.tech/sources/juri-strumpflohner.md>)

Topics: [Angular CLI](<https://devfeed.tech/topics/angular-cli.md>), [lazy loading](<https://devfeed.tech/topics/lazy-loading.md>), [Angular](<https://devfeed.tech/topics/angular.md>), [CSS](<https://devfeed.tech/topics/css.md>), [Sass](<https://devfeed.tech/topics/sass.md>), [Web Development](<https://devfeed.tech/topics/web-development.md>)

Tags: [angular](<https://devfeed.tech/tags/angular.md>), [cli](<https://devfeed.tech/tags/cli.md>), [css](<https://devfeed.tech/tags/css.md>), [egghead](<https://devfeed.tech/tags/egghead.md>), [lazy-loading](<https://devfeed.tech/tags/lazy-loading.md>), [runtime](<https://devfeed.tech/tags/runtime.md>), [sass](<https://devfeed.tech/tags/sass.md>), [themes](<https://devfeed.tech/tags/themes.md>), [tooling](<https://devfeed.tech/tags/tooling.md>)

## AI overview

The excerpt describes using Angular CLI to produce separate CSS or Sass entry points for themes, then loading a selected stylesheet at runtime by adding a link element to the document head. Configure the extra styles so the CLI emits them without including them in the app's initial styles; otherwise later theme rules can override earlier ones. A dedicated service can encapsulate loading, with theme selection driven by login state or configuration. The excerpt cuts off during its development-mode note, so it does not establish how runtime loading behaves there.

## Source excerpt

Lorem ipsum dolor sit amet