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

@hollar/hollar-global-navbar

v3.1.3

Published

Shareable global navigation menu

Downloads

28

Readme

global-navbar

For hollar-web

steps to publish:

  1. run command npm run build
  2. change version in package.json
  3. run command npm publish

For hollar

steps to publish:

  1. run command npm run build:rails
  2. copy index.js to navbar.js

Update version rules

For each task, you need to work on fixing the bug or feature, please put .alpha.ticketnumber.version and publish it.

For example, if you work on the task 12345 clubhouse ticket that requires update global-nav npm. Let say the current version of global nav is 2.0.1 Your PR will contain update version of npm is as 2.0.2.alpha.12345.1 and publish it.

If it doesn't pass QA, the next commit will be 2.0.2.alpha.12345.2 and so on...until it passes QA.

When merging to production, the version will be updated to the latest and remove suffix .alpha out.

version convention

Each number has different meaning.

version A.B.C

A = big milestone // Ex. when we launch new global nav

B = new feature // When we add new feature, we should update this number

C = fix buges

.alpha = for testing purpose. You are about 70%-80% sure that it will be bug free. If you have less than 70% sure, you should test on your local first.

.beta = normally, this is for big milestone when you want to pass it to QA for testing.

How to build the global-nav files for hollar-web and hollar 

Before you start adding changes please signup for an npmjs.com account and request access to @hollar/hollar-global-navbar (https://www.npmjs.com/package/@hollar/hollar-global-navbar). Once you begin following @hollar/hollar-global-navbar you’ll be able to push updated package version to the global-navbar

Building the global-navbar

Once you’re done making your updates to in the global-nav repo run the following commands in the CLI. The documentation can also be found here https://www.npmjs.com/package/@hollar/hollar-global-navbar under the Readme section.

  1. run command npm run build
  2. change version in package.json
  3. run command npm publish

For package naming convention please use the current package version + your story number. For example “2.4.0-ewa-1234”. Please refer to the version section on the global-nav npm page.

Installation of navbar for hollar-web

Next got to the hollar-web repo and update the version of the hollar/hollar-global-navbar in the package.json file and the run npm install in the hollar-web CLI. Once that’s done restart the hollar-web server. Refresh the page and check for your updates.

Installation for hollar (rails)

In the global-nav repo CLI run the following command run command npm run build:rails In the root folder of the global-nav directory there should be and index.js file (global-nav/index.js) 

Copy everything in that file beginning after 
 (function (React, ReactDOM, injectSheet, classnames) {   'use strict’;

To right before  ReactDOM__default.render(React__default.createElement(Navbar, null), document.querySelector('#navbar-root’));

Then go to the hollar repo and go to hollar/app/assets/javascripts/spree/frontend/navbar/navbar-template.js.erb

Around line 159 there should be a comment block. Paste your code over the entire comment block. Do not save!

Then copy all the code in navbar-template.js.erb and paste the entire code into hollar/app/assets/javascripts/spree/frontend/navbar/navbar.js.erb and save. 

Once this is done restart the rails server and go to a static page, for example /about and check for your updates.