首页
关于
推荐
CSDN
Search
1
文件上传下载-io-流的理解-笔记
128 阅读
2
vue循环指令el-table-column展示图片src路径拼接
121 阅读
3
正则表达式,将字符串分割两部分
111 阅读
4
MySQL数据库练习【一】
109 阅读
5
MySQL数据库练习【三】
92 阅读
默认分类
Mysql
Java基础
一天一练
Mongodb
Nginx
Docker
FastDFS
面试题
云计算基础
linux基础
shell脚本
实验
工具
基础命令
redis
zookeeper
部署
案例
登录
Search
标签搜索
vue
Mysql
IO
面试题
良辰美景好时光
累计撰写
67
篇文章
累计收到
0
条评论
首页
栏目
默认分类
Mysql
Java基础
一天一练
Mongodb
Nginx
Docker
FastDFS
面试题
云计算基础
linux基础
shell脚本
实验
工具
基础命令
redis
zookeeper
部署
案例
页面
关于
推荐
CSDN
搜索到
2
篇与
的结果
2024-03-13
vue【opensslErrorStack: [ 'error:03000086:digital envelope routines::initialization error' ]】
@TOC一、Vue项目启动报错如下> front@0.1.0 serve > vue-cli-service serve Browserslist: caniuse-lite is outdated. Please run: npx browserslist@latest --update-db Why you should do it regularly: https://github.com/browserslist/browserslist#browsers-data-updating INFO Starting development server... 10% building 2/5 modules 3 active ...rontsHospital\front\node_modules\eslint-loader\index.js??ref--14-0!D:\Vue\front\src\main.js E rror: error:0308010C:digital envelope routines::unsupported at new Hash (node:internal/crypto/hash:68:19) at Object.createHash (node:crypto:138:10) at module.exports (D:\Vue\front\node_modules\webpack\lib\util\createHash.js:135:53) at NormalModule._initBuildHash (D:\Vue\front\node_modules\webpack\lib\NormalModule.js:417:16) at handleParseError (D:\Vue\front\node_modules\webpack\lib\NormalModule.js:471:10) at D:\Vue\front\node_modules\webpack\lib\NormalModule.js:503:5 at D:\Vue\front\node_modules\webpack\lib\NormalModule.js:358:12 at D:\Vue\front\node_modules\loader-runner\lib\LoaderRunner.js:373:3 at iterateNormalLoaders (D:\Vue\front\node_modules\loader-runner\lib\LoaderRunner.js:214:10) at iterateNormalLoaders (D:\Vue\front\node_modules\loader-runner\lib\LoaderRunner.js:221:10) at D:\Vue\front\node_modules\loader-runner\lib\LoaderRunner.js:236:3 at runSyncOrAsync (D:\Vue\front\node_modules\loader-runner\lib\LoaderRunner.js:130:11) at iterateNormalLoaders (D:\Vue\front\node_modules\loader-runner\lib\LoaderRunner.js:232:2) at Array.<anonymous> (D:\Vue\front\node_modules\loader-runner\lib\LoaderRunner.js:205:4) at Storage.finished (D:\Vue\front\node_modules\enhanced-resolve\lib\CachedInputFileSystem.js:55:16) at D:\Vue\front\node_modules\enhanced-resolve\lib\CachedInputFileSystem.js:91:9 node:internal/crypto/hash:68 this[kHandle] = new _Hash(algorithm, xofLen); ^ Error: error:0308010C:digital envelope routines::unsupported at new Hash (node:internal/crypto/hash:68:19) at Object.createHash (node:crypto:138:10) at module.exports (D:\Vue\front\node_modules\webpack\lib\util\createHash.js:135:53) at NormalModule._initBuildHash (D:\Vue\front\node_modules\webpack\lib\NormalModule.js:417:16) at handleParseError (D:\Vue\front\node_modules\webpack\lib\NormalModule.js:471:10) at D:\Vue\front\node_modules\webpack\lib\NormalModule.js:503:5 at D:\Vue\front\node_modules\webpack\lib\NormalModule.js:358:12 at D:\Vue\front\node_modules\loader-runner\lib\LoaderRunner.js:373:3 at iterateNormalLoaders (D:\Vue\front\node_modules\loader-runner\lib\LoaderRunner.js:214:10) at Array.<anonymous> (D:\Vue\front\node_modules\loader-runner\lib\LoaderRunner.js:205:4) at D:\Vue\front\node_modules\enhanced-resolve\lib\CachedInputFileSystem.js:91:9 at D:\Vue\front\node_modules\graceful-fs\graceful-fs.js:123:16 at FSReqCallback.readFileAfterClose [as oncomplete] (node:internal/fs/read/context:68:3) { opensslErrorStack: [ 'error:03000086:digital envelope routines::initialization error' ], library: 'digital envelope routines', reason: 'unsupported', Node.js v20.11.0解决方式1:NodeJS版本过高解决方式2:添加项目启动参数在npm run serve项目启动前声明条件变量//windows $env:NODE_OPTIONS="--openssl-legacy-provider" npm run serve //Linux NODE_OPTIONS=--openssl-legacy-provider npm run servePS D:\Vue\front> $env:NODE_OPTIONS="--openssl-legacy-provider" PS D:\Vue\front> npm run serve DONE Compiled successfully in 12694ms 15:30:15 App running at: - Local: http://localhost:8080/ - Network: http://192.168.1.10:8080/ Note that the development build is not optimized. To create a production build, run npm run build. endl
2024年03月13日
82 阅读
0 评论
0 点赞
2024-03-09
vue循环指令el-table-column展示图片src路径拼接
在Vue中,使用el-table-column展示图片时,可以通过拼接图片路径来设置src属性。这里提供一个简单的例子: <template> <el-table :data="tableData" style="width: 100%"> <el-table-column prop="date" label="日期" width="180"></el-table-column> <el-table-column label="图标" width="180"> <template slot-scope="scope"> <img :src="getImageUrl(scope.row.icon)" alt="图标" /> </template> </el-table-column> <!-- 其他列 --> </el-table> </template> <script> export default { data() { return { tableData: [ { date: '2016-05-02', icon: 'image1' }, { date: '2016-05-04', icon: 'image2' }, // 其他数据... ], baseImagePath: 'path/to/your/images/' // 图片的基础路径 }; }, methods: { getImageUrl(icon) { return `${this.baseImagePath}${icon}.png`; // 拼接图片路径 } } }; </script>
2024年03月09日
121 阅读
0 评论
0 点赞