Skip to content

Commit

Permalink
Reformat usage example
Browse files Browse the repository at this point in the history
  • Loading branch information
czeckd committed Sep 13, 2023
1 parent c784dfe commit db958ef
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ See the module's accompanying README.md for instructions.
The **angular-svg-icon** should work as-is with webpack/angular-cli. Just import the
``AngularSvgIconModule`` and the ```HttpClientModule```.

### Module Example

```typescript
import { HttpClientModule } from '@angular/common/http';
import { AngularSvgIconModule } from 'angular-svg-icon';
Expand All @@ -48,9 +50,11 @@ import { AngularSvgIconModule } from 'angular-svg-icon';
...
})
export class AppModule {}
```

// Standalone Example
### Standalone Example

```typescript
import { HttpClientModule } from '@angular/common/http';
import { SvgIconComponent, provideAngularSvgIcon } from 'angular-svg-icon';

Expand All @@ -65,7 +69,7 @@ export class AppModule {}
**BREAKING CHANGE**: as of [email protected], an explicit call to `forRoot()`
must be made on the module's import.

### Child modules
### Child Modules

Recommened usage pattern is to import `AngularSvgIconModule.forRoot()` in only the root AppModule of your application.
In child modules, import only `AngularSvgIconModule`.
Expand Down

0 comments on commit db958ef

Please sign in to comment.