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

ninit

v0.1.12

Published

A community-driven Node.js module bootstrapper.

Downloads

20

Readme

ninit Build Status

A community-driven Node.js module bootstrapper with a focus on sharing personal best practices in organizing codebases.

Why?

When I'm talking to developers who are working with Node.js for the first time they are complaining that creating a maintainable structure for their application / module represents one of the hardest aspects. Yes, there are many ways to structure a Node.js module. Every developer has its own style / flavor. That is great! This flexibility makes this community so unbelievable unique. ninit's aim is to provide a platform on which every developer can publish her personal application / module template in order to share best practices and therefore help to support starters but also the evolution of the Node.js ecosystem in general. So this project could be all about sharing experiences regarding this topic.

But even if you don't have any templates to share, no worries, ninit brings the possibility to generate a fresh structure out of the available templates to bootstrap your next project. Enough words. Let's dive into this thingy.

Contributing

The goal of this project is to have a discussion about different views on organizing codebases in Node.js and to provide a platform where all of those organizational patterns can be discussed, archived and used for bootstrapping. So open up your editor and publish your favorite module structure :)

1. Fork ninit

Well, you know, this tiny, but famous, button.

2. Create a template directory

Create a new template directory here, name it like <your-github-username>.<your-template-name> and put all your template files into it.

3. Create a package.json and define some placeholders

The package.json within your template is the central place for the definition of ninit placeholders. These placeholders represent the information which the user has to insert in the case where she wants to generate a new module from your template. They can be used in all of your template files and will be replaced with the actual information while generating the module.

The names of the placeholders are enclosed in '@' characters (e.g. @module description@) and the actual naming is completely up to you. The only required placeholder which has to be defined is '@name@'. See this file for an example.

That's all!

Okay, one last step: Send me a pull request and I will integrate your template into ninit and push a new version to the npm registry :)

Bootstrapping

So this was the part of the contribution. As I said before there is also a generator which can bootstrap a new project out of a template.

Installation

npm install -g ninit

Usage example

ninit akoenig.express-rest

ninit will generate a new application that has the structure of the akoenig.express-rest template.

If you need an overview about the current available templates you could check the respective directory or just type ninit ls

Changelog

Version 0.1.12 (20140412)

  • akoenig.minimal: Added @description@ tag.

Version 0.1.11 (20140404)

  • Changed variable declarations.

Version 0.1.10 (20140315)

  • Fixed placeholder in akoenig.library

Version 0.1.9 (20140310)

  • New template akoenig.gulp-plugin

Version 0.1.8 (20140308)

  • Fixed placeholder in akoenig.minimal

Version 0.1.7 (20140308)

  • New template akoenig.minimal

Version 0.1.6 (20140308)

  • Fixed spec in akoenig.library

Version 0.1.0 - 0.1.5 (20140308)

  • Removed the .npmignore files from the templates.
  • Implemented version command
  • Created gh-pages
  • The initial version with the generator part and two templates, yay :)!

Author

2014, André König ([email protected])