open-index/open-npm huggingface dataset:
npm package: @nitrogql/esbuild-register
Description: Uses esbuild to run TypeScript files directly with Node.js
Author: uhyo
Latest version: 1.7.2

# `@nitrogql/esbuild-register`

This package contains an implementation similar to [egoist/esbuild-register](https://github.com/egoist/esbuild-register).

## Usage

Usage depends on your Node.js version.

### Node.js >= 20.6.0 or >= 18.19.0

```sh
node --import=@nitrogql/esbuild-register
```

### Node.js < 20.6.0 and < 18.19.0

```sh
node --import=@nitrogql/esbuild-register --experimental-loader=@nitrogql/esbuild-register/hook
```

## Notes

This package does not intend to be a drop-in replacement for `esbuild-register`. It intentionally does not support some features, for example `import.meta.url` support in CJS modules.
npm package: @nitrogql/jest-transform
Description: Jest transform for loading graphql files
Author: uhyo
Latest version: 1.7.2

# `@nitrogql/jest-transform`

This package serves as a custom Jest transformer for nitrogql. It is responsible for transforming `.graphql` files into JavaScript modules that export the parsed GraphQL document.

Example Jest configuration:

```js
{
  "transform": {
    "^.+\\.graphql$": ["@nitrogql/jest-transform", {
      "configFile":  path.resolve(__dirname, "nitrogql.config.js")
    }]
  }
}
```

## CommonJS Support

`@nitrogql/jest-transform` is only capable of emitting ES modules. If you are running CommonJS modules during your tests, you will need to use another transformer (for example, `babel-jest` or `ts-jest`) to further transform the output from ES modules to CommonJS.

`@nitrogql/jest-transform` lets you apply another transformer to the output. To do so, use the `additionalTransformer` and `additionalTransformerFilenameSuffix` option:

```js
{
  "transform": {
    // For example, if you are using ts-jest...
    "^.+\.tsx?": ["ts-jest", { isolatedModules: true }],
    "^.+\\.graphql$": ["@nitrogql/jest-transform", {
      "configFile":  path.resolve(__dirname, "nitrogql.config.yml"),
      // Then, use the additionalTransformer option to apply ts-jest to the output.
      "additionalTransformer": ["ts-jest", { isolatedModules: true }],
      // ts-jest expects .ts files, so we need to change the file extension
      // by applying the additionalTransformerFilenameSuffix option.
      "additionalTransformerFilenameSuffix": ".ts"
    }]
  },
}
```
npm package: @nitrogql/loader-core
Description: Core of nitrogql's loader implementations.
Author: uhyo
Latest version: 1.7.2

# `@nitrogql/loader-core`

This package contains the core logic for nitrogql's webpack loader and Rollup plugin.

This package is not intended to be used directly, but rather as a dependency of `@nitrogql/graphql-loader` and `@nitrogql/rollup-plugin`.
npm package: @nitrooo/app
Description: Nitro server
Author: The Nitro Team
Latest version: 0.0.3

[![NPM version][npm-image]][npm-url] [![Build Status][travis-image]][travis-url] [![Build Status][appveyor-image]][appveyor-url] [![Dependency Status][daviddm-image]][daviddm-url]

# Nitro App

Nitro is a Node.js application for simple and complex frontend development with a tiny footprint.  
It provides a proven but flexible structure to develop your frontend code, even in a large team.  
Keep track of your code with a modularized frontend. This app and the suggested
[atomic design](http://bradfrost.com/blog/post/atomic-web-design/) and [BEM](https://en.bem.info/method/definitions/)
concepts could help.  
Nitro is simple, fast and flexible. It works on macOS, Windows and Linux. Use this app for all your frontend work.

## Usage

Before using, you need of course [node](https://nodejs.org/) installed.  
Nitro and the Nitro generator are tested with the current 
["Active LTS" versions of node.js](https://github.com/nodejs/Release#release-schedule) (release 8.x).

## Changelog

Todo: Recent changes can be viewed on Github on the [Releases Page](https://github.com/namics/generator-nitro/releases)

## License

[MIT license](http://opensource.org/licenses/MIT)

[npm-image]: https://badge.fury.io/js/@nitrooo/app.svg
[npm-url]: https://npmjs.org/package/@nitrooo/app
[travis-image]: https://travis-ci.org/namics/generator-nitro.svg?branch=master
[travis-url]: https://travis-ci.org/namics/generator-nitro
[appveyor-image]: https://ci.appveyor.com/api/projects/status/0580phm813ccdbhr/branch/master?svg=true
[appveyor-url]: https://ci.appveyor.com/project/namics/generator-nitro/branch/master
[daviddm-image]: https://david-dm.org/namics/generator-nitro.svg?theme=shields.io
[daviddm-url]: https://david-dm.org/namics/generator-nitro
npm package: @nitrooo/webpack
Description: nitro webpack
Author: The Nitro Team
Latest version: 0.0.1

# nitro-webpack

Configurable and easy to use webpack config for nitro projects.

## Usage

```
const options = {
	rules: {
		ts: false,
		scss: true,
		hbs: true,
		woff: true,
		image: true,
	},
	features: {
	    gitInfo: false,
	},
};
const webpackConfig = require('@nitrooo/webpack/webpack-config/webpack.config.dev')(options);

module.exports = webpackConfig;
```

## Configuration

### Rules

Only js loader rule is enabled by default. Activate following prepared rules you need in `options.rules` 

#### `options.rules.ts`

* Type: boolean
* default: false

`true` will activate TypeScript support

#### `options.rules.scss`

* Type: boolean
* default: false

`true` will activate scss support

#### `options.rules.hbs`

* Type: boolean
* default: false

`true` will activate handlebars handlebars precompiled templates support

#### `options.rules.woff`

* Type: boolean
* default: false

`true` will activate woff font support (in CSS files)

#### `options.rules.image`

* Type: boolean
* default: false

`true` will activate image support ()

### `options.features`

Enable some additional features

#### `options.features.gitInfo`

* Type: boolean
* default: false

(only relevant for production build)

`true` will add infos from git (branchname/last commit) in assets banner text
npm package: @nitropay-io/sdk
Description: SDK to interact with the NitroPay payment gateway (API + smart contracts)
Latest version: 0.1.0

# Merchant SDK

SDK for Merchant payment API


## Installation

```
yarn install @dcp/merchant-sdk
```

## usage:

```typescript
import {
  NitroPaySDK
} from "@org/sdk"

try {
  const sdk = new NitroPaySDK({
    publicKey: 'pk_abc123...'
    evmProvider: window.ethereum,
  })

  const chains = await sdk.getSupportedChains() // /GET merchant supported chains
  const chain = chains.find((c) => c.name == "sepolia") // using viem chain name / id

  const supportedTokens = await sdk.getSupportedTokens(chain.id) // /GET chain's vault supported tokens
  const token = supportedTokens.find((t) => t.symbol == "USDC")

  // call your backend which will do a secret key authenticated API call Provider endpoint to generate a paymentIntent
  const paymentIntent = await axios.post('https://your-backend-api.com/payment-intent', {
    chainId: chain.id,
    token: token,
    amount: '10000n'
  })

  console.log(paymentIntent)
  // {
  //   intentId : "0x64..."
  //   chainId : 11155111
  //   vaultAddress: "0xMerchantVault"
  //   tokenAddress: "0xtokenAddress"
  //   amount: 10000000n
  //   status: 'pending'
  // }

  // approve and pay
  const payTxHash = await sdk.pay(paymentIntent)
} catch(err) {
  console.log(err)
}
```