JSFiddle - React, Tailwind, and code Playground

by meo

HTML

<h1>OSX,UNIC / Windows Path Converter<h1>
<input id="path" type="text" placeholder="paste the path here" />
    <button>convert</button>

CSS

h1 {
    font-size: 2em;
}
input {
    width: 100%;
}

JavaScript

$("button").click(function(){
    var val, regexWin, regexUnix, $input = $("input#path");
    
    regexWin = /\\*/;
    regexUnix = /\/*/;
    val = $input.val();
    
    console.log(regexUnix.test(val))

});