Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

Find a character between space with Regex in js

const text = 'Whatever - this is'
let re = new RegExp(' – ', 'gm') //or 's–s'
//This return an array of  string(s) if the match is found
console.log(text.match(re))
 
PREVIOUS NEXT
Tagged: #Find #character #space #Regex #js
ADD COMMENT
Topic
Name
2+6 =