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

generator-enigma

v5.3.0

Published

Generate a React application with best practice enforcement, integrated testing, and more.

Downloads

25

Readme

generator-enigma

A React webapp scaffolding tool with best practice enforcement, automated testing, and more.


  1. Installation
  2. Usage
  3. Testing

Scaffolding for automation of basic tooling and tasks typically required by React projects, including:

  • CommonJS module bundling via Browserify
  • ES2015+ (ES6+) syntax support and transpilation via Babel
  • Code quality assessment & style enforcement via ESLint
  • Stylus CSS preprocessing & automatic vendor prefix management via Autoprefixer
  • Unit testing via the Jest framework and Jasmine2 test runner

Installation

npm i -g generator-enigma

The build script will automatically try to install Yeoman for you if it isn't installed already. Alternatively, you can do this yourself via

npm i -g yo

back to top


Usage

To set up a new app, create a folder, enter it and run yo enigma

The generator will ask a few questions and insert the prebuilt skeleton for a typical React-based webapp. Then you're rolling!

Once you've set up your app, check out the targets available in package.json. The conveniences available at npm run <target>:

  • build: Compiles your application JS (with sourcemapping -- good for debugging) to public/assets/bundle.js and style files (with sourcemapping) to public/assets/style.css

  • release: Compiles and minifies your application JS (without sourcemapping) to public/assets/bundle.min.js and style files (without sourcemapping) to public/assets/style.min.css - the intent is you should be able to copy the contents of public/ to a server and have it work without modification

  • start: Compiles your app and boots up a livereload server -- just make changes to your files (JS, Stylus/CSS, etc.)

  • test: Runs your unit tests. (will automatically include any file inside of folders named __tests__)

  • coverage: Runs your unit tests and creates an LCOV coverage report in the /coverage directory

  • lint: Checks your project for JS code style, according to the rules in .eslintrc

back to top


Testing

The Jasmine 2 test runner is included by default, as a part of the Jest unit testing framework.

Jest supports a broad spectrum of matchers and test-writing styles, so check out their documentation to customize things to your liking!

back to top


This module adheres to Semantic Versioning.