qian奇岸微信二维码 如您需要快速报价 请加技术经理微信 服务热线
13501992972
"MENU"
首页 > 开发知识 > 正文

组装vuei18n依赖,npm install wowjs

奇岸开发
ahqian.com
11/19/2022
wechat

无需加好友免费技术支持

前几日用vue相互配合wow为顾客制做双语教学宣传单页缓存动漫网页页面……

1、组装wow.js依赖,

npm install wowjs --save;

2、在main.js在文件中引入动漫css,

import "";

3、在入口app.vue文件中引用。

import WOW from "wow.js" ;

mounted() {

const wow = new WOW({

boxClass: "wow", // animated element css class (default is wow)

animateClass: "animated", // animation css class (default is animated)

offset: 0, // distance to the element when triggering the animation (default is 0)

mobile: true, // trigger animations on mobile devices (default is true)

live: true, // act on asynchronously loaded content (default is true)

scrollContainer: null, // optional scroll container selector, otherwise use window,

resetAnimation: true, // reset animation on end (default is true)

});

wow.init();

},

4.应用编码:

具体内容

1、组装vuei18n依赖,

npm install vue-i18n@next

2、新建lang文件夹在里面新创建ch.js,en.js,index.js配备中英内容与入口文件index文件;

3、在main.js文件中引用,

import VueI18n from ""

3.在页面上应用

import { useI18n } from "vue-i18n";

{{ $t("baige.top.year") }}

热度369

了解更多组装vuei18n依赖,npm install wowjs 欢迎联系奇岸开发客服。

奇岸开发可定制企业官网小程序、小程序商城、餐饮外卖小程序、预约小程序、多门店小程序、分销小程序及个人小程序。

微信二维码

微信长按识别或扫一扫,无需加好友直接咨询,企业网站开发、网站托管维护、企业管理系统开发、微信小程序制作、域名主机、网站备案、网站改版等提供专业技术解答。

精彩推荐

猜你喜欢