随笔分类 - 前端
摘要:步骤如下: 一、安装vite npm install -g create-vite 二、创建vue程序,不需要先创建好空的文件夹,直接执行下面的代码即可 create-vite test --template vue 三、使用npm引入element-plus npm install element
阅读全文
摘要:一、安装angular cli npm install -g @angular/cli 二、使用angular cli新建项目 ng new test 三、使用npm引入ng-devui npm i ng-devui # 可选,字体图标库, 部分Demo依赖此字体库 # npm i @devui-d
阅读全文
摘要:这是因为当前版本与4.0.0不兼容 卸载当前版本sass: npm uninstall node-sass 安装指定版本sass: npm install node-sass@4.14.1 参考这里 https://www.cnblogs.com/lisir-blogshare/p/15439088
阅读全文
摘要:运行npm run dev报错:'webpack-dev-server' 不是内部或外部命令,也不是可运行的程序' 原因:没有安装依赖,可以看看当前文件夹是否存在node_modules文件夹,报这个错一般是不存在node_modules文件夹,执行:npm i,等待完成即可。
阅读全文
摘要:需要实现的效果如下: 需求描述: 有这样的三组radio,要实现:可以分别点击,互不干扰 实现步骤: element 代码如下: <row-wrapper> <template><el-radio-group v-model="form.logicOp[index]" :id="'logicOp['
阅读全文
摘要:背景: 对vue的props里的属性赋值,页面上看赋值后props里的属性值被改变了,但是在控制台发现报错:Avoid mutating a prop directly since the value will be overwritten whenever 解决办法: 把props里的属性,放到d
阅读全文
摘要:背景: 如果你的项目开发使用的是若依,前端需要安装依赖,这个时候选择合适的版本,可以避免安装依赖时报错,经过实践,截至目前,比较合适的版本如下: node 14.19.3 使用nvm进行安装,命令如下: nvm install 14.19.3 nvm use 14.19.3
阅读全文
摘要:子组件想要使用父组件的参数,最简单的方法是使用this.$parent 参考资料: https://www.jianshu.com/p/20eb82bc53e7 https://www.cnblogs.com/panwudi/p/15784649.html
阅读全文
摘要:<el-tree :data="data6" node-key="id" :props="defaultProps" default-expand-all @node-drag-start="handleDragStart" @node-drag-enter="handleDragEnter" @n
阅读全文
摘要:参考资料: https://www.coolcou.com/typescript/typescript-language/typescript-expand-operator.html
阅读全文
摘要:参考资料: https://blog.csdn.net/BADAO_LIUMANG_QIZHI/article/details/108069279 https://juejin.cn/post/6997587227807072264 https://heptaluan.github.io/2019/
阅读全文
摘要:参考资料: https://www.cnblogs.com/onesea/p/15346649.html https://blog.csdn.net/weixin_34188576/article/details/113316033 https://www.csdn.net/tags/OtDaUg0
阅读全文
摘要:config.module.rule('images').use('url-loader') .loader('file-loader') // replaces the url-loader .tap(options => Object.assign(options, { name: 'img/a
阅读全文
摘要:在Windows下安装nvm可以参考这里https://www.jianshu.com/p/cce91f3bb181 nvm安装完成以后,需要进行配置,具体步骤如下: nvm list available nvm install 16.12.0 nvm use 16.12.0 在执行 nvm use
阅读全文
摘要:一、安装compodoc npm install --save-dev @compodoc/compodoc 没有使用全局安装,生成文档的时候,需要执行 ./node_modules/.bin/compodoc -p tsconfig.app.json -s -r 9000 编辑package.js
阅读全文
摘要:https://thecodemon.com/angular-oauth2-or-open-id-connect-using-angular-oauth2-oidc-tutorial-with-example-application/
阅读全文
摘要:背景: get请求/sanctum/csrf-cookie,常用于登录,代码如下: return this.http.get<any>(this.apiURL + ':' + this.port + '/sanctum/csrf-cookie', { withCredentials: true })
阅读全文
摘要:Short answer: withCredentials() makes your browser include cookies and authentication headers in your XHR request. If your service depends on any cook
阅读全文