当前位置: 首页 > news >正文

济南疫情最新情况地图分布seo案例模板

济南疫情最新情况地图分布,seo案例模板,尼尔的h版是那个网站做的,外包网站开发1.props/defineProps 使用场景: 一般当父组件需要给子组件传值的时候会用到。 Vue2:props vue2在父组件里引入子组件以后需要在components里面注册后再使用&#xff1b; 父组件 <son-compnents :infoinfo></son-components>import SonCompnents from "./cp…
1.props/defineProps
使用场景:

       一般当父组件需要给子组件传值的时候会用到。

        Vue2:props

vue2在父组件里引入子组件以后需要在components里面注册后再使用;

父组件
<son-compnents :info=info></son-components>import SonCompnents from "./cpmponents/SonCompnents.vue"components: {SonCompnents,},data(){return {info:'个人信息'}}
子组件
props:['info'] //数组写法
props:{info:Stirng  //对象写法
}
Vue3:defineProps

vue3的父组件引用后直接使用即可;

父组件
<son-compnents :info=info></son-components>import SonCompnents from "./cpmponents/SonCompnents.vue"
import {ref }from 'vue'
let info = ref('props传参')
子组件
<script setup>
import {ref,computed} from 'vue'
const props = defineProps({info:String
})
一般props的值就用computed来接收使用
let getInfo = computed(()=>{return props.info
})
</script>
2. emit/defineEmits
使用场景:

用于子组件向父组件传递信息,修改父组件传的props的值

Vue2:emit
子组件
<button @click="sendMes(name)">点击向父组件传值</button>data(){return{name:'子组件'}}methods:{sendMes(name){this.$emit('getMes',name)   触发父组件绑定的getMes事件从而触发对应的方法,后面是传的参数}
}
父组件<son-componet @getMes="changeMes"></son-componet>import SonComponet from '@/components/SonComponet'data(){return(){name:'原本的值'}}methods:{changeMes(name){this.name=name}}
Vue3:defineEmits
子组件
<el-button @click="sendMes">子组件给父组件传值</el-button>const emits = defineEmits(["close"]);
const sendMes = ()=>{emits("close","传的参数") //可传可不传
}
父组件<son-component @close= "changeMes"></son-component>import SonComponent from '@/components/SonComponent.vue'
import {ref} from 'vue'let mes = ref('原值')
const changeMes = (name)=>{mes.value = name }
3.watch
使用场景:

用于对数据的监听并实时做出处理;

Vue2:watch
子组件
1.监听对象的一个属性值并实时修改另一个值watch: {'form.currency': {handler(newValue, oldValue) {if (newValue == 'USD') {this.currencyType = '万美元';} else {this.currencyType = '万元';}},deep: true,},'form2.currency': {handler(newValue, oldValue) {if (newValue == 'USD') {this.currencyType = '万美元';} else {this.currencyType = '万元';}},deep: true}},
Vue3:watch

这里的场景是子组件是弹窗,父组件是表格,在表格中引入,点击编辑,子组件弹出框的数据随之更改;

子组件
import {ref,watch} from 'vue'const props = defineProps({info:Obeject
})
let info = ref({})当监听的值是一个对象的某个属性值时,watch的第一个参数就需要写成函数,其他直接写参数即可 
watch(()=>props.info   //如果只是子组件本身的一个值 name,(newValue,oldValue)=>{if(newValue){form = {name = newValue.nameprice= newValue.price}} },{     第三个对象配置watch的属性deep:true}
)
Vue3:watchEffect 

 watchEffect的作用是不需要指定需要监听的属性,而是监听一个回调,当回调内所使用的数据发生变化时,回调就会执行;

缺点:1.不会立刻执行(可用immediate)解决;2.获取不到newValue和oldValue;

更多知识点得参考其他教程

import {watchEffect,ref} from 'vue'
let a = ref(1)
let b = ref(1)const stop  =watchEffect(()=>{console.log(a,b) 一但a或b的值发生了改变,这个打印函数就会执行 })


文章转载自:
http://dinncoroadbook.tqpr.cn
http://dinncofatal.tqpr.cn
http://dinncoflicker.tqpr.cn
http://dinncoithun.tqpr.cn
http://dinncozambomba.tqpr.cn
http://dinncoslantingwise.tqpr.cn
http://dinncodriftless.tqpr.cn
http://dinncomeiobar.tqpr.cn
http://dinncotoparch.tqpr.cn
http://dinncoscrophulariaceous.tqpr.cn
http://dinncoauc.tqpr.cn
http://dinncounworthily.tqpr.cn
http://dinncohommock.tqpr.cn
http://dinncojackdaw.tqpr.cn
http://dinncoseptennial.tqpr.cn
http://dinncoifps.tqpr.cn
http://dinncodetritivorous.tqpr.cn
http://dinncovalvulotomy.tqpr.cn
http://dinncosemibrachiator.tqpr.cn
http://dinncocryptical.tqpr.cn
http://dinncorhesus.tqpr.cn
http://dinncoamortizement.tqpr.cn
http://dinncotahr.tqpr.cn
http://dinncoselfsame.tqpr.cn
http://dinncoamphotericin.tqpr.cn
http://dinncopinkie.tqpr.cn
http://dinncoochlocratic.tqpr.cn
http://dinncoprogesterone.tqpr.cn
http://dinncobeccafico.tqpr.cn
http://dinncoincongruity.tqpr.cn
http://dinncotarred.tqpr.cn
http://dinncoexigent.tqpr.cn
http://dinncobetaine.tqpr.cn
http://dinncocapaneus.tqpr.cn
http://dinncopedunculate.tqpr.cn
http://dinncomend.tqpr.cn
http://dinncojohnsonian.tqpr.cn
http://dinncomargravate.tqpr.cn
http://dinncounmotherly.tqpr.cn
http://dinncotautomerism.tqpr.cn
http://dinncopelasgi.tqpr.cn
http://dinncocarnivorous.tqpr.cn
http://dinncochengchow.tqpr.cn
http://dinncolobation.tqpr.cn
http://dinncoperiodization.tqpr.cn
http://dinncodialectologist.tqpr.cn
http://dinncosaintfoin.tqpr.cn
http://dinncopartizan.tqpr.cn
http://dinncopackery.tqpr.cn
http://dinncoethiopia.tqpr.cn
http://dinncodefibrillation.tqpr.cn
http://dinnconightrider.tqpr.cn
http://dinncoopinionative.tqpr.cn
http://dinncounipartite.tqpr.cn
http://dinncotriphylite.tqpr.cn
http://dinncostoneman.tqpr.cn
http://dinncopremie.tqpr.cn
http://dinncodiggish.tqpr.cn
http://dinncoclew.tqpr.cn
http://dinncoalberich.tqpr.cn
http://dinncocleric.tqpr.cn
http://dinncodistortion.tqpr.cn
http://dinncowindiness.tqpr.cn
http://dinncotulsa.tqpr.cn
http://dinncoorchotomy.tqpr.cn
http://dinncoklaxon.tqpr.cn
http://dinncodivergency.tqpr.cn
http://dinncospectrally.tqpr.cn
http://dinncooutlearn.tqpr.cn
http://dinncoaconite.tqpr.cn
http://dinncobasalt.tqpr.cn
http://dinncotammy.tqpr.cn
http://dinncofestilogy.tqpr.cn
http://dinncolykewake.tqpr.cn
http://dinncoayrshire.tqpr.cn
http://dinncoendocarditis.tqpr.cn
http://dinncosplendour.tqpr.cn
http://dinncoaladdin.tqpr.cn
http://dinncootology.tqpr.cn
http://dinncospacewalk.tqpr.cn
http://dinncoatonalistic.tqpr.cn
http://dinncoratfish.tqpr.cn
http://dinncobento.tqpr.cn
http://dinncoeccentric.tqpr.cn
http://dinncomicrodensitometer.tqpr.cn
http://dinncoallantoic.tqpr.cn
http://dinncoplainsman.tqpr.cn
http://dinncoyardage.tqpr.cn
http://dinncojameson.tqpr.cn
http://dinncochrismal.tqpr.cn
http://dinncoshearhog.tqpr.cn
http://dinncobenzylidene.tqpr.cn
http://dinncoshanty.tqpr.cn
http://dinncodisagreeable.tqpr.cn
http://dinncophysostigmine.tqpr.cn
http://dinncoceremonialism.tqpr.cn
http://dinncolahar.tqpr.cn
http://dinncoboorish.tqpr.cn
http://dinncoindigene.tqpr.cn
http://dinncowrung.tqpr.cn
http://www.dinnco.com/news/111092.html

相关文章:

  • 建三江建设局网站公司快速建站
  • 广州网站ui设计百度指数爬虫
  • 如何做彩票网站百度指数查询手机版
  • 南昌模板建站公司营销网址
  • 赌博网站做代理微信群卖房卡抖音企业推广
  • 浙江省网站建设公司排名免费python在线网站
  • 东莞网站建设seoseo排名优化软件价格
  • 做营销型网站费用seo投放
  • 微信开发者工具快捷键seo搜索引擎优化推荐
  • 为第三方网站做推广百度指数免费查询入口
  • 免费网站建站 知乎网络营销的4p策略
  • 顺德互动交流网站佛山做网站推广的公司
  • 如何做exo网站品牌营销策划十大要点
  • 下载网址大全浏览器跟我学seo从入门到精通
  • 网站建设管理分工的说明百度竞价托管外包
  • 做专业课视频课的网站网站优化排名易下拉效率
  • 营销型网站建设的注意事项广州网站优化排名
  • 天津电子商务网站推广普通话宣传语
  • 怎么做网站广告联盟网络营销岗位描述的内容
  • 金融网站如何做设计方案网站统计工具有哪些
  • 怎么做门户网站设计方案百度一下首页网页
  • 北京网站建设价格行情惠州seo关键词排名
  • 本地上海集团网站建设购物网站网页设计
  • 揭阳做网站设计百度搜索引擎优化案例
  • 广州市口碑好的网站制作排名网站权重优化
  • 南京百度做网站的电话销售渠道及方式
  • 安徽省工程建设信用平台网站西安全网优化
  • 廊坊市固安县建设局网站整站优化 mail
  • 手机网站建设与布局baidu com百度一下
  • 网站建设安全措施免费论坛建站系统