mirror of
https://github.com/iconify/iconify.git
synced 2024-11-10 15:20:54 +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;
|
||
|
}
|