Skip to content

Instantly share code, notes, and snippets.

View fengliu222's full-sized avatar
🎯
Focusing

JL fengliu222

🎯
Focusing
View GitHub Profile
<!doctype html>
<html>
<head>
<meta name="viewport" content="width=device-width">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>非常感谢您对Hotnode产品的关注与支持。</title>
<style>
/* -------------------------------------
GLOBAL RESETS
------------------------------------- */
@fengliu222
fengliu222 / project.js
Created May 15, 2018 08:39
项目收益
const mockProjectTrend = R.reverse()(R.repeat(1, 200).map((key, index) => ({
dateTime: moment().subtract(index, 'days').format('YYYY-MM-DD'), //时间
price: {
CNY: 1.239928076 * index,
USD: 0.195644770 * index,
BTC: 0.000023000 * index,
ETH: 0.000274619 * index,
EOS: 0.014086445 * index
}, // 投资回报率
vol: {
const mockTrend = R.repeat(1, 200).map((key, index) => ({
dateTime: moment().subtract(index, 'days').format('YYYY-MM-DD'), //时间
ROI: index * 10, // 投资回报率
profits: index * Math.random() * 1000, // 浮动盈亏
assets: index * Math.random() * 10000 // 总资产
}))
// 代码中会兼容本地 service mock 以及部署站点的静态数据
const proxy = {
'/mock/dashboard': (req, res) => {
res.send({
/**
* 走势图彩种结构
*/
const lottery = {
fields: [
{
key: 'number',
name: '期号',
},
@fengliu222
fengliu222 / javascript_resources.md
Last active August 29, 2015 14:07 — forked from jookyboi/javascript_resources.md
Here are a set of libraries, plugins and guides which may be useful to your Javascript coding.

Libraries

  • jQuery - The de-facto library for the modern age. It makes things like HTML document traversal and manipulation, event handling, animation, and Ajax much simpler with an easy-to-use API that works across a multitude of browsers.
  • Backbone - Backbone.js gives structure to web applications by providing models with key-value binding and custom events, collections with a rich API of enumerable functions, views with declarative event handling, and connects it all to your existing API over a RESTful JSON interface.
  • AngularJS - Conventions based MVC framework for HTML5 apps.
  • Underscore - Underscore is a utility-belt library for JavaScript that provides a lot of the functional programming support that you would expect in Prototype.js (or Ruby), but without extending any of the built-in JavaScript objects.
  • lawnchair - Key/value store adapter for indexdb, localStorage
@fengliu222
fengliu222 / 0_reuse_code.js
Last active August 29, 2015 14:07
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@fengliu222
fengliu222 / repeat.js
Created February 17, 2014 09:00
string.prototype.repeat
String.prototype.repeat = function(count){
return new Array( count+1 ).join(this);
}
@fengliu222
fengliu222 / index.html
Created November 15, 2012 16:04
A CodePen by fengliu222.
<div id="main">
<div id="slide">
<ul>
<li><img src="http://pic.yupoo.com/zhenghong/CpEvg2Fi/small.jpg'" alt=""></li>
<li><img src="http://pic.yupoo.com/zhenghong/CpEvg2Fi/small.jpg'" alt=""></li>
<li><img src="http://pic.yupoo.com/zhenghong/CpEvg2Fi/small.jpg'" alt=""></li>
<li><img src="http://pic.yupoo.com/zhenghong/CpEvg2Fi/small.jpg'" alt=""></li>
<li><img src="http://pic.yupoo.com/zhenghong/CpEvg2Fi/small.jpg'" alt=""></li>
<li><img src="http://pic.yupoo.com/zhenghong/CpEvg2Fi/small.jpg'" alt=""></li>
<li><img src="http://pic.yupoo.com/zhenghong/CpEvg2Fi/small.jpg'" alt=""></li>
<center>
<div class="scroll">
<ul>
<li><img src="http://imgsrc.baidu.com/forum/pic/item/ba19c833c895d14316c4f9ad73f0820258af07c8.jpg" alt=""></li>
<li><img src="http://imgsrc.baidu.com/forum/pic/item/ba19c833c895d14316c4f9ad73f0820258af07c8.jpg" alt=""></li>
<li><img src="http://imgsrc.baidu.com/forum/pic/item/ba19c833c895d14316c4f9ad73f0820258af07c8.jpg" alt="1"></li>
<li><img src="http://imgsrc.baidu.com/forum/pic/item/ba19c833c895d14316c4f9ad73f0820258af07c8.jpg" alt=""></li>
<li><img src="http://imgsrc.baidu.com/forum/pic/item/ba19c833c895d14316c4f9ad73f0820258af07c8.jpg" alt=""></li>
</ul>