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

aurelia-skeleton-navigation

v1.1.4

Published

A starter kit for building a standard navigation-style app with Aurelia.

Downloads

9

Readme

aurelia-skeleton-navigation

Running The App

To run the app, follow these steps.

  1. Ensure that NodeJS is installed. This provides the platform on which the build tooling runs.
  2. From the project folder, execute the following command:
npm install
  1. Ensure that Gulp is installed globally. If you need to install it, use the following command:
npm install -g gulp

Note: Gulp must be installed globally, but a local version will also be installed to ensure a compatible version is used for the project.

  1. Ensure that jspm is installed globally. If you need to install it, use the following command:
npm install -g jspm

Note: jspm must be installed globally, but a local version will also be installed to ensure a compatible version is used for the project.

Note: jspm queries GitHub to install semver packages, but GitHub has a rate limit on anonymous API requests. It is advised that you configure jspm with your GitHub credentials in order to avoid problems. You can do this by executing jspm registry config github and following the prompts. If you choose to authorize jspm by an access token instead of giving your password (see GitHub Settings > Personal Access Tokens), public_repo access for the token is required.

  1. Install the client-side dependencies with jspm:
jspm install -y

Note: Windows users, if you experience an error of "unknown command unzip" you can solve this problem by doing npm install -g unzip and then re-running jspm install.

  1. To run the app, execute the following command:
gulp watch
  1. Browse to http://localhost:9000 to see the app. You can make changes in the code found under src and the browser should auto-refresh itself as you save files.

The Skeleton App uses BrowserSync for automated page refreshes on code/markup changes concurrently across multiple browsers. If you prefer to disable the mirroring feature set the ghostMode option to false

Running The App under Electron

Note:

The first five steps below are identical to the first five steps for running this app the "standard' way, using the jspm / systemjs tooling. The difference is in the command to run the app, where the standard gulp watch command is replaced by the sequence of two commands:

gulp build
electron index.js

To run the app under Electron, follow these steps.

  1. Install Electron
npm install electron --save-dev
  1. From the project folder, execute the following command:
npm install
  1. Ensure that Gulp is installed globally. If you need to install it, use the following command:
npm install -g gulp

Note: Gulp must be installed globally, but a local version will also be installed to ensure a compatible version is used for the project.

  1. Ensure that jspm is installed globally. If you need to install it, use the following command:
npm install -g jspm

Note: jspm must be installed globally, but a local version will also be installed to ensure a compatible version is used for the project.

Note: jspm queries GitHub to install semver packages, but GitHub has a rate limit on anonymous API requests. It is advised that you configure jspm with your GitHub credentials in order to avoid problems. You can do this by executing jspm registry config github and following the prompts. If you choose to authorize jspm by an access token instead of giving your password (see GitHub Settings > Personal Access Tokens), public_repo access for the token is required.

  1. Install the client-side dependencies with jspm:
jspm install -y

Note: Windows users, if you experience an error of "unknown command unzip" you can solve this problem by doing npm install -g unzip and then re-running jspm install.

  1. To build the app execute the following command (this will give you a dist directory)
   gulp build
  1. To start the app, execute the following command:
electron index.js

Note: If typing the command electron index.js is too much for you change this line in package.json from "main": "dist/main.js", to "main": "index.js", Then, you can invoke electron by just typing

  electron .

Packaging The App Using Electron-Packager

Note: The electron-packager package relies on "main" in package.json to know which JS file to use to start the application. To make this work with electron-packager change this line in package.json from "main": "dist/main.js", to "main": "index.js",

  1. Follow steps 1-6 in the previous section (Running The App under Electron).

  2. Install electron-packager

npm install electron-packager -g
  1. Run the command:
electron-packager <sourcedir> <appname> --platform=<platform> --arch=<arch> --version <electron version #> [optional flags...]

Include the --asar option to create an asar archive from your app.

By default, electron-packager will place the packaged app in a folder under the source folder with the naming convention of <appname>-<platform>-<arch>.

See the electron-packager readme for more details on options.

Bundling

Bundling is performed by Aurelia Bundler. A gulp task is already configured for that. Use the following command to bundle the app:

  gulp bundle

You can also unbundle using the command bellow:

  gulp unbundle

To start the bundled app, execute the following command:

  gulp serve-bundle

Configuration

The configuration is done by bundles.js file.

Optional

Under options of dist/aurelia add rev: true to add bundle file revision/version.

Running The Unit Tests

To run the unit tests, first ensure that you have followed the steps above in order to install all dependencies and successfully build the library. Once you have done that, proceed with these additional steps:

  1. Ensure that the Karma CLI is installed. If you need to install it, use the following command:
npm install -g karma-cli
  1. Install Aurelia libs for test visibility:
jspm install aurelia-framework
jspm install aurelia-http-client
jspm install aurelia-router
  1. You can now run the tests with this command:
karma start

Running The E2E Tests

Integration tests are performed with Protractor.

  1. Place your E2E-Tests into the folder test/e2e/src
  2. Install the necessary webdriver
gulp webdriver-update
  1. Configure the path to the webdriver by opening the file protractor.conf.js and adjusting the seleniumServerJar property. Typically its only needed to adjust the version number.

  2. Make sure your app runs and is accessible

gulp watch
  1. In another console run the E2E-Tests
gulp e2e

Exporting bundled production version

A gulp task is already configured for that. Use the following command to export the app:

  gulp export

The app will be exported into export directory preserving the directory structure.

To start the exported app, execute the following command:

  gulp serve-export

Configuration

The configuration is done by bundles.js file. In addition, export.js file is available for including individual files.