Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

remove all html tags from string javascript

myString.replace(/<[^>]*>?/gm, '');
Comment

remove-all-html-tags-from-string-javascript

// string with html tags
const str = "<div><h1>Hello World!</h1></div>";

// remove all html tags from string
str.replace(/(<([^>]+)>)/gi, ""); // Hello World
Comment

PREVIOUS NEXT
Code Example
Javascript :: add button in table using javascript 
Javascript :: javascript does key exist 
Javascript :: puppeteer wait for page load 
Javascript :: uuid v4 react 
Javascript :: empty select option jquery 
Javascript :: babel cdn react 
Javascript :: js get number of keys in object 
Javascript :: Your global Angular CLI version is greater than your local version 
Javascript :: javascript remove non numeric chars from string keep dot 
Javascript :: remove special characters regular expression 
Javascript :: Reset reCAPTCHA js 
Javascript :: javscript remove last character 
Javascript :: react native android build apk 
Javascript :: delete all children of div 
Javascript :: js get data attribute 
Javascript :: css how to make a div scrollable 
Javascript :: get random number in solidity 
Javascript :: wrap text react native 
Javascript :: node version not specified in package.json 
Javascript :: disable yellow box react native 
Javascript :: header ejs 
Javascript :: js startswith 
Javascript :: react native status bar color 
Javascript :: cep validator js 
Javascript :: js random string 
Javascript :: how to create round image in react native 
Javascript :: js detect screen size change 
Javascript :: print object in javascript 
Javascript :: javascript clear style inline property 
Javascript :: jquery insert element as first child 
ADD CONTENT
Topic
Content
Source link
Name
2+2 =