Skip to content

Instantly share code, notes, and snippets.

View markkkkas's full-sized avatar
🤓

Markas Klapovščiuk markkkkas

🤓
  • Vilnius, Lithuania
  • 19:01 (UTC +03:00)
  • LinkedIn in/markkkkas
View GitHub Profile
export const chaosTestStrings = (): void => {
const textNodes = getAllTextNodes(document.body);
for (const node of textNodes) {
const textNodeLength = node.textContent ? node.textContent.length : 0;
if (node.textContent === null) {
return;
}
if (node.parentElement instanceof Element) {
if (node.parentElement.dataset.originalText === undefined) {