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

navigationbar-wx

v1.0.12

Published

### 1、安装插件,并在小程序开发工具中构建 npm

Downloads

0

Readme

微信原生小程序导航栏 navigation-bar 使用说明

1、安装插件,并在小程序开发工具中构建 npm

npm i navigationbar-wx

2、app.js 中得 globalData 内写上如下:

import { navigationbarWx } from "navigationbar-wx/config.js";
navigationbarWx.init({
  title: "小程序默认名称",
  homePath: "/pages/index/index",//默认路径,如果相同可以忽略这个参数
})
//备注:init 可初始化的字段如下字段说明

3、app.json 中配置插件

"usingComponents": {
    "navigationbar-wx": "navigationbar-wx"
  }

4、页面使用-传参如下说明

<!-- 可直接使用 -->
<navigationbar-wx />
<!-- 也可传参使用 -->
<navigationbar-wx
title=""
logo=""
color=""
bgColor=""
bgImg=""
iconColor=""
hideHome=""
hideSeat=""
 />

字段说明

| 字段 | 必传 | 类型 | 默认值 | 说明 | | --------- | ---- | ------- | ------------------ | ------------------------------------------------- | | title | 否 | String | 小程序默认标题 | 当前页面标题 | | logo | 否 | String | 无 | 可传入一个图片 URL 作为标题,logo 优先级大于 title | | color | 否 | String | #000000 | 字体颜色,默认黑色 | | bgColor | 否 | String | #ffffff | 导航栏颜色,默认白色 | | bgImg | 否 | String | 无 | 导航栏整体图片,背景图优先级大于背景颜色 | | iconColor | 否 | String | black | 左边按钮颜色,只支持 black、white 两种类型 | | hideHome | 否 | Boolean | false | 当没有上一级页面时,是否隐藏小房子 | | hideSeat | 否 | Boolean | false | 导航栏底部占位,默认占位不隐藏 | | homePath | 否 | String | /pages/index/index | 页面如果设置这个参数优先级高于 init 时传入的路径 |

github 地址

github 地址