Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

javascript string contains multiple substrings

if (/term1|term2|term3/.test("your string")) {
   //your code
}
Comment

PREVIOUS NEXT
Code Example
Javascript :: socket io client 
Javascript :: discord.js rich embed 
Javascript :: how create an index mongodb 
Javascript :: Deleting all white spaces in a string 
Javascript :: react native submit on enter key 
Javascript :: could not resolve module fs react native 
Javascript :: ytdl-core 
Javascript :: find the max length of string elements in an array 
Javascript :: js desktop notification 
Javascript :: javascript replace all occurrences of string 
Javascript :: How to create react app with yarn, npx or npm 
Javascript :: javascript pdf preview 
Javascript :: postman test check response status 
Javascript :: Shuffle a Sting in JavaScript 
Javascript :: nodejs express hot reload 
Javascript :: proactive vs reactive 
Javascript :: javascript check if number is multiple of 3 
Javascript :: if jsp 
Javascript :: json.stringify parameters 
Javascript :: replace spaces with backslash js 
Javascript :: save text to file nodejs 
Javascript :: javascript class 
Javascript :: jquery textarea autosize 
Javascript :: settimeout in a for loop javascript 
Javascript :: Check ratelimit discord js 
Javascript :: commonjs vs es6 
Javascript :: how to upload file in material ui 
Javascript :: node cron every 10 minutes 
Javascript :: insert data from lambda to dynamodb 
Javascript :: datatable get all selected row data 
ADD CONTENT
Topic
Content
Source link
Name
7+5 =