
Security News
The Hidden Blast Radius of the Axios Compromise
The Axios compromise shows how time-dependent dependency resolution makes exposure harder to detect and contain.
@lithiumjs/angular
Advanced tools
Reactive components made easy. Lithium provides utilities that enable seamless reactive state and event interactions for Angular components.
Reactive components made easy! Lithium provides utilities that enable seamless reactive state and event interactions for Angular components.
Check out the full README for more information.
Reactive component state
Lithium's ComponentStateRef service exposes a type-safe representation of component state properties as Subjects, allowing for observation of the component's full state automatically:
import { ComponentState, ComponentStateRef } from '@lithiumjs/angular';
@Component({
...
providers: [ComponentState.create(MyComponent)]
})
class MyComponent {
public value = 0;
constructor (stateRef: ComponentStateRef<MyComponent>) {
stateRef.get('value').subscribe(value => console.log("value: ", value));
this.value = 100;
}
// Output:
// value: 0
// value: 100
}
Reactive lifecycle decorators
Lithium adds support for reactive component events, including decorators for component lifecycle events:
import { OnInit } from '@lithiumjs/angular';
@Component({...})
class MyComponent {
@OnInit()
private readonly onInit$: Observable<void>;
constructor () {
this.onInit$.subscribe(() => console.log("Reactive ngOnInit!"));
}
}
Works with Angular component decorators
You can use Angular's built-in component decorators with Lithium. Use an @Input as a Subject and listen to a @HostListener event as an Observable!
Zoneless change detection made easy
By tracking component state changes automatically, Lithium's AutoPush feature allows you to easily write more performant components using Zoneless change detection and OnPush.
Beyond async
Lithium automatically manages subscription lifetimes just like Angular's async pipe, without the syntax overhead.
Lithium can be installed via npm using the following command:
npm install @lithiumjs/angular
Check out the full README for more information, including usage guides and API documentation.
FAQs
Reactive components made easy. Lithium provides utilities that enable seamless reactive state and event interactions for Angular components.
The npm package @lithiumjs/angular receives a total of 915 weekly downloads. As such, @lithiumjs/angular popularity was classified as not popular.
We found that @lithiumjs/angular demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
The Axios compromise shows how time-dependent dependency resolution makes exposure harder to detect and contain.

Research
A supply chain attack on Axios introduced a malicious dependency, plain-crypto-js@4.2.1, published minutes earlier and absent from the project’s GitHub releases.

Research
Malicious versions of the Telnyx Python SDK on PyPI delivered credential-stealing malware via a multi-stage supply chain attack.