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 🙏

© 2025 – Pkg Stats / Ryan Hefner

@blox/utils

v0.7.0

Published

Utilities for working with Angular projects

Readme

Our collected utilities for working with Single Page Applications

This package contains utilities created by The Source Zone, for working with Single Page Web Applications (e.g. apps created with Angular, Vue, or React):

  • transpile: transpile bundled javascript sources for compatibility with different javascript flavours.
  • prerender: prerender pages of SPA web applications for better SEO and/or improving render performance.

transpile

If you want to build an Angular application for es5, Angular CLI has the inconvenient limitation that you can't import Javascript sources that use es2015 (or newer) syntax.

This utility makes it possible to create es5 compatible Angular applications, even when you import third-party javascript code that uses es2015 (or newer) syntax.

The transpile script works with Angular CLI 6 or later. So to get started, install the latest Angular CLI for your project, and install this utility:

npm install --save-dev @angular/cli @blox/utils

Next in your package.json add/change the following scripts:

  "scripts": {
    ...
    "transpile": "transpile --dir dist/PROJECT-NAME --verbose",
    "build": "ng build --prod && npm run transpile",
    ...
  },

What you just did:

  • To create a build that is compatible with older browsers that don't support es2015 yet, we added a step to the build to transform the generated es2015 scripts to es5, and change the includes in the index.html to use those transpiled sources instead.

From now on, don't forget to use the npm goals npm run start and npm run build, instead of calling ng serve and ng build for starting or building your app.

options

| Option | Default | Description | | ------------------------ | -------------------- | ------------------------------- | | --dir PATH | | Specify the distribution directory to process | | --verbose | false | Add extra output and show uglify warnings while processing files | | --keepOriginalScripts | false | Keep the original es2015 bundles, don't delete them after the transformation | | --browsers | | Specify the browsers for which to transform the javascript sources. May result in smaller javascript bundles, when those browsers support parts of es2015 already. See http://browserl.ist/ for valid values and their meaning. You can also specify the browsers via config files, environment variables, or via a browserslist option in your package.json, see config browserslist. Set this option to ignore to ignore all browserlist configuration and create javascript that is compatible with the largest set of browsers. |

Quick Links