diff --git a/404.html b/404.html index 103f6f9..63ca276 100644 --- a/404.html +++ b/404.html @@ -14,7 +14,7 @@
Skip to content

404

PAGE NOT FOUND

But if you don't change your direction, and if you keep looking, you may end up where you are heading.
- + diff --git "a/Taro\345\274\200\345\217\221\344\270\255\347\232\204\345\235\221.html" "b/Taro\345\274\200\345\217\221\344\270\255\347\232\204\345\235\221.html" index a7b6fe6..bc4f32c 100644 --- "a/Taro\345\274\200\345\217\221\344\270\255\347\232\204\345\235\221.html" +++ "b/Taro\345\274\200\345\217\221\344\270\255\347\232\204\345\235\221.html" @@ -214,7 +214,7 @@ ], ],

这个组件名前缀你喜欢改什么就改什么,记得在vue的template的引用同步更改就行

重新运行pnpm dev:alipay,大功告成~🎉 4.x版本在安卓上已经没有上面提到的两个问题了

总结

这里踩坑主要还是配置问题,因为我不熟悉webpackwebpackchain因此废了很大劲。还有找资料还是优先到github查找一下有没有类似的issue或者贡献,什么chatGPT没啥用,不停的说谎给出错误答案

- + diff --git "a/Vue.js\350\256\276\350\256\241\344\270\216\345\256\236\347\216\260-\351\230\205\350\257\273\347\254\224\350\256\260.html" "b/Vue.js\350\256\276\350\256\241\344\270\216\345\256\236\347\216\260-\351\230\205\350\257\273\347\254\224\350\256\260.html" index f6fd21e..ed26fc8 100644 --- "a/Vue.js\350\256\276\350\256\241\344\270\216\345\256\236\347\216\260-\351\230\205\350\257\273\347\254\224\350\256\260.html" +++ "b/Vue.js\350\256\276\350\256\241\344\270\216\345\256\236\347\216\260-\351\230\205\350\257\273\347\254\224\350\256\260.html" @@ -134,7 +134,7 @@ activeEffect.deps.push(deps) } - + diff --git a/antv.html b/antv.html index 61ce9ac..873b92d 100644 --- a/antv.html +++ b/antv.html @@ -562,7 +562,7 @@ ...new Set(Array.from({ length: 100 }).map(() => ~~(Math.random() * 5))), ].map((item) => "d" + item); - + diff --git "a/assets/\345\267\245\344\275\234\345\270\270\347\224\250\344\273\243\347\240\201.md.d8b407c5.js" "b/assets/\345\267\245\344\275\234\345\270\270\347\224\250\344\273\243\347\240\201.md.e3c96505.js" similarity index 97% rename from "assets/\345\267\245\344\275\234\345\270\270\347\224\250\344\273\243\347\240\201.md.d8b407c5.js" rename to "assets/\345\267\245\344\275\234\345\270\270\347\224\250\344\273\243\347\240\201.md.e3c96505.js" index bc004d2..07818b7 100644 --- "a/assets/\345\267\245\344\275\234\345\270\270\347\224\250\344\273\243\347\240\201.md.d8b407c5.js" +++ "b/assets/\345\267\245\344\275\234\345\270\270\347\224\250\344\273\243\347\240\201.md.e3c96505.js" @@ -1,4 +1,4 @@ -import{_ as o,c as e,b as n,w as t,a as s,r as a,o as c,e as r}from"./app.08e03c58.js";const m=JSON.parse('{"title":"","description":"","frontmatter":{},"headers":[{"level":2,"title":"SN","slug":"sn","link":"#sn","children":[{"level":3,"title":"chrom \u6DFB\u52A0\u6A21\u62DF app \u7684\u8BBE\u5907","slug":"chrom-\u6DFB\u52A0\u6A21\u62DF-app-\u7684\u8BBE\u5907","link":"#chrom-\u6DFB\u52A0\u6A21\u62DF-app-\u7684\u8BBE\u5907","children":[]},{"level":3,"title":"\u79FB\u52A8\u7AEF\u6A2A\u5C4F","slug":"\u79FB\u52A8\u7AEF\u6A2A\u5C4F","link":"#\u79FB\u52A8\u7AEF\u6A2A\u5C4F","children":[]},{"level":3,"title":"\u4E0A\u62C9\u52A0\u8F7D\u5206\u9875","slug":"\u4E0A\u62C9\u52A0\u8F7D\u5206\u9875","link":"#\u4E0A\u62C9\u52A0\u8F7D\u5206\u9875","children":[]},{"level":3,"title":"\u8BB0\u4F4F\u5BC6\u7801","slug":"\u8BB0\u4F4F\u5BC6\u7801","link":"#\u8BB0\u4F4F\u5BC6\u7801","children":[]},{"level":3,"title":"\u5BC6\u7801\u662F\u5426\u53EF\u89C1","slug":"\u5BC6\u7801\u662F\u5426\u53EF\u89C1","link":"#\u5BC6\u7801\u662F\u5426\u53EF\u89C1","children":[]},{"level":3,"title":"\u9A8C\u8BC1\u7801","slug":"\u9A8C\u8BC1\u7801","link":"#\u9A8C\u8BC1\u7801","children":[]},{"level":3,"title":"\u6587\u4EF6\u4E0A\u4F20","slug":"\u6587\u4EF6\u4E0A\u4F20","link":"#\u6587\u4EF6\u4E0A\u4F20","children":[]},{"level":3,"title":"\u6A21\u677F\u8BED\u6CD5","slug":"\u6A21\u677F\u8BED\u6CD5","link":"#\u6A21\u677F\u8BED\u6CD5","children":[]},{"level":3,"title":"workman","slug":"workman","link":"#workman","children":[]},{"level":3,"title":"\u590D\u5236\u6587\u672C","slug":"\u590D\u5236\u6587\u672C","link":"#\u590D\u5236\u6587\u672C","children":[]},{"level":3,"title":"\u5168\u9009\u4E0E\u5168\u4E0D\u9009","slug":"\u5168\u9009\u4E0E\u5168\u4E0D\u9009","link":"#\u5168\u9009\u4E0E\u5168\u4E0D\u9009","children":[]},{"level":3,"title":"moment.js","slug":"moment-js","link":"#moment-js","children":[]},{"level":3,"title":"\u9AD8\u4EFF ios \u6570\u91CF\u9009\u62E9\u5668","slug":"\u9AD8\u4EFF-ios-\u6570\u91CF\u9009\u62E9\u5668","link":"#\u9AD8\u4EFF-ios-\u6570\u91CF\u9009\u62E9\u5668","children":[]},{"level":3,"title":"\u6ED1\u52A8\u5207\u6362","slug":"\u6ED1\u52A8\u5207\u6362","link":"#\u6ED1\u52A8\u5207\u6362","children":[]},{"level":3,"title":"\u8FDB\u5EA6\u6761","slug":"\u8FDB\u5EA6\u6761","link":"#\u8FDB\u5EA6\u6761","children":[]},{"level":3,"title":"\u7981\u6B62\u7528\u6237\u6253\u5F00\u63A7\u5236\u53F0","slug":"\u7981\u6B62\u7528\u6237\u6253\u5F00\u63A7\u5236\u53F0","link":"#\u7981\u6B62\u7528\u6237\u6253\u5F00\u63A7\u5236\u53F0","children":[]},{"level":3,"title":"\u6587\u5B57\u6EDA\u52A8","slug":"\u6587\u5B57\u6EDA\u52A8","link":"#\u6587\u5B57\u6EDA\u52A8","children":[]},{"level":3,"title":"\u5012\u8BA1\u65F6","slug":"\u5012\u8BA1\u65F6","link":"#\u5012\u8BA1\u65F6","children":[]},{"level":3,"title":"\u4FEE\u6539placeholder\u6837\u5F0F","slug":"\u4FEE\u6539placeholder\u6837\u5F0F","link":"#\u4FEE\u6539placeholder\u6837\u5F0F","children":[]},{"level":3,"title":"emmet \u8BED\u6CD5\u751F\u6210\u65E0\u610F\u4E49\u6587\u5B57","slug":"emmet-\u8BED\u6CD5\u751F\u6210\u65E0\u610F\u4E49\u6587\u5B57","link":"#emmet-\u8BED\u6CD5\u751F\u6210\u65E0\u610F\u4E49\u6587\u5B57","children":[]},{"level":3,"title":"\u6587\u672C\u6EA2\u51FA\uFF0C\u4EE5...\u8868\u793A","slug":"\u6587\u672C\u6EA2\u51FA-\u4EE5-\u8868\u793A","link":"#\u6587\u672C\u6EA2\u51FA-\u4EE5-\u8868\u793A","children":[]},{"level":3,"title":"\u5224\u65AD\u5BF9\u8C61\u6709\u65E0\u6307\u5B9A\u5C5E\u6027","slug":"\u5224\u65AD\u5BF9\u8C61\u6709\u65E0\u6307\u5B9A\u5C5E\u6027","link":"#\u5224\u65AD\u5BF9\u8C61\u6709\u65E0\u6307\u5B9A\u5C5E\u6027","children":[]},{"level":3,"title":"\u5224\u65AD\u624B\u673A\uFF08\u5B89\u5353\uFF0C\u82F9\u679C\uFF09","slug":"\u5224\u65AD\u624B\u673A-\u5B89\u5353-\u82F9\u679C","link":"#\u5224\u65AD\u624B\u673A-\u5B89\u5353-\u82F9\u679C","children":[]}]},{"level":2,"title":"LC","slug":"lc","link":"#lc","children":[{"level":3,"title":"\u6743\u9650","slug":"\u6743\u9650","link":"#\u6743\u9650","children":[]},{"level":3,"title":"element","slug":"element","link":"#element","children":[]}]},{"level":2,"title":"HONGDU","slug":"hongdu","link":"#hongdu","children":[{"level":3,"title":"\u7981\u6B62\u5F00\u53D1\u8005\u5DE5\u5177\u8C03\u8BD5","slug":"\u7981\u6B62\u5F00\u53D1\u8005\u5DE5\u5177\u8C03\u8BD5","link":"#\u7981\u6B62\u5F00\u53D1\u8005\u5DE5\u5177\u8C03\u8BD5","children":[]},{"level":3,"title":"\u83B7\u53D6\u5F53\u524D\u65E5\u671F\u7684\u4E00\u5468\u65F6\u95F4","slug":"\u83B7\u53D6\u5F53\u524D\u65E5\u671F\u7684\u4E00\u5468\u65F6\u95F4","link":"#\u83B7\u53D6\u5F53\u524D\u65E5\u671F\u7684\u4E00\u5468\u65F6\u95F4","children":[]},{"level":3,"title":"\u901A\u8FC7 Blob \u4E0B\u8F7D\u6587\u4EF6","slug":"\u901A\u8FC7-blob-\u4E0B\u8F7D\u6587\u4EF6","link":"#\u901A\u8FC7-blob-\u4E0B\u8F7D\u6587\u4EF6","children":[]}]}],"relativePath":"\u5DE5\u4F5C\u5E38\u7528\u4EE3\u7801.md"}'),F={name:"\u5DE5\u4F5C\u5E38\u7528\u4EE3\u7801.md"},y=s(`

SN

chrom \u6DFB\u52A0\u6A21\u62DF app \u7684\u8BBE\u5907

\u5728 User agent string \u4E00\u680F\u4E2D\u586B\u5199

Mozilla/5.0 (iPod touch; CPU iPhone OS 9_2 like Mac OS X) AppleWebKit/601.1.46 (KHTML, like Gecko) Mobile/13C75 2.0.24 CK 2.0
+import{_ as o,c as e,b as n,w as t,a as s,r as a,o as c,e as r}from"./app.08e03c58.js";const m=JSON.parse('{"title":"","description":"","frontmatter":{},"headers":[{"level":2,"title":"SN","slug":"sn","link":"#sn","children":[{"level":3,"title":"chrom \u6DFB\u52A0\u6A21\u62DF app \u7684\u8BBE\u5907","slug":"chrom-\u6DFB\u52A0\u6A21\u62DF-app-\u7684\u8BBE\u5907","link":"#chrom-\u6DFB\u52A0\u6A21\u62DF-app-\u7684\u8BBE\u5907","children":[]},{"level":3,"title":"\u79FB\u52A8\u7AEF\u6A2A\u5C4F","slug":"\u79FB\u52A8\u7AEF\u6A2A\u5C4F","link":"#\u79FB\u52A8\u7AEF\u6A2A\u5C4F","children":[]},{"level":3,"title":"\u4E0A\u62C9\u52A0\u8F7D\u5206\u9875","slug":"\u4E0A\u62C9\u52A0\u8F7D\u5206\u9875","link":"#\u4E0A\u62C9\u52A0\u8F7D\u5206\u9875","children":[]},{"level":3,"title":"\u8BB0\u4F4F\u5BC6\u7801","slug":"\u8BB0\u4F4F\u5BC6\u7801","link":"#\u8BB0\u4F4F\u5BC6\u7801","children":[]},{"level":3,"title":"\u5BC6\u7801\u662F\u5426\u53EF\u89C1","slug":"\u5BC6\u7801\u662F\u5426\u53EF\u89C1","link":"#\u5BC6\u7801\u662F\u5426\u53EF\u89C1","children":[]},{"level":3,"title":"\u9A8C\u8BC1\u7801","slug":"\u9A8C\u8BC1\u7801","link":"#\u9A8C\u8BC1\u7801","children":[]},{"level":3,"title":"\u6587\u4EF6\u4E0A\u4F20","slug":"\u6587\u4EF6\u4E0A\u4F20","link":"#\u6587\u4EF6\u4E0A\u4F20","children":[]},{"level":3,"title":"\u6A21\u677F\u8BED\u6CD5","slug":"\u6A21\u677F\u8BED\u6CD5","link":"#\u6A21\u677F\u8BED\u6CD5","children":[]},{"level":3,"title":"workman","slug":"workman","link":"#workman","children":[]},{"level":3,"title":"\u590D\u5236\u6587\u672C","slug":"\u590D\u5236\u6587\u672C","link":"#\u590D\u5236\u6587\u672C","children":[]},{"level":3,"title":"\u5168\u9009\u4E0E\u5168\u4E0D\u9009","slug":"\u5168\u9009\u4E0E\u5168\u4E0D\u9009","link":"#\u5168\u9009\u4E0E\u5168\u4E0D\u9009","children":[]},{"level":3,"title":"moment.js","slug":"moment-js","link":"#moment-js","children":[]},{"level":3,"title":"\u9AD8\u4EFF ios \u6570\u91CF\u9009\u62E9\u5668","slug":"\u9AD8\u4EFF-ios-\u6570\u91CF\u9009\u62E9\u5668","link":"#\u9AD8\u4EFF-ios-\u6570\u91CF\u9009\u62E9\u5668","children":[]},{"level":3,"title":"\u6ED1\u52A8\u5207\u6362","slug":"\u6ED1\u52A8\u5207\u6362","link":"#\u6ED1\u52A8\u5207\u6362","children":[]},{"level":3,"title":"\u8FDB\u5EA6\u6761","slug":"\u8FDB\u5EA6\u6761","link":"#\u8FDB\u5EA6\u6761","children":[]},{"level":3,"title":"\u7981\u6B62\u7528\u6237\u6253\u5F00\u63A7\u5236\u53F0","slug":"\u7981\u6B62\u7528\u6237\u6253\u5F00\u63A7\u5236\u53F0","link":"#\u7981\u6B62\u7528\u6237\u6253\u5F00\u63A7\u5236\u53F0","children":[]},{"level":3,"title":"\u6587\u5B57\u6EDA\u52A8","slug":"\u6587\u5B57\u6EDA\u52A8","link":"#\u6587\u5B57\u6EDA\u52A8","children":[]},{"level":3,"title":"\u5012\u8BA1\u65F6","slug":"\u5012\u8BA1\u65F6","link":"#\u5012\u8BA1\u65F6","children":[]},{"level":3,"title":"\u4FEE\u6539placeholder\u6837\u5F0F","slug":"\u4FEE\u6539placeholder\u6837\u5F0F","link":"#\u4FEE\u6539placeholder\u6837\u5F0F","children":[]},{"level":3,"title":"emmet \u8BED\u6CD5\u751F\u6210\u65E0\u610F\u4E49\u6587\u5B57","slug":"emmet-\u8BED\u6CD5\u751F\u6210\u65E0\u610F\u4E49\u6587\u5B57","link":"#emmet-\u8BED\u6CD5\u751F\u6210\u65E0\u610F\u4E49\u6587\u5B57","children":[]},{"level":3,"title":"\u6587\u672C\u6EA2\u51FA\uFF0C\u4EE5...\u8868\u793A","slug":"\u6587\u672C\u6EA2\u51FA-\u4EE5-\u8868\u793A","link":"#\u6587\u672C\u6EA2\u51FA-\u4EE5-\u8868\u793A","children":[]},{"level":3,"title":"\u5224\u65AD\u5BF9\u8C61\u6709\u65E0\u6307\u5B9A\u5C5E\u6027","slug":"\u5224\u65AD\u5BF9\u8C61\u6709\u65E0\u6307\u5B9A\u5C5E\u6027","link":"#\u5224\u65AD\u5BF9\u8C61\u6709\u65E0\u6307\u5B9A\u5C5E\u6027","children":[]},{"level":3,"title":"\u5224\u65AD\u624B\u673A\uFF08\u5B89\u5353\uFF0C\u82F9\u679C\uFF09","slug":"\u5224\u65AD\u624B\u673A-\u5B89\u5353-\u82F9\u679C","link":"#\u5224\u65AD\u624B\u673A-\u5B89\u5353-\u82F9\u679C","children":[]}]},{"level":2,"title":"LC","slug":"lc","link":"#lc","children":[{"level":3,"title":"\u6743\u9650","slug":"\u6743\u9650","link":"#\u6743\u9650","children":[]},{"level":3,"title":"element","slug":"element","link":"#element","children":[]}]},{"level":2,"title":"HONGDU","slug":"hongdu","link":"#hongdu","children":[{"level":3,"title":"\u7981\u6B62\u5F00\u53D1\u8005\u5DE5\u5177\u8C03\u8BD5","slug":"\u7981\u6B62\u5F00\u53D1\u8005\u5DE5\u5177\u8C03\u8BD5","link":"#\u7981\u6B62\u5F00\u53D1\u8005\u5DE5\u5177\u8C03\u8BD5","children":[]},{"level":3,"title":"\u83B7\u53D6\u5F53\u524D\u65E5\u671F\u7684\u4E00\u5468\u65F6\u95F4","slug":"\u83B7\u53D6\u5F53\u524D\u65E5\u671F\u7684\u4E00\u5468\u65F6\u95F4","link":"#\u83B7\u53D6\u5F53\u524D\u65E5\u671F\u7684\u4E00\u5468\u65F6\u95F4","children":[]},{"level":3,"title":"\u901A\u8FC7 Blob \u4E0B\u8F7D\u6587\u4EF6","slug":"\u901A\u8FC7-blob-\u4E0B\u8F7D\u6587\u4EF6","link":"#\u901A\u8FC7-blob-\u4E0B\u8F7D\u6587\u4EF6","children":[]},{"level":3,"title":"\u5FAE\u4FE1H5\u6253\u5F00\u5C0F\u7A0B\u5E8F","slug":"\u5FAE\u4FE1h5\u6253\u5F00\u5C0F\u7A0B\u5E8F","link":"#\u5FAE\u4FE1h5\u6253\u5F00\u5C0F\u7A0B\u5E8F","children":[]},{"level":3,"title":"web\u83B7\u53D6dpr","slug":"web\u83B7\u53D6dpr","link":"#web\u83B7\u53D6dpr","children":[]}]}],"relativePath":"\u5DE5\u4F5C\u5E38\u7528\u4EE3\u7801.md"}'),F={name:"\u5DE5\u4F5C\u5E38\u7528\u4EE3\u7801.md"},y=s(`

SN

chrom \u6DFB\u52A0\u6A21\u62DF app \u7684\u8BBE\u5907

\u5728 User agent string \u4E00\u680F\u4E2D\u586B\u5199

Mozilla/5.0 (iPod touch; CPU iPhone OS 9_2 like Mac OS X) AppleWebKit/601.1.46 (KHTML, like Gecko) Mobile/13C75 2.0.24 CK 2.0
 

\u79FB\u52A8\u7AEF\u6A2A\u5C4F

css
@media screen and (orientation: landscape) {
   /*\u6A2A\u5C4F*/
   main {
@@ -722,4 +722,18 @@ import{_ as o,c as e,b as n,w as t,a as s,r as a,o as c,e as r}from"./app.08e03c
   document.body.removeChild(downloadElement); // \u4E0B\u8F7D\u5B8C\u6210\u79FB\u9664\u5143\u7D20
   window.URL.revokeObjectURL(href); // \u91CA\u653E\u6389blob\u5BF9\u8C61
 }
-
`,38);function A(i,u,d,E,h,g){const l=a("Banner"),p=a("font");return c(),e("div",null,[y,n(l),D,n(p,{size:"5"},{default:t(()=>[r("**[\u6E90\u6587\u4EF6](http://gauhar.top/timeCountDown.js)**")]),_:1}),C])}const b=o(F,[["render",A]]);export{m as __pageData,b as default}; +

\u5FAE\u4FE1H5\u6253\u5F00\u5C0F\u7A0B\u5E8F

https://developers.weixin.qq.com/doc/offiaccount/OA_Web_Apps/Wechat_Open_Tag.html#21

web\u83B7\u53D6dpr

\u4F20\u9012canvas\u7684context

ts
function getRatio (context: any): number {
+  if (!context) {
+    return 1
+  }
+  const backingStore =
+    context.backingStorePixelRatio ||
+    context.webkitBackingStorePixelRatio ||
+    context.mozBackingStorePixelRatio ||
+    context.msBackingStorePixelRatio ||
+    context.oBackingStorePixelRatio ||
+    context.backingStorePixelRatio ||
+    1
+  return (window.devicePixelRatio || 1) / backingStore
+}
+
`,43);function A(i,d,u,E,h,g){const l=a("Banner"),p=a("font");return c(),e("div",null,[y,n(l),D,n(p,{size:"5"},{default:t(()=>[r("**[\u6E90\u6587\u4EF6](http://gauhar.top/timeCountDown.js)**")]),_:1}),C])}const b=o(F,[["render",A]]);export{m as __pageData,b as default}; diff --git "a/assets/\345\267\245\344\275\234\345\270\270\347\224\250\344\273\243\347\240\201.md.d8b407c5.lean.js" "b/assets/\345\267\245\344\275\234\345\270\270\347\224\250\344\273\243\347\240\201.md.e3c96505.lean.js" similarity index 86% rename from "assets/\345\267\245\344\275\234\345\270\270\347\224\250\344\273\243\347\240\201.md.d8b407c5.lean.js" rename to "assets/\345\267\245\344\275\234\345\270\270\347\224\250\344\273\243\347\240\201.md.e3c96505.lean.js" index 2269aae..57b8f7c 100644 --- "a/assets/\345\267\245\344\275\234\345\270\270\347\224\250\344\273\243\347\240\201.md.d8b407c5.lean.js" +++ "b/assets/\345\267\245\344\275\234\345\270\270\347\224\250\344\273\243\347\240\201.md.e3c96505.lean.js" @@ -1 +1 @@ -import{_ as o,c as e,b as n,w as t,a as s,r as a,o as c,e as r}from"./app.08e03c58.js";const m=JSON.parse('{"title":"","description":"","frontmatter":{},"headers":[{"level":2,"title":"SN","slug":"sn","link":"#sn","children":[{"level":3,"title":"chrom \u6DFB\u52A0\u6A21\u62DF app \u7684\u8BBE\u5907","slug":"chrom-\u6DFB\u52A0\u6A21\u62DF-app-\u7684\u8BBE\u5907","link":"#chrom-\u6DFB\u52A0\u6A21\u62DF-app-\u7684\u8BBE\u5907","children":[]},{"level":3,"title":"\u79FB\u52A8\u7AEF\u6A2A\u5C4F","slug":"\u79FB\u52A8\u7AEF\u6A2A\u5C4F","link":"#\u79FB\u52A8\u7AEF\u6A2A\u5C4F","children":[]},{"level":3,"title":"\u4E0A\u62C9\u52A0\u8F7D\u5206\u9875","slug":"\u4E0A\u62C9\u52A0\u8F7D\u5206\u9875","link":"#\u4E0A\u62C9\u52A0\u8F7D\u5206\u9875","children":[]},{"level":3,"title":"\u8BB0\u4F4F\u5BC6\u7801","slug":"\u8BB0\u4F4F\u5BC6\u7801","link":"#\u8BB0\u4F4F\u5BC6\u7801","children":[]},{"level":3,"title":"\u5BC6\u7801\u662F\u5426\u53EF\u89C1","slug":"\u5BC6\u7801\u662F\u5426\u53EF\u89C1","link":"#\u5BC6\u7801\u662F\u5426\u53EF\u89C1","children":[]},{"level":3,"title":"\u9A8C\u8BC1\u7801","slug":"\u9A8C\u8BC1\u7801","link":"#\u9A8C\u8BC1\u7801","children":[]},{"level":3,"title":"\u6587\u4EF6\u4E0A\u4F20","slug":"\u6587\u4EF6\u4E0A\u4F20","link":"#\u6587\u4EF6\u4E0A\u4F20","children":[]},{"level":3,"title":"\u6A21\u677F\u8BED\u6CD5","slug":"\u6A21\u677F\u8BED\u6CD5","link":"#\u6A21\u677F\u8BED\u6CD5","children":[]},{"level":3,"title":"workman","slug":"workman","link":"#workman","children":[]},{"level":3,"title":"\u590D\u5236\u6587\u672C","slug":"\u590D\u5236\u6587\u672C","link":"#\u590D\u5236\u6587\u672C","children":[]},{"level":3,"title":"\u5168\u9009\u4E0E\u5168\u4E0D\u9009","slug":"\u5168\u9009\u4E0E\u5168\u4E0D\u9009","link":"#\u5168\u9009\u4E0E\u5168\u4E0D\u9009","children":[]},{"level":3,"title":"moment.js","slug":"moment-js","link":"#moment-js","children":[]},{"level":3,"title":"\u9AD8\u4EFF ios \u6570\u91CF\u9009\u62E9\u5668","slug":"\u9AD8\u4EFF-ios-\u6570\u91CF\u9009\u62E9\u5668","link":"#\u9AD8\u4EFF-ios-\u6570\u91CF\u9009\u62E9\u5668","children":[]},{"level":3,"title":"\u6ED1\u52A8\u5207\u6362","slug":"\u6ED1\u52A8\u5207\u6362","link":"#\u6ED1\u52A8\u5207\u6362","children":[]},{"level":3,"title":"\u8FDB\u5EA6\u6761","slug":"\u8FDB\u5EA6\u6761","link":"#\u8FDB\u5EA6\u6761","children":[]},{"level":3,"title":"\u7981\u6B62\u7528\u6237\u6253\u5F00\u63A7\u5236\u53F0","slug":"\u7981\u6B62\u7528\u6237\u6253\u5F00\u63A7\u5236\u53F0","link":"#\u7981\u6B62\u7528\u6237\u6253\u5F00\u63A7\u5236\u53F0","children":[]},{"level":3,"title":"\u6587\u5B57\u6EDA\u52A8","slug":"\u6587\u5B57\u6EDA\u52A8","link":"#\u6587\u5B57\u6EDA\u52A8","children":[]},{"level":3,"title":"\u5012\u8BA1\u65F6","slug":"\u5012\u8BA1\u65F6","link":"#\u5012\u8BA1\u65F6","children":[]},{"level":3,"title":"\u4FEE\u6539placeholder\u6837\u5F0F","slug":"\u4FEE\u6539placeholder\u6837\u5F0F","link":"#\u4FEE\u6539placeholder\u6837\u5F0F","children":[]},{"level":3,"title":"emmet \u8BED\u6CD5\u751F\u6210\u65E0\u610F\u4E49\u6587\u5B57","slug":"emmet-\u8BED\u6CD5\u751F\u6210\u65E0\u610F\u4E49\u6587\u5B57","link":"#emmet-\u8BED\u6CD5\u751F\u6210\u65E0\u610F\u4E49\u6587\u5B57","children":[]},{"level":3,"title":"\u6587\u672C\u6EA2\u51FA\uFF0C\u4EE5...\u8868\u793A","slug":"\u6587\u672C\u6EA2\u51FA-\u4EE5-\u8868\u793A","link":"#\u6587\u672C\u6EA2\u51FA-\u4EE5-\u8868\u793A","children":[]},{"level":3,"title":"\u5224\u65AD\u5BF9\u8C61\u6709\u65E0\u6307\u5B9A\u5C5E\u6027","slug":"\u5224\u65AD\u5BF9\u8C61\u6709\u65E0\u6307\u5B9A\u5C5E\u6027","link":"#\u5224\u65AD\u5BF9\u8C61\u6709\u65E0\u6307\u5B9A\u5C5E\u6027","children":[]},{"level":3,"title":"\u5224\u65AD\u624B\u673A\uFF08\u5B89\u5353\uFF0C\u82F9\u679C\uFF09","slug":"\u5224\u65AD\u624B\u673A-\u5B89\u5353-\u82F9\u679C","link":"#\u5224\u65AD\u624B\u673A-\u5B89\u5353-\u82F9\u679C","children":[]}]},{"level":2,"title":"LC","slug":"lc","link":"#lc","children":[{"level":3,"title":"\u6743\u9650","slug":"\u6743\u9650","link":"#\u6743\u9650","children":[]},{"level":3,"title":"element","slug":"element","link":"#element","children":[]}]},{"level":2,"title":"HONGDU","slug":"hongdu","link":"#hongdu","children":[{"level":3,"title":"\u7981\u6B62\u5F00\u53D1\u8005\u5DE5\u5177\u8C03\u8BD5","slug":"\u7981\u6B62\u5F00\u53D1\u8005\u5DE5\u5177\u8C03\u8BD5","link":"#\u7981\u6B62\u5F00\u53D1\u8005\u5DE5\u5177\u8C03\u8BD5","children":[]},{"level":3,"title":"\u83B7\u53D6\u5F53\u524D\u65E5\u671F\u7684\u4E00\u5468\u65F6\u95F4","slug":"\u83B7\u53D6\u5F53\u524D\u65E5\u671F\u7684\u4E00\u5468\u65F6\u95F4","link":"#\u83B7\u53D6\u5F53\u524D\u65E5\u671F\u7684\u4E00\u5468\u65F6\u95F4","children":[]},{"level":3,"title":"\u901A\u8FC7 Blob \u4E0B\u8F7D\u6587\u4EF6","slug":"\u901A\u8FC7-blob-\u4E0B\u8F7D\u6587\u4EF6","link":"#\u901A\u8FC7-blob-\u4E0B\u8F7D\u6587\u4EF6","children":[]}]}],"relativePath":"\u5DE5\u4F5C\u5E38\u7528\u4EE3\u7801.md"}'),F={name:"\u5DE5\u4F5C\u5E38\u7528\u4EE3\u7801.md"},y=s("",35),D=s("",25),C=s("",38);function A(i,u,d,E,h,g){const l=a("Banner"),p=a("font");return c(),e("div",null,[y,n(l),D,n(p,{size:"5"},{default:t(()=>[r("**[\u6E90\u6587\u4EF6](http://gauhar.top/timeCountDown.js)**")]),_:1}),C])}const b=o(F,[["render",A]]);export{m as __pageData,b as default}; +import{_ as o,c as e,b as n,w as t,a as s,r as a,o as c,e as r}from"./app.08e03c58.js";const m=JSON.parse('{"title":"","description":"","frontmatter":{},"headers":[{"level":2,"title":"SN","slug":"sn","link":"#sn","children":[{"level":3,"title":"chrom \u6DFB\u52A0\u6A21\u62DF app \u7684\u8BBE\u5907","slug":"chrom-\u6DFB\u52A0\u6A21\u62DF-app-\u7684\u8BBE\u5907","link":"#chrom-\u6DFB\u52A0\u6A21\u62DF-app-\u7684\u8BBE\u5907","children":[]},{"level":3,"title":"\u79FB\u52A8\u7AEF\u6A2A\u5C4F","slug":"\u79FB\u52A8\u7AEF\u6A2A\u5C4F","link":"#\u79FB\u52A8\u7AEF\u6A2A\u5C4F","children":[]},{"level":3,"title":"\u4E0A\u62C9\u52A0\u8F7D\u5206\u9875","slug":"\u4E0A\u62C9\u52A0\u8F7D\u5206\u9875","link":"#\u4E0A\u62C9\u52A0\u8F7D\u5206\u9875","children":[]},{"level":3,"title":"\u8BB0\u4F4F\u5BC6\u7801","slug":"\u8BB0\u4F4F\u5BC6\u7801","link":"#\u8BB0\u4F4F\u5BC6\u7801","children":[]},{"level":3,"title":"\u5BC6\u7801\u662F\u5426\u53EF\u89C1","slug":"\u5BC6\u7801\u662F\u5426\u53EF\u89C1","link":"#\u5BC6\u7801\u662F\u5426\u53EF\u89C1","children":[]},{"level":3,"title":"\u9A8C\u8BC1\u7801","slug":"\u9A8C\u8BC1\u7801","link":"#\u9A8C\u8BC1\u7801","children":[]},{"level":3,"title":"\u6587\u4EF6\u4E0A\u4F20","slug":"\u6587\u4EF6\u4E0A\u4F20","link":"#\u6587\u4EF6\u4E0A\u4F20","children":[]},{"level":3,"title":"\u6A21\u677F\u8BED\u6CD5","slug":"\u6A21\u677F\u8BED\u6CD5","link":"#\u6A21\u677F\u8BED\u6CD5","children":[]},{"level":3,"title":"workman","slug":"workman","link":"#workman","children":[]},{"level":3,"title":"\u590D\u5236\u6587\u672C","slug":"\u590D\u5236\u6587\u672C","link":"#\u590D\u5236\u6587\u672C","children":[]},{"level":3,"title":"\u5168\u9009\u4E0E\u5168\u4E0D\u9009","slug":"\u5168\u9009\u4E0E\u5168\u4E0D\u9009","link":"#\u5168\u9009\u4E0E\u5168\u4E0D\u9009","children":[]},{"level":3,"title":"moment.js","slug":"moment-js","link":"#moment-js","children":[]},{"level":3,"title":"\u9AD8\u4EFF ios \u6570\u91CF\u9009\u62E9\u5668","slug":"\u9AD8\u4EFF-ios-\u6570\u91CF\u9009\u62E9\u5668","link":"#\u9AD8\u4EFF-ios-\u6570\u91CF\u9009\u62E9\u5668","children":[]},{"level":3,"title":"\u6ED1\u52A8\u5207\u6362","slug":"\u6ED1\u52A8\u5207\u6362","link":"#\u6ED1\u52A8\u5207\u6362","children":[]},{"level":3,"title":"\u8FDB\u5EA6\u6761","slug":"\u8FDB\u5EA6\u6761","link":"#\u8FDB\u5EA6\u6761","children":[]},{"level":3,"title":"\u7981\u6B62\u7528\u6237\u6253\u5F00\u63A7\u5236\u53F0","slug":"\u7981\u6B62\u7528\u6237\u6253\u5F00\u63A7\u5236\u53F0","link":"#\u7981\u6B62\u7528\u6237\u6253\u5F00\u63A7\u5236\u53F0","children":[]},{"level":3,"title":"\u6587\u5B57\u6EDA\u52A8","slug":"\u6587\u5B57\u6EDA\u52A8","link":"#\u6587\u5B57\u6EDA\u52A8","children":[]},{"level":3,"title":"\u5012\u8BA1\u65F6","slug":"\u5012\u8BA1\u65F6","link":"#\u5012\u8BA1\u65F6","children":[]},{"level":3,"title":"\u4FEE\u6539placeholder\u6837\u5F0F","slug":"\u4FEE\u6539placeholder\u6837\u5F0F","link":"#\u4FEE\u6539placeholder\u6837\u5F0F","children":[]},{"level":3,"title":"emmet \u8BED\u6CD5\u751F\u6210\u65E0\u610F\u4E49\u6587\u5B57","slug":"emmet-\u8BED\u6CD5\u751F\u6210\u65E0\u610F\u4E49\u6587\u5B57","link":"#emmet-\u8BED\u6CD5\u751F\u6210\u65E0\u610F\u4E49\u6587\u5B57","children":[]},{"level":3,"title":"\u6587\u672C\u6EA2\u51FA\uFF0C\u4EE5...\u8868\u793A","slug":"\u6587\u672C\u6EA2\u51FA-\u4EE5-\u8868\u793A","link":"#\u6587\u672C\u6EA2\u51FA-\u4EE5-\u8868\u793A","children":[]},{"level":3,"title":"\u5224\u65AD\u5BF9\u8C61\u6709\u65E0\u6307\u5B9A\u5C5E\u6027","slug":"\u5224\u65AD\u5BF9\u8C61\u6709\u65E0\u6307\u5B9A\u5C5E\u6027","link":"#\u5224\u65AD\u5BF9\u8C61\u6709\u65E0\u6307\u5B9A\u5C5E\u6027","children":[]},{"level":3,"title":"\u5224\u65AD\u624B\u673A\uFF08\u5B89\u5353\uFF0C\u82F9\u679C\uFF09","slug":"\u5224\u65AD\u624B\u673A-\u5B89\u5353-\u82F9\u679C","link":"#\u5224\u65AD\u624B\u673A-\u5B89\u5353-\u82F9\u679C","children":[]}]},{"level":2,"title":"LC","slug":"lc","link":"#lc","children":[{"level":3,"title":"\u6743\u9650","slug":"\u6743\u9650","link":"#\u6743\u9650","children":[]},{"level":3,"title":"element","slug":"element","link":"#element","children":[]}]},{"level":2,"title":"HONGDU","slug":"hongdu","link":"#hongdu","children":[{"level":3,"title":"\u7981\u6B62\u5F00\u53D1\u8005\u5DE5\u5177\u8C03\u8BD5","slug":"\u7981\u6B62\u5F00\u53D1\u8005\u5DE5\u5177\u8C03\u8BD5","link":"#\u7981\u6B62\u5F00\u53D1\u8005\u5DE5\u5177\u8C03\u8BD5","children":[]},{"level":3,"title":"\u83B7\u53D6\u5F53\u524D\u65E5\u671F\u7684\u4E00\u5468\u65F6\u95F4","slug":"\u83B7\u53D6\u5F53\u524D\u65E5\u671F\u7684\u4E00\u5468\u65F6\u95F4","link":"#\u83B7\u53D6\u5F53\u524D\u65E5\u671F\u7684\u4E00\u5468\u65F6\u95F4","children":[]},{"level":3,"title":"\u901A\u8FC7 Blob \u4E0B\u8F7D\u6587\u4EF6","slug":"\u901A\u8FC7-blob-\u4E0B\u8F7D\u6587\u4EF6","link":"#\u901A\u8FC7-blob-\u4E0B\u8F7D\u6587\u4EF6","children":[]},{"level":3,"title":"\u5FAE\u4FE1H5\u6253\u5F00\u5C0F\u7A0B\u5E8F","slug":"\u5FAE\u4FE1h5\u6253\u5F00\u5C0F\u7A0B\u5E8F","link":"#\u5FAE\u4FE1h5\u6253\u5F00\u5C0F\u7A0B\u5E8F","children":[]},{"level":3,"title":"web\u83B7\u53D6dpr","slug":"web\u83B7\u53D6dpr","link":"#web\u83B7\u53D6dpr","children":[]}]}],"relativePath":"\u5DE5\u4F5C\u5E38\u7528\u4EE3\u7801.md"}'),F={name:"\u5DE5\u4F5C\u5E38\u7528\u4EE3\u7801.md"},y=s("",35),D=s("",25),C=s("",43);function A(i,d,u,E,h,g){const l=a("Banner"),p=a("font");return c(),e("div",null,[y,n(l),D,n(p,{size:"5"},{default:t(()=>[r("**[\u6E90\u6587\u4EF6](http://gauhar.top/timeCountDown.js)**")]),_:1}),C])}const b=o(F,[["render",A]]);export{m as __pageData,b as default}; diff --git "a/es6\347\254\224\350\256\260.html" "b/es6\347\254\224\350\256\260.html" index 375edfa..2912db2 100644 --- "a/es6\347\254\224\350\256\260.html" +++ "b/es6\347\254\224\350\256\260.html" @@ -339,7 +339,7 @@

初始化对象

最好把对象静态化

js
const a = { x: null };
 a.x = 3;
 
- + diff --git a/flutter.html b/flutter.html index a420c70..afeace9 100644 --- a/flutter.html +++ b/flutter.html @@ -16,7 +16,7 @@
Skip to content
本页目录

flutter中文网

起步

下载 flutter,国内建议下载压缩包。

添加环境变量

具体的路径由你自己把控,sdk,avd 虚拟机通过 android studio 下载

  1. 打开 Android Studio SDK Manager
  2. 找到 Android SDK 这个选项卡,取消勾选 Hide Obsolete Packages
  3. 下载 Android SDK Tools (Obsolete)

tips

安装好 android sdk 和 AVD 安卓手机模拟器后,打开命令行,执行flutter doctor

如果提示flutter doctor --android-licenses,就执行该命令,全部输入y

说明:

  1. ANDROID_HOME:安卓 SDK 文件夹路径 默认 c 盘位置:C:\Users\gauhar\AppData\Local\Android\Sdk
  2. ANDROID_SDK_HOME:安卓手机模拟器路径 默认 c 盘位置:C:\Users\gauhar\.android\avd
  3. 其他两个是镜像地址,如果你可以科学上网可以不用设置
变量名变量值
ANDROID_HOMED:\AndroidSDK
ANDROID_SDK_HOMED:\android_avd
FLUTTER_STORAGE_BASE_URLhttps://storage.flutter-io.cn
PUB_HOSTED_URLhttps://pub.flutter-io.cn

创建项目

  1. vscode 中安装flutter插件,同时他会自动安装dart插件
  2. ctrl + shift + p打开命令面板,输入flutter,选择Flutter: New Project
  3. 输入项目名,创建之后慢慢等待
  4. F5运行项目,如果没有模拟器,去android studio新建一个
  5. 如果是真机调试,注意看手机的安装提示,过了时间就默认不安装了
  6. 修改main.dart文件
- + diff --git a/hashmap.json b/hashmap.json index 2c75b4b..e94633a 100644 --- a/hashmap.json +++ b/hashmap.json @@ -1 +1 @@ -{"taro开发中的坑.md":"b47f2e84","vue.js设计与实现-阅读笔记.md":"6966ea21","antv.md":"49e79830","es6笔记.md":"9587c9f3","flutter.md":"cf758a9f","index.md":"0fc07c0c","js学习笔记.md":"ffad86ff","js笔记.md":"cc11ff74","note.md":"18a12138","react笔记.md":"562a00ae","taro.md":"aa7cee6f","typescript.md":"6a1b610e","uniapp.md":"e2e23086","utils.md":"43c9df7a","vite-plugin-shared.md":"4fe6106f","vue3.md":"6dfc138c","vue3源码.md":"b10d56c3","vue笔记.md":"75f1f18d","webpack.md":"cd045ad1","工作上遇到的坑.md":"d91ed733","工作常用代码.md":"d8b407c5","常用代码.md":"848d0634","微信小程序.md":"2de31641","文章链接.md":"26f477a7","正则表达式.md":"9b71bb5a","那些坑.md":"73144ec9","问题.md":"fdc3fc34"} +{"taro开发中的坑.md":"b47f2e84","vue.js设计与实现-阅读笔记.md":"6966ea21","antv.md":"49e79830","es6笔记.md":"9587c9f3","flutter.md":"cf758a9f","index.md":"0fc07c0c","js学习笔记.md":"ffad86ff","js笔记.md":"cc11ff74","note.md":"18a12138","react笔记.md":"562a00ae","taro.md":"aa7cee6f","typescript.md":"6a1b610e","uniapp.md":"e2e23086","utils.md":"43c9df7a","vite-plugin-shared.md":"4fe6106f","vue3.md":"6dfc138c","vue3源码.md":"b10d56c3","vue笔记.md":"75f1f18d","webpack.md":"cd045ad1","工作上遇到的坑.md":"d91ed733","工作常用代码.md":"e3c96505","常用代码.md":"848d0634","微信小程序.md":"2de31641","文章链接.md":"26f477a7","正则表达式.md":"9b71bb5a","那些坑.md":"73144ec9","问题.md":"fdc3fc34"} diff --git a/index.html b/index.html index d74be8e..a0f69e6 100644 --- a/index.html +++ b/index.html @@ -16,7 +16,7 @@
Skip to content
本页目录

Home🏡

Persevere or give up, only the difference in one thought

- + diff --git "a/js\345\255\246\344\271\240\347\254\224\350\256\260.html" "b/js\345\255\246\344\271\240\347\254\224\350\256\260.html" index 1938d3a..9417a51 100644 --- "a/js\345\255\246\344\271\240\347\254\224\350\256\260.html" +++ "b/js\345\255\246\344\271\240\347\254\224\350\256\260.html" @@ -599,7 +599,7 @@ console.log(c.name); // gauhar c.pro(); // prototype_pro - + diff --git "a/js\347\254\224\350\256\260.html" "b/js\347\254\224\350\256\260.html" index bd649be..1618970 100644 --- "a/js\347\254\224\350\256\260.html" +++ "b/js\347\254\224\350\256\260.html" @@ -172,7 +172,7 @@ scroll-behavior: smooth; }

scrollingElement

该对象可以非常兼容地获取scrollTopscrollHeight等属性,在移动端PC端都屡试不爽

- + diff --git a/note.html b/note.html index d9fca4a..e0e2e99 100644 --- a/note.html +++ b/note.html @@ -71,7 +71,7 @@ let input = yield; // OK } - + diff --git "a/react\347\254\224\350\256\260.html" "b/react\347\254\224\350\256\260.html" index a7d8ca2..793739d 100644 --- "a/react\347\254\224\350\256\260.html" +++ "b/react\347\254\224\350\256\260.html" @@ -273,7 +273,7 @@ </Router> ); - + diff --git a/taro.html b/taro.html index 2a7616f..3aa3c3d 100644 --- a/taro.html +++ b/taro.html @@ -640,7 +640,7 @@ } }

生命周期

入口文件

componentWillMount()

对应小程序的onLaunch,全局触发一次,通过this.$router.params访问路由地址、携带的参数

componentDidMount()

对应小程序的onLaunch,在componentWillMount之后执行

componentDidShow()

对应小程序的onShow

componentDidHide()

对应小程序的onHide

componentDidCatchError(String error)

在微信/百度/字节跳动/支付宝小程序中这一生命周期方法对应 onError,H5/RN 中尚未实现

程序发生脚本错误或 API 调用报错时触发,微信小程序中也可以使用 Taro.onError 绑定监听

componentDidNotFound(Object)

在微信/字节跳动小程序中这一生命周期方法对应 onPageNotFound,其他端尚未实现 微信小程序中,基础库 1.9.90 开始支持

程序要打开的页面不存在时触发,微信小程序中也可以使用 Taro.onPageNotFound 绑定监听

页面文件

组件传值不更新

通过props传值,组件中获取的值还是旧数据

解决方法: 在父组件更新数据之前,先清空,再赋值

- + diff --git a/typeScript.html b/typeScript.html index 0d62b4e..9bc2d87 100644 --- a/typeScript.html +++ b/typeScript.html @@ -135,7 +135,7 @@ console.log('mounted'); } - + diff --git a/uniapp.html b/uniapp.html index 91beef3..a073a27 100644 --- a/uniapp.html +++ b/uniapp.html @@ -254,7 +254,7 @@ border-top-right-radius: 20rpx; }

ref

内置的组件中不可以使用this.$refs获取,只能用于自定义组件

- + diff --git a/utils.html b/utils.html index ab4de90..8342882 100644 --- a/utils.html +++ b/utils.html @@ -179,7 +179,7 @@ } else return; } - + diff --git a/vite-plugin-shared.html b/vite-plugin-shared.html index fe8084e..d5731bc 100644 --- a/vite-plugin-shared.html +++ b/vite-plugin-shared.html @@ -319,7 +319,7 @@ // ... }));

现在我们的shared工具就会在正常启动项目的时候运行啦,没有配置的心智负担了

插件配置参数
参数名描述类型
source页面文件夹路径,一般是 src/views、src/pagesstring[可选]
showDeleted是否展示对已删除文件引用的文件列表boolean[可选]

发包注意事项

future feature

image-20230227154033391

目前有个痛点是,我们抛出的成员名称是以文件夹+文件名命名的,assets原有的ts文件一旦重命名,那么成员的名称将会变更,同时页面中的引用需要我们手动更改

chokidar没有提供重命名的事件监听

- + diff --git a/vue3.html b/vue3.html index 199aa90..ab4f5cf 100644 --- a/vue3.html +++ b/vue3.html @@ -531,7 +531,7 @@ // mutate count.value, should trigger onTrigger count.value++; - + diff --git "a/vue3\346\272\220\347\240\201.html" "b/vue3\346\272\220\347\240\201.html" index 05146ff..0cdb8f4 100644 --- "a/vue3\346\272\220\347\240\201.html" +++ "b/vue3\346\272\220\347\240\201.html" @@ -235,7 +235,7 @@ export const toReadonly = <T extends unknown>(value: T): T => isObject(value) ? readonly(value as Record<any, any>) : value - + diff --git "a/vue\347\254\224\350\256\260.html" "b/vue\347\254\224\350\256\260.html" index b2debf4..a8f9117 100644 --- "a/vue\347\254\224\350\256\260.html" +++ "b/vue\347\254\224\350\256\260.html" @@ -512,7 +512,7 @@ </my-component>

强制更新

迫使 Vue 实例重新渲染。注意它仅仅影响实例本身和插入插槽内容的子组件,而不是所有子组件。

直接调用即可,如果是因为新增对象或者数组的属性、请使用this.$set新增属性

js
this.$forceUpdate();
 
- + diff --git a/webpack.html b/webpack.html index 517d5f5..ae283d0 100644 --- a/webpack.html +++ b/webpack.html @@ -154,7 +154,7 @@

哪个文件需要,就在哪里引入

js
import @babel/polyfill
 

souce-map

通过 webpack 的 devtool 选项,配置哪一种。

定义 souce-map,开发调试更方便,展示源代码,如:打印位置能准确定位

js
devtool: "cheap-module-eval-source-map";
 
- + diff --git "a/\345\267\245\344\275\234\344\270\212\351\201\207\345\210\260\347\232\204\345\235\221.html" "b/\345\267\245\344\275\234\344\270\212\351\201\207\345\210\260\347\232\204\345\235\221.html" index 1e699b9..b892a7f 100644 --- "a/\345\267\245\344\275\234\344\270\212\351\201\207\345\210\260\347\232\204\345\235\221.html" +++ "b/\345\267\245\344\275\234\344\270\212\351\201\207\345\210\260\347\232\204\345\235\221.html" @@ -240,7 +240,7 @@ </html>

vscdoe 行尾序列格式

vscdoe 行尾序列格式有两种

  1. LF
  2. CRLF

坑:

当 vscode 编辑器的格式与项目中的配置不同时,prettier 会报错。

git 拉代码的时候默认是 CRLF 格式

解决方法:

执行命令

shell
git config --global core.autocrlf false
 
- + diff --git "a/\345\267\245\344\275\234\345\270\270\347\224\250\344\273\243\347\240\201.html" "b/\345\267\245\344\275\234\345\270\270\347\224\250\344\273\243\347\240\201.html" index 655d2ae..7e17953 100644 --- "a/\345\267\245\344\275\234\345\270\270\347\224\250\344\273\243\347\240\201.html" +++ "b/\345\267\245\344\275\234\345\270\270\347\224\250\344\273\243\347\240\201.html" @@ -8,7 +8,7 @@ - + @@ -739,8 +739,22 @@ document.body.removeChild(downloadElement); // 下载完成移除元素 window.URL.revokeObjectURL(href); // 释放掉blob对象 } +

微信H5打开小程序

https://developers.weixin.qq.com/doc/offiaccount/OA_Web_Apps/Wechat_Open_Tag.html#21

web获取dpr

传递canvascontext

ts
function getRatio (context: any): number {
+  if (!context) {
+    return 1
+  }
+  const backingStore =
+    context.backingStorePixelRatio ||
+    context.webkitBackingStorePixelRatio ||
+    context.mozBackingStorePixelRatio ||
+    context.msBackingStorePixelRatio ||
+    context.oBackingStorePixelRatio ||
+    context.backingStorePixelRatio ||
+    1
+  return (window.devicePixelRatio || 1) / backingStore
+}
 
- + diff --git "a/\345\270\270\347\224\250\344\273\243\347\240\201.html" "b/\345\270\270\347\224\250\344\273\243\347\240\201.html" index 4882002..0b9283c 100644 --- "a/\345\270\270\347\224\250\344\273\243\347\240\201.html" +++ "b/\345\270\270\347\224\250\344\273\243\347\240\201.html" @@ -77,7 +77,7 @@ } } - + diff --git "a/\345\276\256\344\277\241\345\260\217\347\250\213\345\272\217.html" "b/\345\276\256\344\277\241\345\260\217\347\250\213\345\272\217.html" index a8d82e0..9c03bd4 100644 --- "a/\345\276\256\344\277\241\345\260\217\347\250\213\345\272\217.html" +++ "b/\345\276\256\344\277\241\345\260\217\347\250\213\345\272\217.html" @@ -99,7 +99,7 @@ true false

scope 列表

scope对应接口描述
scope.userInfowx.getUserInfo用户信息
scope.userLocationwx.getLocation, wx.chooseLocation地理位置
scope.userLocationBackgroundwx.userLocationBackground后台定位
scope.addresswx.chooseAddress通讯地址
scope.invoiceTitlewx.chooseInvoiceTitle发票抬头
scope.invoicewx.chooseInvoice获取发票
scope.werunwx.getWeRunData微信运动步数
scope.recordwx.startRecord录音功能
scope.writePhotosAlbumwx.saveImageToPhotosAlbum, wx.saveVideoToPhotosAlbum保存到相册
scope.cameracamera 组件摄像头

chooseAddress

获取用户的通讯地址

navigateTo

页面跳转

navigateBack

页面返回

注意点

只有当前页面配置了tabBar时,底部的导航栏才会出现,没有配置的页面底部是没有导航栏的

1564840249809

- + diff --git "a/\346\226\207\347\253\240\351\223\276\346\216\245.html" "b/\346\226\207\347\253\240\351\223\276\346\216\245.html" index df21cb0..9665ff3 100644 --- "a/\346\226\207\347\253\240\351\223\276\346\216\245.html" +++ "b/\346\226\207\347\253\240\351\223\276\346\216\245.html" @@ -16,7 +16,7 @@
Skip to content
本页目录
- + diff --git "a/\346\255\243\345\210\231\350\241\250\350\276\276\345\274\217.html" "b/\346\255\243\345\210\231\350\241\250\350\276\276\345\274\217.html" index 82f8bbf..ab9b8c2 100644 --- "a/\346\255\243\345\210\231\350\241\250\350\276\276\345\274\217.html" +++ "b/\346\255\243\345\210\231\350\241\250\350\276\276\345\274\217.html" @@ -51,7 +51,7 @@
js
let reg = /a{1,2}/;
 console.log(reg.test("1aa56")); //返回true
 

其他常用元字符

总结

正则表达式,只能用于验证字符串是否满足条件(有还是没有),并不是要求字符串是什么样子的。

\w\W通常用于用户名的验证,注意:\w只要出现 字母、数字、下划线 其中的一种,都会返回 true。

空白字符包括 空格、回车(\r) 或者 换行(\n) 、缩进(\t)。

$ 验证特定的字符串的时候记得加(), let reg = /(aa)$/ 这表示验证以 aa 结尾。

.可以匹配空格,但不能匹配\r \n

匹配不是中文:/[^\u4e00-\u9fa5]/

()用于提升优先级,分组

在正则表达式中对空格是敏感的

- + diff --git "a/\351\202\243\344\272\233\345\235\221.html" "b/\351\202\243\344\272\233\345\235\221.html" index 63dfbb5..897f7fe 100644 --- "a/\351\202\243\344\272\233\345\235\221.html" +++ "b/\351\202\243\344\272\233\345\235\221.html" @@ -299,7 +299,7 @@ console[type](log); }; - + diff --git "a/\351\227\256\351\242\230.html" "b/\351\227\256\351\242\230.html" index d7b7b21..d8aca74 100644 --- "a/\351\227\256\351\242\230.html" +++ "b/\351\227\256\351\242\230.html" @@ -376,7 +376,7 @@ var b = {}; //a的引用次数减1,为1 }

引用计数有缺点,就是引用循环。循环引用指的是对象 A 中包含一个指向对象 B 的指针,而对象 B 中也包含一个指向对象 A 的引用。

js 运行原理

runTime

浏览器提供的一些 api,比如windowdom的 api;js 的事件循环、事件队列被称为runTime

堆栈

堆::储存着引用类型的内存地址,闭包的变量也存在于此

栈:储存函数的调用,基本类型的数据。函数上下文执行完毕之后被消除,如果还有引用,那就继续存在于调用栈中。

script标签

defer

defer 会“在后台”下载,浏览器将继续处理 HTML,构建 DOM;然后等 **DOM 构建完成后,脚本才会执行。**也因此这中标签在文档中的位置不重要

async

也是异步加载不会阻塞页面渲染,但是当script加载就绪后,就会根据在文档中的顺序优先执行代码

Set无法对哪些值去重

Set成员是唯一且无序的,没有重复值。 向Set中加入值的时候,不会进行类型转换,类似于精确运算符===,主要的区别在于**NaN等于自身**,==而精确运算符===判断NaN不等于自身。==

方法和属性

实例属性constructor:构造函数 size: 返回元素数量

遍历方法:

keys():返回一个包含集合中所有键的迭代器 values():返回一个包含集合中所有值的迭代器 entries():返回一个包含set对象中所有元素得键值对迭代器 forEach(callback,thisArg):用于对集合成员执行callback

- +