# node-module-example-of-thsi

> Example of node module

Latest version **1.0.2** (published 2020-10-12) · MIT license · 0 weekly downloads

## Install

```sh
npm install node-module-example-of-thsi
pnpm add node-module-example-of-thsi
yarn add node-module-example-of-thsi
bun add node-module-example-of-thsi
```

## Health

**Score 20/100 (F)** — status: abandoned.

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.2 |
| Published | 2020-10-12 |
| First published | 2019-07-02 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Dependencies | 1 |
| Unpacked size | 5.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | EricThsi |
| Maintainers | pluswhite |
| Keywords | Example, Node, Module, TypeScript, Jest, ESLint, Prettier |

## Links

- npm: https://www.npmjs.com/package/node-module-example-of-thsi
- Repository: https://github.com/EricThsi/Node-Module-Example
- Homepage: https://github.com/EricThsi/Node-Module-Example#readme
- Issues: https://github.com/EricThsi/Node-Module-Example/issues
- npm.io page: https://npm.io/package/node-module-example-of-thsi

## Dependencies (1)

- [typescript](https://npm.io/package/typescript.md) ^4.0.3

## Alternatives

- [eslint-plugin-sonarjs](https://npm.io/package/eslint-plugin-sonarjs.md) — 2.9M weekly downloads
- [eslint-config-expo](https://npm.io/package/eslint-config-expo.md) — 1.5M weekly downloads
- [@matter/protocol](https://npm.io/package/@matter/protocol.md) — 63.5K weekly downloads
- [@eventcatalog/linter](https://npm.io/package/@eventcatalog/linter.md) — 24.8K weekly downloads
- [@inrupt/eslint-config-base](https://npm.io/package/@inrupt/eslint-config-base.md) — 4.5K weekly downloads

## Recent versions

- 1.0.2 (latest) — 2020-10-12
- 1.0.1 — 2020-10-12
- 1.0.0 — 2020-10-11
- 0.0.3 — 2019-07-04
- 0.0.2 — 2019-07-02
- 0.0.1 — 2019-07-02

## README

# Node-Module-Example

![npm](https://img.shields.io/npm/v/node-module-example-of-thsi?label=npm-package)
![GitHub](https://img.shields.io/github/license/EricThsi/Node-module-example)
![npm](https://img.shields.io/npm/dm/node-module-example-of-thsi)

## 1. Create package.json

```bash
npm init
```

Note: define your module name in `name` field of `package.json`.

## 2. Define a entry file

`entry` is a file that return object method for the `require('your_module_name')` call.

Can be config in `main` field of `package.json`

## 3. login your npm account

```bash
npm login
npm whoami
```

## 4. Publish your module

```bash
npm publish
```

## 5. Install and Use your module

```bash
# Anthor directory
npm install your-package-name
```

```js
const myModule = require('your-package-name');
myModule();
```

## Notice:

1. If it occurs an error message that `you do not have permission to publish "your module name", Are you logged in as the correct user?`, that means this module had alredy existed.
2. If you update module and want to republish, you **must** update your module version file in package.json, you can use the npm cli `npm version major/minor/patch`.
3. Your registry config must be `http://registry.npmjs.org`, or you can config it a Github npm registry by `https://npm.pkg.github.com`.

---
_Source: https://npm.io/package/node-module-example-of-thsi · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
