npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

vue-better-router-transition

v0.0.3

Published

vue-仿微信页面左右切换动画效果,页面刷新不影响,滑动切换页面

Downloads

14

Readme

vue-better-router-transition

vue-仿微信页面左右切换动画效果,页面刷新不影响,滑动切换页面

简介

移动端页面之间的转场动画,仿微信转场动画,支持浏览器刷新无影响,并且可定制滑动切换

安装下载

  • 下载地址
  • npm i vue-better-router-transition
  • CDN https://unpkg.com/vue-better-router-transition

快速使用

  1. npm i vue-better-router-transition
  2. main.js
    import VueBetterRouterTransition from '@/components/vue-better-router-transition' VueBetterRouterTransition.noSetPage(['/', 'userCenter']) // 设置初始页面,将来转换场景将从这页开始(此页面,初始不设置session) Vue.use(VueBetterRouterTransition)
  3. app.vue文件里
    默认为缓存可以配置
    在router/index.js 中 配置元字段
    meta: { keepAlive: false //不缓存 }
  4. 在layout/index.vue里面配置
 path: '/',
  component: index,
  redirect: '/home',
  children: [{
    path: '/home',
    component: r => require(['@/pages/home'], r),
    meta: {
      title: 'home1'
    }
  }
  首页path: '/home' 必须是home
  <router-layout id="__index">
        <router-view></router-view>
        <van-tabbar slot="footer" :fixed="false" v-model="active">
          <van-tabbar-item to="/" icon="shop">标签</van-tabbar-item>
          <van-tabbar-item to="/tab" icon="chat">标签</van-tabbar-item>
          <van-tabbar-item to="/swipe" icon="records">标签</van-tabbar-item>
        </van-tabbar>
      </router-layout>
  1. 在app.vue里
    <vue-better-router-transition :keepAlive="true"></vue-better-router-transition>

router-layout 为插件自带的全局组件, 为vant插件,可以替换其他插件
使用例子
顶部导航栏使用例子
滑动切换的例子

也可以全局使用

交流 & 提问

https://github.com/websmallrabbit/vue-better-router-transition/issues

关于作者

  • 个人主页 https://websmallrabbit.github.io

- 技术公众号: 程序员蜗牛 (关注有学习资料送)

  • 收款二维码
    我想可以请喝杯咖啡嘛ヾ(≧O≦)〃嗷~