snippets
copy text with selector
This is the target text to copy
- The
b.copy(selector)method copies text from the element with the given selector. - The
.valueis copied if it exists. Otherwise, the.innerHTMLis copied. - If you want feedback (e.g. changing "Copy Text" to "Copied" for a short interval), you can roll your own or use the b.quickCopy method.
html
This is the target text to copy
Copy Textjavascript
;