← All pipes
Text

capitalize

Uppercase the first code unit.

Use it in your component

Standalone component
import { Component } from '@angular/core';
import { CapitalizePipe } from 'extra-pipe';

@Component({
  standalone: true,
  imports: [CapitalizePipe],
  template: `{{ 'angular' | capitalize }}`,
})
export class ExampleComponent {

}

Template
{{ 'angular' | capitalize }}

Try it live.

The output below runs the packed library. Edit data, not code.

Use double quotes for text, or a number, array, object or null.
No parameters: use []. Locale is controlled separately.
This pipe has no locale override.
Live template data
readonly value = "angular";

{{ value | capitalize }}

Rendered output

Angular