Vue+Vux实现登录功能
作者:奔跑吧邓邓子 时间:2024-04-30 10:39:45
一、准备工作
请参照 Vue前端框架搭建 使用模板创建框架。
二、创建登录页
1.main.js 中引入全局 ToastPlugin、LoadingPlugin 插件
import { ToastPlugin, LoadingPlugin } from 'vux'
Vue.use(ToastPlugin)
Vue.use(LoadingPlugin)
2.views 下创建 login\login.vue
import Vue from 'vue'
import Router from 'vue-router'
import HelloWorld from '@/components/HelloWorld'
import Test from '@/views/test'
Vue.use(Router)
export default new Router({
routes: [
{
path: '/',
name: 'HelloWorld',
component: HelloWorld
},
{
path: '/test',
name: 'test',
component: Test
}
]
})
3.运行
浏览器输入 http://localhost:8080/#/login:
点击【登录】:
来源:https://blog.csdn.net/u012069313/article/details/126526273
标签:Vue,Vux,登录
![](/images/zang.png)
![](/images/jiucuo.png)
猜你喜欢
Python类的定义和使用详情
2021-03-10 18:10:59
![](https://img.aspxhome.com/file/2023/5/118735_0s.png)
忆童年!用Python实现愤怒的小鸟游戏
2023-06-03 11:01:12
![](https://img.aspxhome.com/file/2023/4/90714_0s.png)
聊聊Pytorch torch.cat与torch.stack的区别
2021-05-07 02:07:39
![](https://img.aspxhome.com/file/2023/2/127812_0s.jpg)
6个Python办公黑科技,助你提升工作效率
2022-11-15 14:31:21
![](https://img.aspxhome.com/file/2023/8/68438_0s.png)
自动在Windows中运行Python脚本并定时触发功能实现
2023-04-15 21:12:38
![](https://img.aspxhome.com/file/2023/6/76926_0s.png)
MySQL Server层四个日志的实现
2024-01-21 11:16:58
![](https://img.aspxhome.com/file/2023/8/117838_0s.jpg)
好用的VSCode头部注释插件Fileheader Pro
2023-07-05 06:16:00
Google首页的CSS Sprite
2007-09-29 21:36:00
![](https://img.aspxhome.com/file/UploadPic/20079/29/2007929213924854s.png)
详解用Python爬虫获取百度企业信用中企业基本信息
2022-07-27 18:49:52
![](https://img.aspxhome.com/file/2023/6/65416_0s.jpg)
Python3爬虫爬取英雄联盟高清桌面壁纸功能示例【基于Scrapy框架】
2023-03-07 19:19:59
![](https://img.aspxhome.com/file/2023/4/83934_0s.png)
Mysql中使用时间查询的详细图文教程
2024-01-17 16:35:54
![](https://img.aspxhome.com/file/2023/0/77210_0s.png)
基于python实现查询ip地址来源
2021-02-10 14:45:52
![](https://img.aspxhome.com/file/2023/9/95499_0s.png)
用Python给文本创立向量空间模型的教程
2021-07-13 17:06:41
Mootools 1.2教程(21)——类(二)
2008-12-28 20:58:00
Python+Selenium使用Page Object实现页面自动化测试
2022-09-30 06:09:57
python print出共轭复数的方法详解
2021-11-15 20:37:57
Python写的Tkinter程序屏幕居中方法
2022-08-03 17:53:07
Python 实现3种回归模型(Linear Regression,Lasso,Ridge)的示例
2021-06-17 20:46:53
![](https://img.aspxhome.com/file/2023/5/117955_0s.jpg)
Python 读取某个目录下所有的文件实例
2022-08-27 20:04:13
python模块引入问题和解决方案
2023-06-05 11:05:52
![](https://img.aspxhome.com/file/2023/2/135362_0s.png)