上一页 1 ··· 21 22 23 24 25 26 27 28 29 ··· 112 下一页
摘要: <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <script src="https://cdn.jsdelivr.net/npm/vue@2/dist/vue.js"></script> </head> <body> <div id="ap 阅读全文
posted @ 2021-07-05 15:08 thomas_blog 阅读(76) 评论(0) 推荐(0) 编辑
摘要: <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <script src="https://cdn.jsdelivr.net/npm/vue@2/dist/vue.js"></script> </head> <body> <div id="ap 阅读全文
posted @ 2021-07-05 14:58 thomas_blog 阅读(27) 评论(0) 推荐(0) 编辑
摘要: 一组数据,过滤出小于100的数,结果乘以2,并将结果汇总 <script> let buf = [10, 110, 20, 120, 30, 130]; let resBuf = buf.filter(n => n < 100).map(n => n * 2).reduce((value, n) = 阅读全文
posted @ 2021-07-05 14:36 thomas_blog 阅读(52) 评论(0) 推荐(0) 编辑
摘要: <script> let buf = [10, 110, 20, 120, 30, 130]; // value记录上次结果 let mapBuf = buf.reduce(function(value, n) { console.log(value, n); return 100 + n; }, 阅读全文
posted @ 2021-07-05 14:24 thomas_blog 阅读(28) 评论(0) 推荐(0) 编辑
摘要: <script> let buf = [10, 110, 20, 120, 30, 130]; let mapBuf = buf.map(function(n) { return n * 2; }) console.log(mapBuf); </script> 阅读全文
posted @ 2021-07-05 14:07 thomas_blog 阅读(63) 评论(0) 推荐(0) 编辑
摘要: <script> let buf = [10, 110, 20, 120, 30, 130]; let filterBuf = buf.filter(function(n) { // 返回bool return n > 100; }) console.log(filterBuf); </script 阅读全文
posted @ 2021-07-05 13:58 thomas_blog 阅读(57) 评论(0) 推荐(0) 编辑
摘要: <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <script src="https://cdn.jsdelivr.net/npm/vue@2/dist/vue.js"></script> </head> <body> <div id="ap 阅读全文
posted @ 2021-07-04 16:07 thomas_blog 阅读(129) 评论(0) 推荐(0) 编辑
摘要: <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <script src="https://cdn.jsdelivr.net/npm/vue@2/dist/vue.js"></script> <style type="text/css"> .a 阅读全文
posted @ 2021-07-03 11:42 thomas_blog 阅读(245) 评论(0) 推荐(0) 编辑
摘要: <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <script src="https://unpkg.com/vue/dist/vue.js"></script> </head> <body> <div id="app"> <p>{{ mes 阅读全文
posted @ 2021-07-01 20:24 thomas_blog 阅读(326) 评论(0) 推荐(0) 编辑
摘要: <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <script src="https://unpkg.com/vue/dist/vue.js"></script> </head> <body> <div id="app"> <p v-if=" 阅读全文
posted @ 2021-07-01 19:46 thomas_blog 阅读(43) 评论(0) 推荐(0) 编辑
上一页 1 ··· 21 22 23 24 25 26 27 28 29 ··· 112 下一页