mirror of
https://github.com/iconify/iconify.git
synced 2024-12-13 14:13:06 +00:00
15 lines
296 B
TypeScript
15 lines
296 B
TypeScript
|
let counter = 0;
|
||
|
|
||
|
/**
|
||
|
* Create node for test
|
||
|
*/
|
||
|
export function getNode(prefix = 'test') {
|
||
|
const id = prefix + '-' + Date.now() + '-' + counter++;
|
||
|
|
||
|
const node = document.createElement('div');
|
||
|
node.setAttribute('id', id);
|
||
|
|
||
|
document.getElementById('debug').appendChild(node);
|
||
|
return node;
|
||
|
}
|