Angular Composition API
Composition API and supporting libraries for writing functional Angular applications.
function setup() {
const service = inject(Service)
const count = use(0)
subscribe(count, () => {
service.log(count.value)
})
return {
count,
}
}
RFC
This repository is a reference implementation for this RFC discussion.
Packages
Name | Description |
---|---|
Core | Composition model for writing functional reactive Angular applications. |
Boundary | Error Boundary and Suspense implementation for Angular. |
Store | State management library for Angular Composition API. |
Resource | Data fetching library for Angular Composition API. |
Contributing
-
Clone this repository.
-
Run
yarn
inside the project root. -
Run
ng test
to ensure tests are passing. -
Run
ng build [package]
to build the library. -
Run
ng link
fromdist/[package]
andng link @mmuscat/[package]
to link the build files to your workspace -
Run
ng serve
to check the example application works.