mirror of
https://github.com/github/semantic.git
synced 2024-11-25 11:04:00 +03:00
Add a function to wrap a node in another node.
This commit is contained in:
parent
0dcecb9a00
commit
208238ae6e
@ -28,6 +28,12 @@
|
||||
request.send(null);
|
||||
}
|
||||
|
||||
function wrap(tagName, element) {
|
||||
var node = document.createElement(tagName);
|
||||
node.appendChild(element);
|
||||
return node;
|
||||
}
|
||||
|
||||
function toDOM(json) {
|
||||
var node = document.createElement("div");
|
||||
if (json instanceof Array) {
|
||||
|
Loading…
Reference in New Issue
Block a user