Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

uppercase angular pipe

      
      {{ value_expression | uppercase }}
    
Comment

angular pipe to capitalize first letter

transform(value:string): string {
  let first = value.substr(0,1).toUpperCase();
  return first + value.substr(1); 
}
  
Comment

angular capitalize pipe

import { Pipe, PipeTransform } from '@angular/core';

@Pipe({
  name: 'capitalize'
})
export class CapitalizePipe implements PipeTransform {
  transform(value: string, ...args: string[]): string {
    return value.toLowerCase().charAt(0).toUpperCase() + value.toLowerCase().slice(1);
  }
}
Comment

PREVIOUS NEXT
Code Example
Javascript :: regex for numbers and decimals only 
Javascript :: js for each character in string 
Javascript :: jquery set checkbox 
Javascript :: loop through checkboxes jquery 
Javascript :: eslint change max line length 
Javascript :: remove all html tags from string javascript 
Javascript :: sort array of object js 
Javascript :: angular ERROR Error: ExpressionChangedAfterItHasBeenCheckedError: Expression has changed after it was checked. 
Javascript :: javascript split get last element 
Javascript :: get radio button value javascript 
Javascript :: remove curly brackets from stringify javascript 
Javascript :: how to get session value using javascript 
Javascript :: javascript live time 
Javascript :: bootstrap not working in angular 
Javascript :: typescript read url parameters 
Javascript :: how to clear inner html using jquery 
Javascript :: jquery success refresh page 
Javascript :: node downgrade windows 
Javascript :: tolowercase javascript 
Javascript :: javascript filter array by another array 
Javascript :: js stop form submit on enter 
Javascript :: how to assign port in angular 
Javascript :: Failed to transform react-native-reanimated-65.aar 
Javascript :: react native status bar color 
Javascript :: select a form by name jquery 
Javascript :: primera letra en mayuscula javascript 
Javascript :: split string by uppercase javascript 
Javascript :: javascript snumber two decimal places as string 
Javascript :: how to detect safari browser in javascript 
Javascript :: check for url change js 
ADD CONTENT
Topic
Content
Source link
Name
1+3 =