1 Star 10 Fork 8

孔乙己拉夫米 / react-ant-admin-server

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README
MIT

react-ant-admin 后台项目

本项目使用express快速搭载项目。

使用前,请安装nodejs环境,mysql 数据库环境git 代码管理工具

安装

  • 在系统盘下打开 dos 窗口(cmd),运行以下命令拉取文件。
D:>git clone https://gitee.com/kong_yiji_and_lavmi/react-ant-admin-server.git
  • 安装项目依赖
D:\react-ant-admin-server>cnpm i # or yarn install  / npm i
  • 修改自己定义的配置

token的secret 加密字符串

// ${root}/common/jwt.js
const secret = "your secret";

项目启动地址,端口

// ${root}/common/index.js
module.exports = {
  host: "0.0.0.0",
  port: 8081,
};

数据库地址,用户名,密码,数据库名

// ${root}/common/mysql.js
const pool = mysql.createPool({
  host: "127.0.0.1", // 本地
  user: "root",
  password: "your password",
  database: "react_admin", // 数据库名
  port: "3306",
  multipleStatements: true, // 允许同时执行多条sql语句
});
  • 创建一个数据库名为react_admin,编码使用utf8,编码排序使用utf8_general_ci

在根目录下有一个react_admin.sqlsql 备份文件。导入刚刚创建的数据库即可。

不太了解数据库的朋友在这里推荐使用navicat来导入数据库。

启动

完成了以上操作之后,即可开始启动项目。

D:\react-ant-admin-server>npm run start

此时出现一下语句即代表成功!

  server is starting:
    http://监听地址:端口号

接口文档地址

如有问题欢迎骚扰~ qq 交流群:564048130

qrcode

MIT License Copyright (c) 2021 孔乙己拉夫米 Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

简介

react-ant-admin后台web服务,使用nodejs创建 展开 收起
JavaScript 等 2 种语言
MIT
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
1
https://gitee.com/kong_yiji_and_lavmi/react-ant-admin-server.git
git@gitee.com:kong_yiji_and_lavmi/react-ant-admin-server.git
kong_yiji_and_lavmi
react-ant-admin-server
react-ant-admin-server
master

搜索帮助