spring boot 项目拆分 2019年5月20日 | Leave a comment 问题: 有几个 spring boot 项目, 有些不同的版本 有些公用的代码想抽取成一个 jar 应该怎么操… Read More
JDK11.0.3 module java.base does not “opens jdk.internal.reflect” to unnamed module @4f757cf6 2019年4月28日 | Leave a comment 问题: JDK11.0.3 报错,11.0.2 还正常 Caused by: java.lang.reflec… Read More
[转]让SpringBoot启动更快一点 2019年4月20日 | Leave a comment http://www.importnew.com/30647.html 本文由 ImportNe… Read More
[转] SpringBoot实战之SpringBoot自动配置原理 2019年4月20日 | Leave a comment https://www.cnblogs.com/leihuazhe/p/7743479.html … Read More
[转] 微信小程序开发用 JS ES8 async/await 解决异步调用 2019年4月20日 | Leave a comment 微信小程序开发用 JS ES8 async/await 解决异步调用 在小程序开发… Read More
ES2015 Promise demo 2019年4月20日 | Leave a comment 解决: <!DOCTYPE html> <html> <head> <script> let i = true; function get() { const p = new Promise((resolve, reject) => { if (i) { resolve("ok"); } else { reject("error"); } i = !i; }); return p; } function onRefresh() { const p = get(); let resultDiv = document.getElementById("result"); let errorDiv = document.getElementById("error"); p.then(v => { resultDiv.innerText = v; errorDiv.innerText = null; }).catch(err => { resultDiv.innerText = null; errorDiv.innerText = err; }); } </script> </head> <body> <div id="result"></div> <div id="error"></div> <button onclick="onRefresh()">刷新</button> </body> </html> 123456789101112131415161718192021222324252627282930313233343536 <!DOCTYPE html><html> <head> <script> let i = true; function get() { const p = new Promise((resolve, reject) => { if (i) { resolve("ok"); } else { reject("error"); } i = !i; }); return p; } function onRefresh() { const p = get(); let resultDiv = document.getElementById("result"); let errorDiv = document.getElementById("error"); p.then(v => { resultDiv.innerText = v; errorDiv.innerText = null; }).catch(err => { resultDiv.innerText = null; errorDiv.innerText = err; }); } </script> </head> <body> <div id="result"></div> <div id="error"></div> <button onclick="onRefresh()">刷新</button> </body></html> &nbs… Read More
ES2015 生成器 demo 2019年4月20日 | Leave a comment 解决: 需要运行在 chrome 及其他支持ES2015的浏览器 [crayon-674631cea2eae7… Read More
html5 canvas demo 2019年4月19日 | Leave a comment 解决: <!doctype <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <title>tt</title> <meta name="viewport" content="width=device-width, initial-scale=1"> <script> function draw(){ var c = document.getElementById('c'); var ctx = c.getContext('2d'); ctx.fillStyle="rgb(200,0,0)" ctx.fillRect(100,100,150,150); ctx.fillStyle="rgba(0,0,200,0.5)"; ctx.fillRect(150,150,200,200); } function getCtx(){ var c = document.getElementById('c'); var ctx = c.getContext('2d'); return ctx; } function drawPath(){ var ctx = getCtx(); ctx.beginPath(); ctx.moveTo(50,50); ctx.lineTo(50,100); ctx.lineTo(100,100); ctx.stroke(); } function drawFace(){ var c = getCtx(); c.beginPath(); c.arc(75,75,50,0,Math.PI*2,true); c.moveTo(110,75); c.arc(75,75,35,0,Math.PI); c.stroke(); } function drawSVGPath(){ var c= getCtx(); c.strokeStyle="#ff0000"; var p = new Path2D("M10 10 h 80 v 80 h -80 Z"); c.stroke(p); } function drawText(){ var c = getCtx(); c.font = "50px serif"; c.fillStyle = "#00FF00"; c.strokeText("你好",100,100); } </script> </head> <body onload="drawText()"> <canvas id="c" width="500" height="500" /> </body> </html> 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758 <!doctype <!DOCTYPE html><html> <head> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <title>tt</title> <meta name="viewport" content="width=device-width, initial-scale=1"> <script> function draw(){ var c = document.getElementById('c'); var ctx = c.getContext('2d'); ctx.fillStyle="rgb(200,0,0)" ctx.fillRect(100,100,150,150); ctx.fillStyle="rgba(0,0,200,0.5)"; ctx.fillRect(150,150,200,200); } function getCtx(){ var c = document.getElementById('c'); var ctx = c.getContext('2d'); return ctx; } function drawPath(){ var ctx = getCtx(); ctx.beginPath(); ctx.moveTo(50,50); ctx.lineTo(50,100); ctx.lineTo(100,100); ctx.stroke(); } function drawFace(){ var c = getCtx(); c.beginPath(); c.arc(75,75,50,0,Math.PI*2,true); c.moveTo(110,75); c.arc(75,75,35,0,Math.PI); c.stroke(); } function drawSVGPath(){ var c= getCtx(); c.strokeStyle="#ff0000"; var p = new Path2D("M10 10 h 80 v 80 h -80 Z"); c.stroke(p); } function drawText(){ var c = getCtx(); c.font = "50px serif"; c.fillStyle = "#00FF00"; c.strokeText("你好",100,100); } </script></head> <body onload="drawText()"> <canvas id="c" width="500" height="500" /></body> </html> &nbs… Read More