# VUE

# VUE

0篇文章
js实现全屏 <a-button type="primary" @click="screen">全屏</a-button> data() { return ...
  • Vue
  • 2023-03-06
使用provice和inject结合的方法。此方法着实有效,不会有闪烁的空白出现。如下: 首先在App.vue组件里声明这个方法,写法如下: <template> &l...
  • Vue
  • 2023-03-06
//完整url可以用 window.location.href //路由路径可以用 this.$route.path //路由路径参数 this.$route.params
  • Vue
  • 2023-03-06
重定向也是通过 routes 配置来完成,下面例子是从 /a 重定向到 /b: const router = new VueRouter({ routes: [ { path: '...
  • Vue
  • 2023-03-06
@click="click" 单击 @mousedown="down" 按下 @mouseup="up" 抬起 @dblclick="dblclick" 双击 @mousemove...
  • Vue
  • 2023-03-06
this.$nextTick这个方法作用是当数据被修改后使用这个方法会回调获取更新后的dom再渲染出来 <div ref="tar">{{ content }}<...
  • Vue
  • 2023-03-06
安装 //安装nuxt脚手架 yarn add -D create-nuxt-app //创建一个名字为project的项目 npx create-nuxt-app project...
  • Vue
  • 2023-03-06
根目录 vue.config.js 文件,没有则新建 module.exports = { devServer: { open: true } }
  • Vue
  • 2023-03-06
大家在项目开发的时候,需要看看一些后端接口返回的结果,会多次使用 console.log 项目开发完成打包的时候,发现控制台一堆的 console.log ,非常头疼,下面给大家推...
  • Vue
  • 2023-03-06
前言:根据最近做的一个医疗手机端项目总结在移动端,vue怎么在不同屏幕上做根据不同屏幕大小适配 1.适配方案 在本项目中我所使用的vue移动方案是使用amfe-flexible 和...
  • Vue
  • 2023-03-06
根目录创建:vue.config.js module.exports = { lintOnSave: false, }
  • Vue
  • 2023-03-06
解决跨域: 1.根目录新建vue.config.js文件 module.exports = { devServer: { open: true, proxy: { '/api': ...
  • Vue
  • 2023-03-06
方法一 <!DOCTYPE html> <html> <head> <meta charset="utf-8" /> <met...
  • Vue
  • 2023-03-06
‘Content-Type’: ‘application/json’ 请求 将数据转为 key=value 的形式 import qs from 'qs' http({ metho...
  • Vue
  • 2023-03-06
二级路由配置path时前面不能有 " / " 在一级路径信息数组中添加一个children配置项: {path:'/hot',component:()=>import('@/...
  • Vue
  • 2023-03-06
vuex import Vue from 'vue' import Vuex from 'vuex' Vue.use(Vuex) export default new Vuex.S...
  • Vue
  • 2023-03-06
监听单个数据 vuex数据 import Vue from 'vue' import Vuex from 'vuex' Vue.use(Vuex) export default n...
  • Vue
  • 2023-03-06

关注我们的公众号

微信公众号