Skip to content

Commit

Permalink
docs: update custom-storage documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
timdeschryver committed Oct 22, 2024
1 parent da77a40 commit c593586
Showing 1 changed file with 16 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,22 @@ export class MyStorageService implements AbstractSecurityStorage {
}
```

Then provide the class in the module:
Then provide the custom storage class in the `ApplicationConfig`:

```ts
export const appConfig: ApplicationConfig = {
providers: [
provideAuth({
// ..
}),
{ provide: AbstractSecurityStorage, useClass: MyStorageService },
],
};
```

## NgModule

You can also provide the storage class in a module using the `providers` array:

```ts
@NgModule({
Expand Down

0 comments on commit c593586

Please sign in to comment.