Last active
December 31, 2015 15:39
-
-
Save huanglong-zz/8008519 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
// 1.Take me nearly 1.5 hours to figure it out | |
function buildTotalPrice(ths, arrs) { | |
var _arrs = [] | |
var l = ths.length - 1 | |
for (var i = 0; i < l; i++) { | |
var _arr = 0 | |
for (var n = 0, m = arrs.lenth; n < m; n++) { | |
var vs = arrs[n].costs | |
_arr += parseFloat(vs[i]) | |
} | |
_arrs.push(_arr) | |
} | |
return _arrs | |
} | |
// 2. Take me nearly 30 minutes to figure it out: | |
var temp = heredoc(function() {/* | |
{{#each data}} | |
<li class="dib-wrap class_id"> | |
<a class="dib picbox mr10" href="{{eurl}}" target="_blank"> | |
<img src="{{imgUrl}}" /> | |
</a> | |
<div class="dib detail mr10"> | |
<p class="aucTitle"> | |
<a class="dib" href="{{eurl}}" target="_blank">{{title}}</a> | |
</p> | |
<div class="dib-wrap"> | |
<div class="dib info"> | |
{{#each propertyMap}} | |
<p><span>{{key}}:</span>{{value}}</p> | |
{{/each}} | |
<p> | |
<span id="J_WW" bx-name="mosaics/wangwang" class="J_WangWang" data-nick="{{wangwangID}}" data-icon="large"></span> | |
</p> | |
</div> | |
<div class="dib aboutshop"> | |
<p>月销:{{sellCount}}笔</p> | |
<p>评价:{{comments}}</p> | |
</div> | |
</div> | |
</div> | |
<div class="dib handle"> | |
<span class="price">¥<strong>{{price}}</strong></span> | |
<a href="{{eurl}" class="btn btn-blue">查看详情</a> | |
</div> | |
</li> | |
{{/each}} | |
*/}) | |
// 3. Take me 30 minutes to google it when using google map | |
“Uncaught RangeError: Maximum call stack size exceeded | |
Wrong position for lat and lng or lng is invalid! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment