Skip to content

Instantly share code, notes, and snippets.

View coskuncakir's full-sized avatar

Coskun Cakir coskuncakir

View GitHub Profile
@coskuncakir
coskuncakir / slugify.pipe.ts
Last active May 29, 2023 12:28 — forked from djabif/slugify.pipe.ts
Angular Pipe to transform a string into a slug with turkish character support.
import { Pipe, PipeTransform } from '@angular/core';
@Pipe({ name: 'slugify' })
export class SlugifyPipe implements PipeTransform {
transform(input: string): string {
const trChars = {
'çÇ': 'c',
'ğĞ': 'g',
'şŞ': 's',
'üÜ': 'u',