/
TON618OFF
/
FinalPWHTML
Обзор
Документация
Войти
/
TON618OFF
/
FinalPWHTML
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
node_modules/@testing-library/dom/dist/get-node-text.js
13 строк
448 B
TON618OFF
не ну это ваще
23 июн 2024, 00:30
23 июн 2024, 00:30
e27ae20
Код
Авторство
О чём код?
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.getNodeText = getNodeText; var _helpers = require("./helpers"); function getNodeText(node) { if (node.matches('input[type=submit], input[type=button], input[type=reset]')) { return node.value; } return Array.from(node.childNodes).filter(child => child.nodeType === _helpers.TEXT_NODE && Boolean(child.textContent)).map(c => c.textContent).join(''); }