const http=require('http') const fs=require('fs') const path=require('path') const server=http.createServer(function(req,res){ const {url}=req console ...
分类:
Web程序 时间:
2021-05-04 15:44:00
阅读次数:
0
import axios from "axios"; import { getOssTicket } from "@/pages/mb/constants/API"; // 拿到ticket const getTicket = function (): any { return new Promis ...
分类:
Web程序 时间:
2021-05-04 15:31:21
阅读次数:
0
一、原生字符串(raw string literals) 比如我们写硬盘上一个文件的访问路径:"C:\Program Files\Microsoft.NET\ADOMD.NET",你需要把它写成以下格式 string path = "C:\\Program Files\\Microsoft.NET\ ...
分类:
编程语言 时间:
2021-05-03 12:40:02
阅读次数:
0
1、安装 npm install postcss-plugin-px2rem --save-dev 2、引入配置 // vue.config.js const px2rem = require("postcss-plugin-px2rem"); module.exports = { css: { l ...
分类:
其他好文 时间:
2021-04-30 12:39:06
阅读次数:
0
定时获取远程文件并存储更新记录 这类似一个备份功能, 只会保存更新, 比如后端的接口文档经常变, 然后可以用此工具来保存更新记录. new Promise(async () => { setInterval(() => { // const fileUrl = `http://172.16.203. ...
分类:
其他好文 时间:
2021-04-30 12:21:26
阅读次数:
0
链判断运算符 ES2020 引入了“链判断运算符”(optional chainingoperator) ?. 1. const firstName = message?.body?.user?.firstName || 'default'; 2. const fooValue = myForm.q ...
分类:
其他好文 时间:
2021-04-28 12:22:32
阅读次数:
0
添加一个类继承JsonResult public class CustomJsonResult : JsonResult { private const string _dateFormat = "yyyy-MM-dd HH:mm:ss"; public CustomJsonResult() { s ...
分类:
Web程序 时间:
2021-04-28 12:07:11
阅读次数:
0
unique(arr) { const res = new Map(); return arr.filter( (arr) => !res.has(arr.strat_id) && res.set(arr.strat_id, 1) ); }, ...
分类:
编程语言 时间:
2021-04-28 12:04:33
阅读次数:
0
【题意】 求最长回文子串 【分析】 把原字符串翻过来接到后面,中间放一个特殊字符 然后枚举每一个点作为回文串的中心,计算当前位置的后缀和对应的延长位置上的后缀的最长公共前缀 具体的:分类讨论如果i为奇数长度的中心lcp(i,n-i-1),i为偶数长度回文串的中心的一个lcp(i,n-i) 【代码】 ...
分类:
其他好文 时间:
2021-04-28 12:01:17
阅读次数:
0
题目 Atcoder 思路 代码 #include <iostream> #include <cstring> #include <algorithm> #include <queue> using namespace std; const int N = 500010, INF = 1e9; in ...
分类:
其他好文 时间:
2021-04-28 11:51:48
阅读次数:
0