摘要: position.set的时候如果传入字符串那么渲染没有问题、但是导出的时候会出现问题 阅读全文
posted @ 2022-07-26 18:01 莣ㄋ噯 阅读(9) 评论(0) 推荐(0) 编辑
摘要: 第一步 创建控制器的对象 controls 第二步 把控制器添加进去 import {OrbitControls} from 'three/examples/jsm/controls/OrbitControls.js'; 第三步 使用 创建控制器 controls = new OrbitContro 阅读全文
posted @ 2022-07-15 15:17 莣ㄋ噯 阅读(38) 评论(0) 推荐(0) 编辑
摘要: 第一步:下载three的npm包 npm i three -S 第二步 创建容器 <div id="container"><div> 第三步 引入three文件 import * as THREE from 'three' 第四步 声明需要用到的对象(这些对象生命在export default外面的 阅读全文
posted @ 2022-07-15 14:29 莣ㄋ噯 阅读(565) 评论(0) 推荐(0) 编辑
摘要: 1.使用webpack-bundle-analyzer查看打包之后的js包大小 然后改成线上地址等等方式优化打包之后的大小2.通过配置externals把插件改成网络地址,优化打包速度3.ui组件按需导入4.路由按需导入、默认地址直接导入的方式5.去掉map文件6.代码压缩(在configureWe 阅读全文
posted @ 2022-06-21 16:26 莣ㄋ噯 阅读(128) 评论(0) 推荐(0) 编辑
摘要: let sort = (arr, callback) => { for (let i = 0; i < arr.length; i++) { for (let j = 0; j < arr.length; j++) { if (callback(arr[i], arr[j]) > 0) { let 阅读全文
posted @ 2022-06-15 11:06 莣ㄋ噯 阅读(7) 评论(0) 推荐(0) 编辑
摘要: function dateOperation(date = new Date()) { this.myDate = new Date(date); // 格式化时间 this.getFormat = (format = 'YYYY-MM-DD HH:mm:ss', date = this.myDat 阅读全文
posted @ 2022-05-23 17:37 莣ㄋ噯 阅读(24) 评论(0) 推荐(0) 编辑
摘要: var a = Object.prototype.toString; console.log(a.call(2));console.log(a.call(true));console.log(a.call('str'));console.log(a.call([]));console.log(a.c 阅读全文
posted @ 2022-05-17 21:04 莣ㄋ噯 阅读(16) 评论(0) 推荐(0) 编辑
摘要: 使用trim()函数去除前后空格 阅读全文
posted @ 2022-05-12 11:19 莣ㄋ噯 阅读(9) 评论(0) 推荐(0) 编辑
摘要: text-align-last: justify; 阅读全文
posted @ 2022-05-08 16:52 莣ㄋ噯 阅读(135) 评论(0) 推荐(0) 编辑
摘要: com-tree.vue <template> <div class="com-tree"> <TreeNodeDom :node="item" v-for="(item,index) in props.treeList" :key="index" @sonTreeFun="treeNodeFun" 阅读全文
posted @ 2022-04-28 15:30 莣ㄋ噯 阅读(239) 评论(0) 推荐(0) 编辑
点击右上角即可分享
微信分享提示