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

tuxharness

v2.0.5

Published

Test User eXperience Harness

Downloads

31

Readme

Test User eXperience Harness

Build a stand-alone test harness with dynamic data to quickly prototype and isolate your HTML/CSS or examine your JSON document.

npm version Dependencies Status DevDependencies Status MIT Licensed

Installation steps to setup and configure

  1. npm install tuxharness --save-dev
  2. Define a recipe file -- similar to Gruntfile.js or gulpfile.js
    • Mac/Unix copy file cp -nv "node_modules/tuxharness/tuxfile.js" "tuxfile.js"
    • Windows copy file copy "node_modules/tuxharness/tuxfile.js" "tuxfile.js"
    • More example recipes starter sample tuxharness recipe or full sample
  3. Run the harness server
    • node ./node_modules/tuxharness/index.js
    • or add a script reference to your package.json like "harness": "node ./node_modules/tuxharness/index.js" then execute with npm run harness

Recipe details

Register

  • port localhost server port number (default is 4000)
  • static serve static assets (img, js, css, fonts...)
    • route is a virtual web path - served by express.js
    • directory is the physical path where the static assets are hosted
  • view
    • engines array of template view engine name as defined in npm
    • path is the physical path to the views folder - relative from your project root

Harness (array)

  • route is a virtual web path - served by express.js
  • view is the physical path where the view is hosted - relative to your view folder
  • data (object) - passed into the view for transformation
  • data (string) - service call to request JSON data
  • data (function(callback, util)) - callback argument will async call to gather data passed into the view for transformation
    • callback type string/JSON: print to browser
    • util type object
      • getIpsumText Lorum Ipsum generator
      • getJsonRoute type function(string route): wraps route name with localhost IP address with port and JSON path

Template View Engines

  1. dust.js (sample in test folder)
    • npm install dustjs-linkedin --save
  2. Jade (sample in test folder)
    • npm install jade --save
  3. Many others supported by Consolidate.js
    1. install any additional engines in your project
    2. register your view engine in your project's JS file

Commands

  • npm run harness Single run server to serve the test harness environment
  • npm run dev Respawn-on-save server to serve the test harness environment
  • npm run lint Lint JS files
  • npm test Unit test and coverage

JSON browser extentions

Roadmap

  1. Allow remote recipes
    • Views and data too
  2. Host demo