- 博客(9)
- 资源 (2)
- 收藏
- 关注
原创 vue使用docker+node+nginx部署
问题:在网上搜索的dockefileFROM node:lts-alpine as build-stage# # npm镜像,解决报错而引入# RUN npm config set registry https://registry.npm.taobao.org# RUN npm config set sass_binary_site=https://npm.taobao.org/mirrors/node-sass...执行到npm install.
2021-12-22 19:52:15 1565
原创 react 添加富文本编辑器BraftEditor
需求:react添加一款富文本编辑器,可配置字体等方案:选择BraftEditor,extendControls属性为可扩展的受控组件,一般要配置的属性均可添加进去,fontFamilies属性为字体数组。安装:# Install using yarnyarn add braft-editor# Install using npmnpm install braft-editor --save使用代码import React from "react";import { Card } f
2021-10-19 17:43:40 636 2
原创 相同域名下的不同端口的cookie可以共享
问题:在实际的项目中,经常有不同的项目部署在同一域名下,但是端口不同。但是两个项目之前需要共享cookie结果:这种情况时可以共享的,当清除其中一个cookie,另一个也会连带清除。但是两者有条件:1.使用前需要清除缓存;注:localStorage不可以共享...
2021-10-19 11:30:28 5694
原创 axios使用响应的config的data(response.config.data),data的格式为json,发送请求时,config的data会出现乱码
axios使用响应的config的data(response.config.data),data的格式为json,会出现乱码问题描述:直接使用响应的config的json格式的数据访问接口时,会出现发送的data乱码。比如以下请求function (response){ axios({ method: response.config.method, data: response.config.data, u
2021-10-18 20:05:22 2373
原创 axios自动刷新token
根据refreshToken刷新Token问题描述:axios使用token访问时,token如果失效,则需要使用refreshToken来刷新Token得到新的Token这时可以考虑在axios的响应后,对状态做处理,处理逻辑:返回响应token后显示失效——〉使用refreshToken接口,刷新token——〉对refreshToken接口的返回数据做处理——>再次访问显示失效的接口instance.interceptors.response.use( function (respo
2021-10-18 19:33:46 1503 1
EMD 模态选择问题
2017-12-20
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人