JSFiddle - React, Tailwind, and code Playground

JavaScript

document.write($('<div id="foo~edit">').is('#foo\\~edit'))