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

initialiseur

v5.1.1

Published

THIS IS A BOILER PLATE CODE INITIALIZER FOR NODE.JS APPLICATIONS (express, koa, electron).

Downloads

40

Readme

initialiseur

This is a package that can be installed on your computer to easily initialize node.jsnode applications boiler plates:

It initializes the following boiler plate code

- express
- koa
- electron

Express Application

This backend server is an express application with cors configured that is ready to run on a configured default port 3001 which can be modified in code. This package can initialize boiler plate code for a basic express application for the following languages:

  1. javascript
  2. typescript (default)

Generated files for an express boiler plate:


Generating Basic Files(🌼) and Folders(📁)
  📁  src
     📁  routes
       🌼 index.ts
     🌼 server.ts
  🌼 .gitignore
  🌼 .env
  🌼 package.json
  🌼 tsconfig.json

Koa Application

This backend server is an koa that is ready to run on a configured default port 3001 which can be modified in code. This package can initialize boiler plate code for a basic express application for the following languages:

  1. javascript
  2. typescript (default)

Generated files for an koa boiler plate:

Generating Basic Files(🌼) and Folders(📁)
  📁  src
     📁  routes
        📁  hello
           🌼 index.ts
     🌼 server.ts
  🌼 .gitignore
  🌼 .env
  🌼 package.json
  🌼 tsconfig.json

Electron

This is skeleton electron application that is ready and running. All you have to do it to change the code according to what you want your application to do. The current version 5.0.* is currently having one language initialization for an electron application which is:

  1. javascript

Generated files for an electron boiler plate:

Generating Basic Files(🌼) and Folders(📁)
  📁  src
     📁  public
        🌼 index.html
     📁  scripts
        🌼 index.js
        🌼 preload.js
     📁  styles
        🌼 index.css
     🌼 main.js
  🌼 .gitignore
  🌼 README.md
  🌼 LICENSE
  🌼 .env
  🌼 package.json

Note that this package is coming from @crispengari/node-backend.

Getting started

First you need to install the node initialiseur globally by running the following command:

  1. Using npm
npm install -g initialiseur
  1. Using yarn
yarn global add initialiseur

Usage

To initialize a new node boiler plate application you run the following command:

initialiseur init <name>

Note that you can initialize the node.js backend project without installing initialiseur globally by the use of npx:

npx initialiseur init <name>
  • <name> is optional if note specified initialiseur will use the root directory of the project as the default package name, which can be altered as well.

Available commands in initialiseur

  1. help This shows all available commands of initialiseur package
initialiseur -h

# or
initialiseur --help
  1. version This shows the currently installed version of initialiseur package:
initialiseur -v
# or
initialiseur --version
  1. init

This initializes a new initialiseur project:


initialiseur init <name>
# Or
initialiseur init

Starting the apps.

Note: Starting the server is different if you are using typescript or javascript and if you are using electron, koa or express.

  1. With JavaScript:
# yarn
yarn start

# npm
npm run start

The above command start a application for both electron, koa and express. The electron application is currently starting with one command which is the start.

  1. With TypeScript:

With ts you have to open two command the one that will watch for file changes and the other one that will run the compiled javascript code: a) cmd 1

# yarn
yarn watch

# npm
npm run watch

b) cmd 2

# yarn
yarn dev

# npm
npm run dev

Or you can run a single command which was introduced in version 5.1.* which is:

# yarn
yarn start:fast

# npm
npm run start:fast

The above commands can only be run when you are either running a typescript application for either koa or express.

From @crispengari/node-backend to initialiseur

Initialiseur was initially @crispengari/node-backend so you can initialize the node.js backend by running executing @crispengari/node-backend using npx.

Executing specific versions

You can be able to execute the specific versions of @crispengari/node-backend using the node package executer (npx)

  1. Running the node package executer npx
npx @crispengari/node-backend@<version>

# example (make sure the version exists before running this)
npx @crispengari/node-backend@<1.3.2>

Available working versions

v1

  1. @crispengari/[email protected]
  2. @crispengari/[email protected]
  3. @crispengari/[email protected]
  4. @crispengari/[email protected]

v2

  1. @crispengari/[email protected]

v3

  1. [email protected]
  2. [email protected]
  3. [email protected]

What's new in initialiseur@4.*.*?

  • In this version developers are allowed to choose licenses templates from the available ones during backend initialization.
  • Developers can also select which additional optional files they want to add in their project during initialization.

What is new in initialiseur@5.*.*?

  • In this version developers are now able to select the application they want to initialize between:
    • express application
    • electron application
    • koa application
  • Developers still have choice to choose the programming language to be used among:
    • javascript
    • typescript
  • The language choices are currently working for the following applcations:
    • koa application
    • express application

Why initialiseur?

initialiseur is a name that I got from google translation english to french for the name initializer. I created this package so that developers can create their backend applications with typescript or javascript without running into a headache of creating files and installing basic packages like express.

Commonly Known Issues.

  • The initialiseur package has commonly known issue when for starting the kao or express server for the first time with the start:fast command for both npm and yarn. The error is as follows:
 Error: Cannot find module './server.js'

The solution to this is to either open one of your ts boiler plate files and save it or you stop the command and run it again.

License

MIT License

Copyright (c) 2021 Crispen Gari

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.