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

nodroid

v1.4.5

Published

create a Projecttemplate for a NodeJs Project using VS Code and yarn

Downloads

8

Readme

Node Droid

Creates a Standard Template for a Empty NodeJs Project.

Requirements before we can start

First of all we have to Download and Install VSCode from here. After the installation I recommend to install these extensions.

VSCode Extensions

| Extension | Description | |------------------------------------------|-------------------------------------------------------------| | ESLint | linting Code on the Fly | | Node TDD | Helps to execute Tests when Code is changed | | Coverage Gutters | Show Code Coverage on the Fly | | Document This | Fast and Easy Documentation Generation | | npm && npm intellisense | enables Intellisense in package.json | | Path Autocomplete | Intellisense for Paths | | Project Manager | working with multiple Projects | | GIT Lens | brings GIT Informations in the Code | | GraphQl for VSCode | brings GraphQl Syntax Highliting and Intellisense to VSCode | | Linux Themes for VS Code && vscode-icons | better Styling |

The second dependency is Yarn. This tool builds NPM and allows you to install the packages faster. To install Yarn please follow the instructions here.

Install Tool

Now we are ready to install the nodroid command. To do this we only need to execute the following command.

yarn global add nodroid

Usage

How to create a new project:

nodroid init

Name of your Project?:{input name of Project}
Author?:{input the name of the Author}
Authors Email?:{input Email of the Author}
License?:{input License Type}

An attempt is made to create a new folder with the project name. If the folder already exists, it is possible to delete the contents. This should not be done if you have e. g. cloned an empty GIT project, because then the settings of GIT will be deleted!

How to create an alias

nodroid resolve myfolder src/somefolder

If a project is created, the alias "~" is already created for the src directory. Any other aliases can be added, but they may only be assigned once! These are entered in the VS Code setting for the Path Autocomplete plugin, in the jsconfig. json for the VS Code Intellisense and in the. babelrc for Babel.

Folder Structure

| Folder | Description | |--------------|--------------------------------| | .vscode | Settings for VSCode | | node_modules | dependencies | | spec | Folder for Tests | | src | Source Code Folder | | dist | buildfolder for Release | | coverage | generated Coverage Folder | | docs | generated Documentation Folder |

Scripts

| Script | What it does | |--------|--------------------------------------| | start | start the index.js in the src Folder | | test | run the Tests and generate Coverage | | build | build the Code for Release usage | | docs | generate the Documentation |

Debug Launcher

Two processes are entered in the VS Code Launch setting. Once "Launch Program" to start the index. js from the src directory and "Tests" to start the tests from the spec directory.

under the Hood

| Package | Using for... | |-----------------------|--------------------------------------------------------| | babel-cli | use Babel Commands for Transpiling | | babel-plugin-istanbul | used for generation of Coverage | | babel-plugin-module-resolver | create aliases for folders | | babel-plugin-transform-runtime | transpile async and await | | babel-preset-env | latest transpiling Rules | | babel-preset-stage-2 | transpiling Rules for newest ES Features | | babel-register | helps to transpile Code for Testing | | chai | assert Testing Tool | | mocha | Test Runner | | sinon | Mocking Tool | | nyc | Coverage Reporter | | esdoc | Documentation Generator for ES2017 | | esdoc-standard-plugin | the Default Pugin for esdoc | | eslint | check Javascript Code for Errors | | eslint-config-google | eslint Google Ruleset | | nodemon | used to automat restart Processes |