If statments in Js

I need a litle bit of help. So I have a rename functionality, I have many if statements, the one I cant bear to begin is, I want to create an if statement when name is
is not changed, I will add an alert. Like you see from the example below for Name blank. I hope you understood me. Edit: this is if statement is for the other funcionality of rename File

   if(!fileName.replace(/s+/, "") .length > 0){
            Alert.alert('Error', "Name can't be blank");

Source: JavaSript – Stack Overflow

November 22, 2021
Category : News
Tags: if-statement | javascript | react native | reactjs

Leave a Reply

Your email address will not be published. Required fields are marked *

Sitemap | Terms | Privacy | Cookies | Advertising

Senior Software Developer

Creator of @LzoMedia I am a backend software developer based in London who likes beautiful code and has an adherence to standards & love's open-source.