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

electrode-bolt

v1.0.12

Published

Opinionated meta config runner for react components

Downloads

62

Readme

bolt

An opinionated meta config runner for react components, doing the heavy lifting so you don't have to.

Provides CLI access to things such as:

  • webpack
  • eslint
  • karma

through bolt.

Install

within an electrode package, run:

$ npm install electrode-bolt --save
  1. in your package.json, replace existing scripts with bolt <task> where the task is the name of the task being replaced. For instance: "cov-frontend": "istanbul check-coverage 'coverage/client/*/coverage.json'" would be replaced with "cov-frontend": "bolt cov-frontend".
  2. Enjoy seamless integration with pre-existing configs for your opininated electrode component!

Run bolt within your package to see the scripts that are available to you.

Usage

Once you've followed the steps above, you should be able to not worry about using it. bolt does the work for you.

Unique Configuration

So you don't want to the bolt command out of the box? No problem!

You can override a command in your package.json and run bolt <cmd> and bolt will opt for your script over the script it provides.

For example, say you run:

$ bolt clean-dist

bolt will run rimraf on your dist directory. If you wanted it to do something else such as echo "I love electricity!", you can put the following script in your scripts object:

"scripts": {
  "clean-dist": "echo 'I love electricity!'"
  ...
}

Now when you run bolt clean-dist, rather than it running rimraf dist, it will echo "I love electricity!".

Why?

Going through and modifying *.config* files in every react component library you have (which correlates 1:1 to a git repository) is a huge pain in the butt, it's a lot of copy/pasta and no one should 1) have to do that and 2) have to endure the possible degradation over time of human copy/pasta.

This package tries to solve the problem of creating a "meta-monolith" that stands behind our components so people can just build cool stuff and not worry about all the config that goes into keeping a component up to date.

Maybe one day it won't be opinionated. But this day? Not this day.

Opinionated Directory Structure

|-- my_project
|   |-- package.json
|   |-- demo
|   |   |-- index.html
|   |   |-- demo.jsx
|   |-- dist
|   |-- src
|   |   |-- components
|   |   |   |-- component.jsx
|   |   |-- index.js
|   |-- docs
|   |-- test
|       |-- client
|           |-- component
|               |-- component.spec.jsx