Skip to content

Commit

Permalink
feat(trim): add transformer for trim
Browse files Browse the repository at this point in the history
  • Loading branch information
TomokiMiyauci committed May 21, 2023
1 parent ac30ed5 commit 474bf66
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions transformers/string/trim.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
// Copyright 2023-latest Tomoki Miyauchi. All rights reserved. MIT license.
// This module is browser compatible.

import type { Transformer } from "../../types.ts";

export class TrimTransformer implements Transformer<string, string> {
transform(input: string): string {
return input.trim();
}
}

0 comments on commit 474bf66

Please sign in to comment.