-
-
Save aria42/f2ad8ff911364c6d3dc0 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
dommy.template_perf_test.user_post = function user_post(post) { | |
var dom15329 = document.createElement("li"); | |
dom15329.className = "post"; | |
dom15329.appendChild(function() { | |
var dom15330 = document.createElement("a"); | |
if(cljs.core.truth_([cljs.core.str("/post/"), cljs.core.str(post["id"])].join(""))) { | |
dom15330.setAttribute("href", [cljs.core.str("/post/"), cljs.core.str(post["id"])].join("")) | |
}else { | |
} | |
dom15330.appendChild(document.createTextNode(post["title"])); | |
return dom15330 | |
}()); | |
dom15329.appendChild(document.createTextNode(post["contents"])); | |
return dom15329 | |
}; | |
dommy.template_perf_test.user_profile = function user_profile(user) { | |
var dom15338 = document.createElement("div"); | |
dom15338.className = "user"; | |
dom15338.appendChild(function() { | |
var dom15339 = document.createElement("div"); | |
dom15339.className = "name"; | |
dom15339.appendChild(document.createTextNode(user["name"])); | |
return dom15339 | |
}()); | |
dom15338.appendChild(function() { | |
var dom15340 = document.createElement("img"); | |
dom15340.className = "avatar"; | |
if(cljs.core.truth_(user["imgURL"])) { | |
dom15340.setAttribute("src", user["imgURL"]) | |
}else { | |
} | |
return dom15340 | |
}()); | |
dom15338.appendChild(function() { | |
var dom15341 = document.createElement("p"); | |
dom15341.className = "posts"; | |
dom15341.appendChild(document.createTextNode("Posts:")); | |
dom15341.appendChild(function() { | |
var dom15342 = document.createElement("ul"); | |
dom15342.appendChild(dommy.template.__GT_node_like.call(null, function() { | |
var iter__2919__auto__ = function iter__15343(s__15344) { | |
return new cljs.core.LazySeq(null, false, function() { | |
var s__15344__$1 = s__15344; | |
while(true) { | |
var temp__4092__auto__ = cljs.core.seq.call(null, s__15344__$1); | |
if(temp__4092__auto__) { | |
var xs__4579__auto__ = temp__4092__auto__; | |
var post = cljs.core.first.call(null, xs__4579__auto__); | |
return cljs.core.cons.call(null, dommy.template_perf_test.user_post.call(null, post), iter__15343.call(null, cljs.core.rest.call(null, s__15344__$1))) | |
}else { | |
return null | |
} | |
break | |
} | |
}, null) | |
}; | |
return iter__2919__auto__.call(null, user["posts"]) | |
}())); | |
return dom15342 | |
}()); | |
return dom15341 | |
}()); | |
return dom15338 | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment