JSFiddle - React, Tailwind, and code Playground

by Dmitri Ganenco

JavaScript

const str = '1 - test \n2 - test2 \n3 - test3 \n4 - test4';
str.replace(' - ', )
console.log(str);