diff options
author | Vijay A <vraravam@users.noreply.github.com> | 2024-01-26 08:24:20 +0530 |
---|---|---|
committer | Vijay Aravamudhan <vraravam@users.noreply.github.com> | 2024-01-28 03:31:35 +0000 |
commit | 6c67387b2978f1a02244a1350725238da35b341b (patch) | |
tree | c357ab6826cce8272642c01b0d80120bd5baaa86 /src/jsUtils.ts | |
parent | 6.7.1-nightly.11 [skip ci] (diff) | |
download | ferdium-app-6c67387b2978f1a02244a1350725238da35b341b.tar.gz ferdium-app-6c67387b2978f1a02244a1350725238da35b341b.tar.zst ferdium-app-6c67387b2978f1a02244a1350725238da35b341b.zip |
chore: minor refactoring to reduce lines and add tests
Diffstat (limited to 'src/jsUtils.ts')
-rw-r--r-- | src/jsUtils.ts | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/jsUtils.ts b/src/jsUtils.ts index 0095028ef..31d6a2121 100644 --- a/src/jsUtils.ts +++ b/src/jsUtils.ts | |||
@@ -30,3 +30,6 @@ export const acceleratorString = ( | |||
30 | prefix: string = '(', | 30 | prefix: string = '(', |
31 | suffix: string = ')', | 31 | suffix: string = ')', |
32 | ) => (index <= 10 ? `${prefix}${keyCombo}+${index % 10}${suffix}` : ''); | 32 | ) => (index <= 10 ? `${prefix}${keyCombo}+${index % 10}${suffix}` : ''); |
33 | |||
34 | export const removeNewLines = (input: string): string => | ||
35 | input.replaceAll(/\r?\n|\r/g, ''); | ||