open-index/open-npm huggingface dataset:
npm package: @nsis/dent
Description: An opinionated code formatter for NSIS scripts
Latest version: 0.6.2

# @nsis/dent

> An opinionated code formatter for NSIS scripts

[![License](https://img.shields.io/github/license/idleberg/node-dent?color=blue&style=for-the-badge)](https://github.com/idleberg/node-dent/blob/main/LICENSE)
[![Version](https://img.shields.io/npm/v/@nsis/dent?style=for-the-badge)](https://www.npmjs.org/package/@nsis/dent)
[![Build](https://img.shields.io/github/actions/workflow/status/idleberg/node-dent/default.yml?style=for-the-badge)](https://github.com/idleberg/node-dent/actions)

> [!NOTE]  
> This is the repository for the formatting library. Chances are you are looking for the [CLI tool](https://www.npmjs.com/package/@nsis/dent-cli) instead.

## Installation

`npm install @nsis/dent`

## Usage

```ts
import { createFormatter } from '@nsis/dent';

const format = createFormatter(/* user options */);

format(`
	# Look ma, no indentation
	Name "Demo"
	Section
	Nop
	Section
`);
```

### Options

#### `options.endOfLines`

Type: `"crlf" | "lf"`  
Default: `"crlf"` (Windows), `"lf"` (Linux, macOS)

#### `options.indentSize`

Type: `number`  
Default: `2`  

#### `options.trimEmptyLines`

Type: `boolean`  
Default: `true`  

#### `options.useTabs`

Type: `boolean`  
Default: `true`  

:white_check_mark: [Why defaulting to tabs is good for accessibility](https://github.com/prettier/prettier/issues/7475#issuecomment-668544890)

## Related

- [dent-cli](https://www.npmjs.com/package/@nsis/dent-cli)

## License

This work is licensed under [The MIT License](LICENSE)
npm package: @nsis/dent-cli
Description: An opinionated code formatter for NSIS scripts
Latest version: 0.4.3

# @nsis/dent-cli

> An opinionated code formatter for NSIS scripts

[![License](https://img.shields.io/github/license/idleberg/node-dent-cli?color=blue&style=for-the-badge)](https://github.com/idleberg/node-dent-cli/blob/main/LICENSE)
[![Version](https://img.shields.io/npm/v/@nsis/dent-cli?style=for-the-badge)](https://www.npmjs.org/package/@nsis/dent-cli)
[![Build](https://img.shields.io/github/actions/workflow/status/idleberg/node-dent-cli/default.yml?style=for-the-badge)](https://github.com/idleberg/node-dent-cli/actions)

## Prerequisites

This is a TypeScript application that depends on a [NodeJS](https://nodejs.org) runtime installed on your computer.

## Usage

### Installation

> [!TIP]
>
> If you don't use a JavaScript runtime such as Node.js, download a binary of the [latest version](https://github.com/idleberg/node-dent-cli/releases/latest) for Windows.

You could install the `dent` CLI globally

```sh
$ npm install --global @nsis/dent-cli
$ npx dent --help
```

### Single use

Download and execute the latest version using [`npx`](https://medium.com/@maybekatz/introducing-npx-an-npm-package-runner-55f7d4bd282b).

```sh
$ npx @nsis/dent-cli --help
```

### Options

```
Usage: dent [options] <file...>

CLI tool to format NSIS scripts

Options:
  -V, --version               output the version number
  -D, --debug                 prints additional debug messages (default: false)
  -h, --help                  display help for command

Formatting Options
  -e, --eol <"crlf"|"lf">     control how line-breaks are represented (default: "lf")
  -i, --indent-size <number>  number of units per indentation level (default: 2)
  -s, --use-spaces            indent with spaces instead of tabs (default: false)
  -t, --trim                  trim empty lines (default: true)
  -w, --write                 edit files in-place (default: false)
```

## Related

- [dent](https://www.npmjs.com/package/@nsis/dent)

## License

This work is licensed under [The MIT License](LICENSE)
npm package: @nsis/mui-language-strings
Description: Parser for NSIS Modern UI language headers
Latest version: 0.3.0

# mui-language-strings

[![npm](https://flat.badgen.net/npm/license/@nsis/mui-language-strings)](https://www.npmjs.org/package/@nsis/mui-language-strings)
[![npm](https://flat.badgen.net/npm/v/@nsis/mui-language-strings)](https://www.npmjs.org/package/@nsis/mui-language-strings)
[![CircleCI](https://flat.badgen.net/circleci/github/idleberg/node-mui-language-strings)](https://circleci.com/gh/idleberg/node-mui-language-strings)
[![David](https://flat.badgen.net/david/dev/idleberg/node-mui-language-strings)](https://david-dm.org/idleberg/node-mui-language-strings?type=dev)

Parser for NSIS Modern UI language headers

## Installation

`yarn add @nsis/mui-language-strings || npm install @nsis/mui-language-strings`

## Usage

Use ES6 imports or `require()` to include the module:

```js
// ECMAScript Import
import { parse } from '@nsis/mui-language-strings';

// CommonJS Require
const { parse } = require('@nsis/mui-language-strings');
```

Example usage in script:

```js
// Read an NSIS Language File
const languageFile = fs.readFileSync('Contrib/Language files/English.nsh', 'utf8');

const languageObj = parse(languageFile);
```

### Methods

#### parse

Usage: `parse(string, options)`

Parses an NSIS Modern UI language header, constructing an object or JSON string that's easy to query

##### options.looseQuotes

Type: `boolean`

Ignores leading and trailing quotes of a language string. This option is useful to parse the Hindi language, which currently lacks one trailing quote.

##### options.minify

Type: `boolean`

Minifies a stringified object, requires `options.stringify` to be `true`

##### options.stringify

Type: `boolean`

Return a stringified object

## License

This work is licensed under [The MIT License](https://opensource.org/licenses/MIT)

## Donate

You are welcome to support this project using [Flattr](https://flattr.com/submit/auto?user_id=idleberg&url=https://github.com/idleberg/node-mui-language-strings) or Bitcoin `17CXJuPsmhuTzFV2k4RKYwpEHVjskJktRd`
npm package: @nsis/nlf
Description: Parser and stringifier for NSIS Language Files
Latest version: 0.13.0

# nlf

[![License](https://img.shields.io/github/license/idleberg/node-nlf?color=blue&style=for-the-badge)](https://github.com/idleberg/node-nlf/blob/main/LICENSE)
[![Version](https://img.shields.io/npm/v/@nsis/nlf?style=for-the-badge)](https://www.npmjs.org/package/@nsis/nlf)
![GitHub branch check runs](https://img.shields.io/github/check-runs/idleberg/node-nlf/main?style=for-the-badge)

Parser and stringifier for NSIS Language Files (.nlf)

## Installation

` npm install @nsis/nlf`

## Usage

```js
import * as NLF from "@nsis/nlf";
```

Example usage in script:

```js
// Read an NSIS Language File
const languageFile = fs.readFileSync(
	"Contrib/Language files/English.nlf",
	"utf8",
);

const languageObj = NLF.parse(languageFile);
const languageNew = NLF.stringify(languageObj);
```

### Methods

#### parse

Usage: `parse(string)`

Parses an NSIS Language File, constructing an object.

#### stringify

Usage: `stringify(Object|string, options)`

Converts an NSIS Language File object or JSON string to an `.nlf` string.

##### options.eol

Type: `"crlf" | "lf"`

Selects the default end of line sequence. When not specified, it defaults to `"crlf"` on Windows and `"lf"` elsewhere.

## Related

- [nlf-cli](https://www.npmjs.org/package/@nsis/nlf-cli) - command-line tool to convert NLF files
- [vite-plugin-nlf](https://www.npmjs.org/package/@nsis/vite-plugin-nlf) - Vite plugin to load NSIS language files

## License

This work is licensed under [The MIT License](LICENSE).
npm package: @nsis/nlf-cli
Description: CLI tool to convert NSIS Language Files to JSON and vice versa
Latest version: 0.11.0

# nlf-cli

[![License](https://img.shields.io/github/license/idleberg/node-nlf-cli?color=blue&style=for-the-badge)](https://github.com/idleberg/node-nlf-cli/blob/main/LICENSE)
[![Version](https://img.shields.io/npm/v/@nsis/nlf-cli?style=for-the-badge)](https://www.npmjs.org/package/@nsis/nlf-cli)
![GitHub branch check runs](https://img.shields.io/github/check-runs/idleberg/node-nlf-cli/main?style=for-the-badge)

CLI tool to convert NSIS Language Files to JSON and vice versa

## Installation

```sh
npm install --global @nsis/nlf-cli
```

Alternatively, you can use it without installation

```sh
npx @nsis/nlf-cli <parameters>
```

## Usage

You can now use the `nlf` command to convert language files:

```sh
# Standard usage
nlf "Contrib/Language files/English.nlf"

# Alternatively, use stdin
cat "Contrib/Language files/English.nlf" | nlf
```

### Options

Running `nlf --help` list available flags

```
--version    output the version number
--eol        select end of line sequence
--minify     minify output JSON
--output     set the output directory
--stdout     print result to stdout
--help       output usage information
```

## Related

- [nlf](https://www.npmjs.org/package/@nsis/nlf) - library to convert NLF files
- [vite-plugin-nlf](https://www.npmjs.org/package/@nsis/vite-plugin-nlf) - Vite plugin to load NSIS language files

## License

This work is licensed under [The MIT License](https://opensource.org/licenses/MIT)
npm package: @nsis/vite-plugin-nlf
Description: A Vite plugin to load NSIS language files
Author: Jan T. Sott
Latest version: 0.3.0

# @nsis/vite-plugin-nlf

> A Vite plugin to load NSIS language files

[![License](https://img.shields.io/github/license/idleberg/vite-plugin-nlf?color=blue&style=for-the-badge)](https://github.com/idleberg/vite-plugin-nlf/blob/main/LICENSE)
[![Version](https://img.shields.io/npm/v/@nsis/vite-plugin-nlf?style=for-the-badge)](https://www.npmjs.org/package/@nsis/vite-plugin-nlf)
[![Build](https://img.shields.io/github/actions/workflow/status/idleberg/vite-plugin-nlf/tests.yml?style=for-the-badge)](https://github.com/idleberg/vite-plugin-nlf/actions)

## Installation

`npm install -D @nsis/vite-plugin-nlf`

## Usage

```js
// vite.config.js
import { defineConfig } from 'vite';
import nlf from '@nsis/vite-plugin-nlf';

export default defineConfig({
    plugins: [
        nlf()
    ]
});
```

```js
// example.js
import English from './Contrib/Language files/English.nlf';

console.log(`The ID for English is ${English.id}`);
```

## License

This work is licensed under [The MIT License](LICENSE).
npm package: @nsisodiya/es6-mixins
Description: ES6 Mixins, Useful for adding Mixin support to React Component when you use ES6 class syntax
Author: Narendra Sisodiya
Latest version: 1.1.0

# es6-mixins
ES6 Mixins, Useful for adding Mixin support to React Component when you use ES6 class syntax

# Installation

```
npm install --save @nsisodiya/es6-mixins
```

# Usage

```js
import Mixin from '@nsisodiya/es6-mixins';

// The first class to be used as a mixin
class TestMixin1 {
	testMethod1() {
		console.log('test Method 1 from TestMixin1');
	}

	testMethod2() {
		console.log('test Method 2 from TestMixin2');
	}
}

// The second class to be used as a mixin
class TestMixin2 {
	testMethod1() {
		console.log('test Method 1 from TestMixin2');
	}
}

class MainClass {
	constructor() {
		this.testMethod1(); // outputs 'test Method 1 from TestMixin2' and then 'test Method 1 from TestMixin1' will warn in console about duplicate methods.
	}
}

Mixin(MainClass, [TestMixin1, TestMixin2]);

new MainClass();
```
npm package: @nsisodiya/eventbus
Description: Simple EventBus for Node.js
Author: Narendra Sisodiya
Latest version: 1.1.0

# @nsisodiya/eventbus
Simple EventBus for Node.js

# Installation

```
npm install --save @nsisodiya/eventbus
```

# Usage

```js
import EventBus from '@nsisodiya/eventbus';


var b1 = new EventBus();

var unsub1 = b1.subscribe("ADD_EVENT", function (obj) {
	console.log("AddEvent Received at Section 1", obj);
});


var unsub2 = b1.subscribe("ADD_EVENT", function (obj) {
	console.log("AddEvent Received at Section 2", obj);
});


var unsub3 = b1.subscribeAll(function (obj, obj2) {
	console.log("Some Event Received at Section 3", obj, obj2);
});


b1.publish("ADD_EVENT", {done: false, title: "write JS"});
/*
AddEvent Received at Section 1 Object {done: false, title: "write JS"}
AddEvent Received at Section 2 Object {done: false, title: "write JS"}
Some Event Received at Section 3 ADD_EVENT Object {done: false, title: "write JS"}
*/

b1.publish("EDIT_EVENT", {done: false, title: "write JS"});
/*
Some Event Received at Section 3 EDIT_EVENT Object {done: false, title: "write JS"}
*/


unsub1();

b1.publish("ADD_EVENT", {done: false, title: "write JS"});
/*
AddEvent Received at Section 2 Object {done: false, title: "write JS"}
Some Event Received at Section 3 ADD_EVENT Object {done: false, title: "write JS"}
*/


unsub3();

b1.publish("EDIT_EVENT", {done: false, title: "write JS"});

/*
No Output and no one subscribe this event.
*/
```
npm package: @nsisodiya/flux
Description: Simple Flux Experimental Code
Author: Narendra Sisodiya
Latest version: 1.1.0

# @nsisodiya/flux
Simple Flux Implementation

# Installation

```
npm install --save @nsisodiya/flux
```

# Usage

```js
import { dispatcher, createStore} from '@nsisodiya/flux';

var counterStore = createStore({
	INIT: function (state) {
		state.count = 0;
	},
	COUNTER_INCREMENT: function (state) {
		state.count = state.count + 1;
	},
	COUNTER_INCREMENT_NUM: function (state, num) {
		state.count = state.count + num;
	},
	COUNTER_DECREMENT: function (state) {
		state.count = state.count - 1;
	}
});

counterStore.onChange(() => {
	console.log("New State is ", counterStore.getState());
});
dispatcher.subscribeAll((evtName, args) => {
	console.log("Some Event was Fired", evtName, args);
});

dispatcher.publish('COUNTER_INCREMENT');
dispatcher.publish('COUNTER_INCREMENT');
dispatcher.publish('COUNTER_INCREMENT_NUM', 3);
dispatcher.publish('COUNTER_DECREMENT');
dispatcher.publish('COUNTER_INCREMENT');

/* OutPut
New State is  Object {count: 1}
Some Event was Fired COUNTER_INCREMENT undefined
New State is  Object {count: 2}
Some Event was Fired COUNTER_INCREMENT undefined
New State is  Object {count: 5}
Some Event was Fired COUNTER_INCREMENT_NUM 3
New State is  Object {count: 4}
Some Event was Fired COUNTER_DECREMENT undefined
New State is  Object {count: 5}
Some Event was Fired COUNTER_INCREMENT undefined
*/
```
npm package: @nsisodiya/react-components
Description: Hotelsoft Common React Components
Author: Narendra Sisodiya
Latest version: 3.1.0

# sample-react-component-lib
How to build this repo

```
npm install
npm run server
```

# Purpose and Problem with current code
This repo is working fine. It is meant for a small collections of Reusable React Components. like React-Bootstrap.
Repo include 2 main section. 
1. Actual Code
2. Code to Showing Demo of Components.

But there is a minor problem.
In order to make demo page working, I have to include some variable like this

```
import React from "react";
import ReactDOM from "react-dom";
import ReactCSSModules from "react-css-modules";
import {
  OverlayTrigger,
  Tooltip
} from "react-bootstrap";
import uuid from "uuid";

window.React = React;
window.ReactDOM = ReactDOM;
window.ReactCSSModules = ReactCSSModules;
window.UUID = uuid;
window.ReactBootstrap = {
  OverlayTrigger,
  Tooltip
};
```


This is the problem which I am facing. I want to remove this hack. If you know the solution then fork and send me pull request !!

# Video

https://www.youtube.com/watch?v=UsxEZTm0kYk
npm package: @nsisong/messagejs
Description: MessageJS Client SDK - Lightweight SDK for sending messages from web apps
Author: Isaac Emmanuel
Latest version: 0.2.0

# @nsisong/messagejs

MessageJS Client SDK - Send messages via WhatsApp, Telegram, SMS, and more through a simple, unified API.

## Installation

```bash
npm install @nsisong/messagejs
```

## Quick Start

```typescript
import messagejs from '@nsisong/messagejs';

// Initialize the SDK
messagejs.init({
  apiKey: 'sk_live_your_api_key',
  baseUrl: 'https://api.messagejs.pro'
});

// Send a message
const result = await messagejs.sendMessage({
  connectorId: 'conn_whatsapp',
  templateId: 'tpl_welcome',
  to: '+1234567890',
  variables: {
    name: 'John',
    code: '12345'
  }
});

console.log('Message ID:', result.messageId);
console.log('Status:', result.status);
```

## Documentation

For complete documentation, visit [https://docs.messagejs.pro](https://docs.messagejs.pro)

## License

MIT
npm package: @nsivertsen/svelte-preprocess-postcss
Description: Svelte preprocessor function for PostCSS
Author: Nikolai Sivertsen
Latest version: 0.1.0

# svelte-preprocess-postcss

Svelte preprocessor function for PostCSS.

## Install

```
npm install --save-dev @nsivertsen/svelte-preprocess-postcss
```

## Usage

If you're using the Svelte compiler API directly:

```js
import * as svelte from 'svelte';
import postcss from 'svelte-preprocess-postcss';

const processed = await svelte.preprocess(source, {
  style: postcss()
});
```

If you're using Rollup with [rollup-plugin-svelte](https://github.com/rollup/rollup-plugin-svelte/):

```js
import svelte from 'rollup-plugin-svelte';
import postcss from 'svelte-preprocess-postcss';

export default {
  // ...
  plugins: [
    // ...
    svelte({
      preprocess: {
        style: postcss()
      }
    }),
    // ...
  ],
  // ...
};
```

## API

```
preprocessorFunction = postcss([context])
```

`svelte-preprocess-postcss` cares about the following keys in `context`:

| | **Values** | **Description** | **Default** |
|---|---|---|---|
| `useConfigFile` | `true`, `false` | Whether to load a PostCSS configuration from disk using `postcss-load-config` | `true` |
| `configFilePath` | `string` | The path to your PostCSS config file. If not given, `postcss-load-config` will look in the current working directory | `undefined` |

All other keys are passed on to `postcss-load-config`. It passes the following keys on to PostCSS if provided:

| | **Values** | **Description** | **Default** |
|---|---|---|---|
| `plugins` | `array` | Array of PostCSS plugins | `[]` |
| `options` | `object` | PostCSS options | `{}` |

## License

MIT
npm package: @nsivertsen/svelte-preprocess-sass
Description: Svelte preprocessor function for Sass
Author: Nikolai Sivertsen
Latest version: 0.1.1

# svelte-preprocess-sass

Svelte preprocessor function for Sass. Uses [Dart Sass](https://github.com/sass/dart-sass).

## Install

```
npm install --save-dev @nsivertsen/svelte-preprocess-sass
```

## Usage

If you're using the Svelte compiler API directly:

```js
import * as svelte from 'svelte';
import sass from 'svelte-preprocess-sass';

const processed = await svelte.preprocess(source, {
  style: sass()
});
```

If you're using Rollup with [rollup-plugin-svelte](https://github.com/rollup/rollup-plugin-svelte/):

```js
import svelte from 'rollup-plugin-svelte';
import sass from 'svelte-preprocess-sass';

export default {
  // ...
  plugins: [
    // ...
    svelte({
      preprocess: {
        style: sass()
      }
    }),
    // ...
  ],
  // ...
};
```

Now, add a `type="text/scss"` attribute to your components' style tags, and you're good to go:

```html
<style type="text/scss">
  $color: blue;

  h1 {
    color: $color;
  }
</style>
```

## Options

The function exported by `svelte-preprocess-sass` optionally takes an options object as a first argument. The only option it cares about is `attribute`. All other options are passed on to Sass (see the Sass [documentation](https://github.com/sass/dart-sass/#javascript-api) for available options).

You can use the `attribute` option to configure the HTML attribute that determines which style tags should be processed by Sass. For example:

```js
const processed = await svelte.preprocess(source, {
  style: sass({
    attribute: { key: 'lang', value: 'sass' }
  })
});
```

tells `svelte-preprocess-sass` to process style tags with a `lang="sass"` attribute:

```html
<style lang="sass">
  $color: blue;

  h1 {
    color: $color;
  }
</style>
```

The default is `type="text/scss"`;

## License

MIT