From 9fe7c29f96cccfe09794b9d53e293c402139ba10 Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 2 Nov 2023 21:03:18 +0530 Subject: [PATCH] added upper and lower --- src/components/utils/stringCaseConverter.js | 8 +++++ src/pages/StringCaseConverter/index.vue | 40 +++++++++++++++++++-- 2 files changed, 45 insertions(+), 3 deletions(-) diff --git a/src/components/utils/stringCaseConverter.js b/src/components/utils/stringCaseConverter.js index 81f2edc..1fa10f6 100644 --- a/src/components/utils/stringCaseConverter.js +++ b/src/components/utils/stringCaseConverter.js @@ -31,6 +31,14 @@ export const toTrainCase = (userInput) => { return String(userInput).replace(/(? word.charAt(0).toUpperCase() + word.slice(1).toLowerCase()).join('-'); } +export const toUpperCase = (userInput) => { + return String(userInput).toUpperCase(); +} + +export const toLowerCase = (userInput) => { + return String(userInput).toLowerCase(); +} + export const ifNull = (userInput) => { if (userInput == null) { return true; diff --git a/src/pages/StringCaseConverter/index.vue b/src/pages/StringCaseConverter/index.vue index 9868dd8..45e4b84 100644 --- a/src/pages/StringCaseConverter/index.vue +++ b/src/pages/StringCaseConverter/index.vue @@ -1,14 +1,14 @@