摘要: This program follows the usual GNU command line syntax, with long options starting with two dashes (`-'). A summary of options is included below. -h - 阅读全文
posted @ 2022-09-26 16:24 _Otis 阅读(104) 评论(0) 推荐(0) 编辑
摘要: 安装 npm i -D react-loadable 创建loadable.tsx文件 import React from 'react' import Loadable from 'react-loadable' import { Spin } from 'antd' import index f 阅读全文
posted @ 2021-08-02 12:21 _Otis 阅读(59) 评论(0) 推荐(0) 编辑
摘要: 在src目录中创建 setupProxy.js文件 添加如下配置 const createProxyMiddleware = require('http-proxy-middleware') module.exports = function (app) { app.use( createProxy 阅读全文
posted @ 2021-07-30 15:22 _Otis 阅读(194) 评论(0) 推荐(0) 编辑
摘要: const CracoLess = require('craco-less') const CracoAntDesign = require('craco-antd') const path = require('path') module.exports = { plugins: [ // 针对L 阅读全文
posted @ 2021-07-30 15:20 _Otis 阅读(339) 评论(0) 推荐(0) 编辑
摘要: 在.eslintrc.js的rules中添加一条规则 rules: { "no-use-before-define": 'off', "@typescript-eslint/no-use-before-define": ["error"] } 阅读全文
posted @ 2021-07-26 15:48 _Otis 阅读(2057) 评论(0) 推荐(1) 编辑
摘要: 分页 动态计算分页按钮 # coding=utf-8 import math class Page: def __init__(self, data_count, page_size=5, pre_page_num=10): """ 分页 :param data_count: 数据总量 :param 阅读全文
posted @ 2021-01-13 15:02 _Otis 阅读(44) 评论(0) 推荐(0) 编辑
摘要: 连接池 from sqlalchemy import create_engine engine = create_engine( 'mysql+pymysql://root:000000@192.168.30.161:3306/sqlalchemy_test?charset=utf8mb4', ma 阅读全文
posted @ 2020-06-07 20:59 _Otis 阅读(120) 评论(0) 推荐(0) 编辑
摘要: WTForms是一个支持多个web框架的form组件,主要用于生成HTML标签,对用户请求数据进行验证。 安装 pip install wtforms 使用 用户注册示例 from flask import Flask from flask import request from flask imp 阅读全文
posted @ 2020-06-04 17:35 _Otis 阅读(182) 评论(0) 推荐(0) 编辑
摘要: 安装 pip install DBUtils 使用 import threading import pymysql from DBUtils.PooledDB import PooledDB POOL = PooledDB( creator=pymysql, # 使用链接数据库的模块 maxconn 阅读全文
posted @ 2020-06-02 16:30 _Otis 阅读(122) 评论(0) 推荐(0) 编辑
摘要: 安装 pip install flask_session 使用 from flask import Flask from flask import session from flask_session import Session from redis import Redis app = Flas 阅读全文
posted @ 2020-06-01 13:00 _Otis 阅读(674) 评论(0) 推荐(0) 编辑