摘要:
注意:在src下创建setupproxy.js文件 const proxy = require('http-proxy-middleware') module.exports = function(app) { app.use( proxy('/api1', { //api1是需要转发的请求(所有带 阅读全文
posted @ 2021-06-19 22:05
千里码!
阅读(13)
评论(0)
推荐(0)
摘要:
import axios from "axios" import qs from 'qs' //响应时间 axios.defaults.timeout = 6000; //配置请求头 axios.defaults.headers.post['Content-Type'] = 'application 阅读全文
posted @ 2021-06-19 21:36
千里码!
阅读(11)
评论(0)
推荐(0)
摘要:
// 聊聊 浏览器使用 fetch(promise风格) 发送请求 /** * 网络请求: * xhr: * ajax(xhr封装) * axios(promise风格) * * xhr:请求分为 3个阶段 * 1、发送请求 * 2、请求成功或失败 * 3、成功则接收数据,失败则返回失败原因 * * 阅读全文
posted @ 2021-06-19 21:22
千里码!
阅读(36)
评论(0)
推荐(0)
摘要:
/** * * 各个排序算法的封装 * * * */ function ArrayList(){ this.array = []; ArrayList.prototype.insert = function (num){ this.array.push(num); } ArrayList.proto 阅读全文
posted @ 2021-06-19 20:56
千里码!
阅读(15)
评论(0)
推荐(0)
摘要:
直接干代码 /** * * 二叉搜索树封装 * * */ function BinarySearchTree(){ this.root = null; function Node(key){ this.key = key; this.left = null; this.right = null; } 阅读全文
posted @ 2021-06-19 20:47
千里码!
阅读(16)
评论(0)
推荐(0)
摘要:
图示 直接干代码 <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title></title> <style type="text/css"> *{ margin: 0; padding: 0; } body{ overflow: hidd 阅读全文
posted @ 2021-06-19 20:22
千里码!
阅读(14)
评论(0)
推荐(0)
摘要:
效果图 直接干代码 <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>钟表</title> <style type="text/css"> body{ width: 100vw; height: 100vh; overflow: 阅读全文
posted @ 2021-06-19 11:20
千里码!
阅读(12)
评论(0)
推荐(0)
浙公网安备 33010602011771号