open-index/open-npm huggingface dataset:
npm package: @massimo-cassandro/charts
Description: SVG charts
Author: Massimo Cassandro
Latest version: 2.5.3

# Charts
A collections of charts scripts

**Charts** comes with three flavours: 

* Main mode (index.js): standard way, use imported svg.js module
* Node mode (index-node.js): for use within node script (to be imported as module)
* With svg.js imported as a standalone script (index-external-svgjs.js): if you need to import svg.js using the script tag, this implementation doesn't load svg.js but assumes that a global `SVG` function is available


## Radial bars chart
Oct 2022

Refs: 

* https://codepen.io/massimo-cassandro/pen/zYRBJyG?editors=1100
* https://datavizproject.com/data-type/circular-bar-chart/
* https://datavizcatalogue.com/methods/radial_bar_chart.html


## General references

* <https://levelup.gitconnected.com/publish-react-components-as-an-npm-package-7a671a2fb7f>
* <https://itnext.io/how-to-package-your-react-component-for-distribution-via-npm-d32d4bf71b4f>
npm package: @massimo-cassandro/cookie-consent
Description: Small and customizable script to display a cookie consent banner
Author: Massimo Cassandro
Latest version: 3.1.0

# Cookie consent banner

**v.3 (was “consenso-cookie” in v.1)**

<https://github.com/massimo-cassandro/cookie-consent>

Small and customizable script to display a cookie consent banner

## Installation

```
npm i --save @massimo-cassandro/cookie-consent
```

## Using Cookie consent banner
Import `cookie-consent.js` as es6 module to your project and add
`cookie-consent.scss` to your styles (you can also use the compiled css version in the demo folder).

```javascript
import {cookie_consent} from '@massimo-cassandro/cookie-consent';
```

Many elements of scss can be customized:

```scss
$mcc-font-family: false; // set to false to inherit document font-family
$mcc-banner-bg-color: #444;
$mcc-banner-text-color: color-yiq($mcc-banner-bg-color);

$mcc-link-color: #fc0;
$mcc-link-hover-color: darken($mcc-link-color, 10);
$mcc-link-text-decoration: none;
$mcc-link-hover-text-decoration: underline;

$mcc-button-bg-color: #fc0;
$mcc-button-text-color: #000;
$mcc-button-hover-bg-color: darken($mcc-button-bg-color, 10);
$mcc-button-hover-text-color: #000;

$mcc-border-radius: 0;

$mcc-box-shadow: 0 0 4px rgba(#000, .6); // set to false or none to disable

@import '@massimo-cassandro/cookie-consent';
```

To activate the banner, invoke the function adding some parameter:

```javascript
cookie_consent({
  message: '...',
  btn_text: '...',
  banner_aria_label: '...',
  btn_aria_label: '...',
  btn_class: '...' 
});
```

Where:

* `message` is the text to be displayed in the banner (html allowed). It may contain the link to your privacy policy page
* `btn_text` is the text of the dismiss button (html allowed)
* `banner_aria_label` and `btn_aria_label` are text for ARIA label attributes
* `btn_class` is an optional class(es) to be added to the dismiss button

The banner is positioned at page bottom right. To change this behavior you have to change the scss/css file.

If the banner is displayed, a `div.cookie-consent` element is appended to your page.
npm package: @massimo-cassandro/dev-updater
Description: Web development uitilities
Author: Massimo Cassandro
Latest version: 3.0.3

# Dev updaters

Utilità per lo sviluppo.

vedi:

* [upd@m](./app/upd@m/README.md)
* [update-version](./app/update-version/README.md)


## Utilizzo nella sezione script del file `package.json`

```json
{
  "scripts": {
     "update-version": "npx update-version",
     "upd@m": "npx upd@m"
  }
}
```
npm package: @massimo-cassandro/dom-builder
Description: Builds dom elements from array of objects
Author: Massimo Cassandro
Latest version: 1.1.0

# Dom builder

Builds dom elements from array of objects.

Only available as module script.

```
import { domBuilder } from '@massimo.cassandro/dom-builder';

domBuilder({ /* options */}); // see source code for details
```
npm package: @massimo-cassandro/eslint-config
Description: my eslint config
Author: Massimo Cassandro
Latest version: 3.0.5

# Eslint config

My [eslint](https://eslint.org/) config,


## Use

Install `eslint` and all the needed packages:

```bash
npm i -D @massimo-cassandro/eslint-config
```

Create a `eslint.config.js` file (or use any other name and syntax you like, following the instructions at <https://eslint.org/docs/latest/use/configure/configuration-files>) and add:

```javascript
import eslint_config from '@massimo-cassandro/eslint-config';

// OPTIONAL
// https://github.com/cybozu/eslint-config
// import cybozuEslintConfigBaseline from '@cybozu/eslint-config/flat/presets/css-baseline.js'; 


export default [

  // ...cybozuEslintConfigBaseline.map((config) => ({
  //   ...config,
  //   files: ['**/*.css']
  // })),

  ...eslint_config,
  // {
  //   files: ['src/**/*.js'],
  //   ignores: [
  //     'dist/',
  //     'build/',
  //     '**/vendor/'
  //   ],
  // }
  // {
  //   languageOptions: {
  //     globals: {
  //       jQuery: 'readonly',
  //       $: 'readonly',
  //     },
  //   },
  // },
];
```
npm package: @massimo-cassandro/form-utilities
Description: Form utilities
Author: Massimo Cassandro
Latest version: 1.2.1
Deprecated: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.

# form-utilities

Archived on Jul 24 2023 and merged with [js-utilities](https://github.com/massimo-cassandro/js-utilities).
npm package: @massimo-cassandro/linters-config
Description: Css & js linters configurations
Author: Massimo Cassandro
Latest version: 1.6.1
Deprecated: @massimo-cassandro/linters-config is no longer supported, use @massimo-cassandro/styleint-config and @massimo-cassandro/eslint-config

# Linters config


In `package.json`

```json
{
  "stylelint": {
    "extends": "@massimo-cassandro/linters-config/stylelintrc.js",
    "ignoreFiles": [
      "build/**/*.css"
    ],
    "rules": {}
  },
   "eslintConfig": {
    "extends": "./node_modules/@massimo-cassandro/linters-config/eslintrc.js",
    "ignorePatterns": [],
    "rules": {}
  }
}
```
npm package: @massimo-cassandro/m-utilities
Description: My collection of front-end development snippets & utilities
Author: Massimo Cassandro
Latest version: 5.3.0
Deprecated: This package is no longer supported and has been split into @massimo-cassandro/js-utilities, @massimo-cassandro/ckeditor-utilities, @massimo-cassandro/scss-utilities, @massimo-cassandro/auto-datatables-bs5, @massimo-cassandro/twig-utilities

# m-utilities

Collection of js, less, sass etc snippets and utilities, including ones from others developers (cited), for front-end development.

Install it using npm:

```
npm i --save @massimo-cassandro/m-utilities
```

Consult the [repository](https://github.com/massimo-cassandro/m-utilities) for the complete list of utilities (some of them are not included in the npm distribution).

***

**Caution**: This is a collection of utilities for my personal projects and all elements can be moved, renamed or deleted without notice. Be careful if you decide to use them.

***

## breaking changes

### v3.x → v4.x
* naming standardization: many filenames have been changed 
* `submitErr` function is now exported from a new file (`submit-error-bs4`, or `submit-error-bs5`) and not from `_form_utilities.js`. The function is now exported as default
npm package: @massimo-cassandro/minimo
Description: Light css framework
Author: Massimo Cassandro
Latest version: 0.3.5

# minimo

Very light-size framework

...and some install [snippets](snippets/snippets.md)

## Install

```bash
npm i @massimo-cassandro/minimo
```

> Note: **minimo** is designed to be used with WebPack using the configuration you can find in the [boilerplate folder](./boilerplate/) of this repository. If changes are made (for example, to how SVG files are imported), things may not work as expected
npm package: @massimo-cassandro/modal-alert
Description: Vanilla JS modal alert
Author: Massimo Cassandro
Latest version: 2.7.2

# modal-alert
Vanilla JS modal alert

Demo: <https://massimo-cassandro.github.io/modal-alert/demo/>

## Use:

### Add the css file to your page

Optionally, add this custom properties to your page (see the `src/modal-alert.scss` file for default values):

* `--malert-success-color`: success color
* `--malert-success-color-fg`: success color foreground
* `--malert-info-color`: info color
* `--malert-info-color-fg`: info color foreground
* `--malert-warning-color`: warning color
* `--malert-warning-color-fg`: warning color foreground
* `--malert-error-color`: error color
* `--malert-error-color-fg`: error color foreground
* `--malert-confirm-color`: confirm color
* `--malert-confirm-color-fg`: confirm color foreground
* `--malert-marks-stroke-width`: stroke width for svg marks
* `--malert-backdrop`: dialog backdrop color
* `--malert-border-radius`: dialog border radius
* `--malert-box-shadow`: dialog box shadow
* `--malert-heading-font-family`: font family for dialog heading
* `--malert-heading-font-size`: font size for dialog heading
* `--malert-heading-font-weigth`: font weigth for dialog heading
* `--malert-body-font-family`: font family for dialog body text
^ `--malert-background-color`: background color

### Add javascript

```javascript
import mAlert from '@massimo-cassandro/modal-alert';

mAlert({
  type              : 'success', // success warning error info confirm

  // optionals
  // -------------------------------------------------------------------------
  title             : 'Some title',        // NB: required for `info`
  mes               : 'Some message',      // message, default null
  ok_btn_text       : 'OK',                // text for OK button (default `OK`)
  cancel_btn_text   : 'Annulla',           // text for cancel button (`confirm` only)

  // callback function
  // default `null`
  // the `result` argument is available only for the confim type
  // `result` is `true` if the user confirms, `false` if they cancel
  callback          : function(result) {}, 

  // ms for autoclose, null for disable
  // default `4000` for success, `null` for the others
  // has not effects on `confirm`
  timer             : 4000,

  // classes to be added to relative element (default `null`)
  heading_class     : 'text-success',
  ok_btn_class      : 'btn-success',
  cancel_btn_class  : 'btn-outline-warning'
}, custom_defaults);
```

The default settings for each type can be viewed in the `./src/js/defaults.js` file.

The special type `global`, if present, contains settings to be applied to all other types.

The optional `custom defaults` object can be used to set custom defaults, without needing 
to repeat them every time in the first options object.

### Customizing

See demo sources.

## TODO

* rivedere naming custom props (confusione tra color e bg, custom prrops specifiche per marks, marks size)
* custom props non su :root?
* aggiungere proprietà e opzioni per maggiore personalizzazione (padding, colori ecc) 
* terminare pagina di setup
* ottimizzare uso classi predefinite gestendole come variabili
npm package: @massimo-cassandro/stylelint-config
Description: my stylelint config
Author: Massimo Cassandro
Latest version: 2.3.4

# Stylelint config

My [stylelint](https://stylelint.io/) config,


## Use

Install package:

```bash
npm install -D stylelint @massimo-cassandro/stylelint-config
```

Create a `stylelint.config.mjs` file and add:

```javascript
export default {
  extends: [
    '@massimo-cassandro/stylelint-config',
  ],

  // Files to be ignored
  ignoreFiles: [
    'node_modules/**/*.{css,scss}',
    'vendor/**/*.{css,scss}',
    'templates/**/*.{css,scss}',
    'dist/**/*.css',
    'build/**/*.css',
    'public/**/*.css',
    'test/**/*.css'
  ],

  // Overrides
  rules: {
    //********************** optionally for tailwind:
    // 'at-rule-no-unknown': [
    //   true,
    //   'value-keyword-case': null,
    //   '@stylistic/number-no-trailing-zeros': null
    // ],
    //********************** /tailwind
  }
};
```
npm package: @massimo-cassandro/svg-icons-tools
Description: Optimize svg iocns (with SVGO) and generate SVG symbols file, JSX etc.
Author: Massimo Cassandro
Latest version: 1.3.0

# Svg Icons Tools

Svg Icons Tools provides some utilities for manage and optimize SVG icons:

* optimize all files with [SVGO](https://svgo.dev/)
* combine svg files into a single file, where each icon is wrapped within a `<symbol>` element (inspired from [svgstore](https://github.com/svgstore/svgstore)) 
* convert svg files to JSX
* copy optimized svg files to target directory
* removes *pallets* from the icon markups (see config file for more details).
* create a scss file with svg icons converted to sass variables
* jsx and optimized icons only: ability to manage both icons with `fill` and `stroke` adding optional classes to apply different css properties

These tools are pretty useless if you download your icons from one of the libraries you can find on the web, but if you design them yourself, *svg-icons-tools* can save you a lot of time in cleaning up and optimizing icons drawn with Illustrator, Figma, Sketch etc.

Also, most (or all) libraries only allow you to download icons with a fixed thickness, but you can often download "working" versions where thickness is defined by the stroke attribute. In these cases there is often a *pallet* that you can easily remove.

Read more in my [Building an Icon System in React](https://medium.com/better-programming/building-an-icon-system-in-react-16757d73cc35) article.

## Installation

```bash
npm i -D @massimo-cassandro/svg-icons-tools
```

## Setup

First, create a config file for you project, you can run:

```bash
npx iconsTools init
```

This creates a `svg-icons-tools` directory which contains the `svg-icons-tools.config.mjs` configuration file.

Rename the folder as you like and move it where you need. Then open and customize the `svg-icons-tools.config.mjs` file.

## Run

To launch the script, open your terminal and use the command:

```bash
npx iconsTools --config ./path/to/svg-icons-tools.config.mjs
```

where `--config` must contain the path, relative to the current dir, to the config file.

If the `--config` parameter is not set, the script will look for the configuration file in the current directory; if the file is not found, an error will be thrown.


## Configuration details

See [src/default-config.mjs](src/default-config.mjs) for more info.

## Demo

See [demo/readme](demo/readme.md).

## TODO
* documentation to jsdoc
* prettify the jsx output (update docs)
* SVG attributes to jsx (upd doc)
* option to clean-up dest folder for jsx and optimized (?)
* auto changelog


## Changelog / Breaking Changes

### 1.1
* added default jsx icon builder function

#### Breaking Changes
* in config file, `config.jsx.icon_builder` becomes `config.jsx.custom_icon_builder`, if not defined the default icon builder is used for jsx files.

### 1.0
* First production release
npm package: @massimopalmieri/react-session-debugger
Description: A session storage debugger component for React applications
Author: Massimo Palmieri
Latest version: 0.1.6

# React Session Debugger

A development tool for debugging session storage in React applications.

## Installation

```bash
npm install react-session-debugger
or
yarn add react-session-debugger
or
bun add react-session-debugger
```

## Usage

```tsx
import { SessionStorageDebugger } from "react-session-debugger";
import { z } from "zod";

// Optional: Define your own schema
const schema = z.object({
  name: z.string(),
  email: z.string().email(),
});

export default function App() {
  return (
    <div>
      {/* Your app content */}
      {process.env.NODE_ENV === "development" && (
        <SessionStorageDebugger
          schema={schema}
          defaultValue={{ name: "", email: "" }}
          storageKey="myData"
        />
      )}
    </div>
  );
}
```

## Props

- `schema`: (optional) A Zod schema for validating the JSON data
- `defaultValue`: (optional) Default value to show in the editor
- `storageKey`: (optional) Key to use for sessionStorage (default: "userData")

## Development

Only shows in development mode (`NODE_ENV === "development"`).
npm package: @massiveinfinity/contentschema
Description: Install the package by running
Author: massiveinfinity.com
Latest version: 0.0.0-alpha.5

# Getting Started

Install the package by running 

```bash
yarn add @massiveinfinity/contentschema
```
or if you are using _npm_: 
```bash
npm install --save @massiveinfinity/contentschema
```

# Usage

```javascript
import { helpers } from "@massiveinfinity/contentschema";

const v1Schema = {
  schemaVersion: 1,
  blocks: [...]
};

const v2Schema = helpers.migrate.v1ToV2(v1Schema);

console.log(v2Schema); // { schemaVersion: 2, blocks: [...] }

```

alternatively, you can import everything from the module into a module object: 

```javascript
import * as contentSchema from "@massiveinfinity/contentschema";

const v1Schema = {
  schemaVersion: 1,
  blocks: [...]
};

const v2Schema = contentSchema.helpers.migrate.v1ToV2(v1Schema);

console.log(v2Schema); // { schemaVersion: 2, blocks: [...] }

```

# API
* [constants](#constants)
    * [BLOCK_TYPE](#block_type)
    * [V1](#v1)
    * [V2](#v2)
    * [VERSION](#version)
* [helpers](#helpers)
    * [genId](#genId)
    * [migrate](#migrate)

## <a id="constants"></a> constants
### <a id="block_type"></a> BLOCK_TYPE

#### V1_BLOCK_TYPE
`constants.BLOCK_TYPE.V1_BLOCK_TYPE` constants

Block types in schema version 1.

| Constants     | Description   |
|---------------|---------------|
| SECTION       |               |
| DISCUSSION    |               |
| FEEDBACK      |               |
| BUBBLE        |               |
| OPEN          |               |

#### V2_BLOCK_TYPE
`constants.BLOCK_TYPE.V2_BLOCK_TYPE` constants

Block types in schema version 2.

| Constants     | Description   |
|---------------|---------------|
| SECTION       |               |
| SECTION_TITLE    |               |
| SECTION_DESCRIPTION      |               |
| SECTION_CONTENT        |               |
| DISCUSSION          |               |
| DISCUSSION_TITLE
| COMMENT_SECTION||
| COMMENT||
| FEEDBACK||
| FEEDBACK_TITLE||
| FEEDBACK_DESCRIPTION||
| RADIO_GROUP||
| RADIO||
| RADIO_TITLE||
| RADIO_DESCRIPTION||

### <a id="v1"></a> V1
#### BLOCK_TYPE
`constants.V1.BLOCK_TYPE` constants

Similar to `constants.BLOCK_TYPE.V1_BLOCK_TYPE`. 

### <a id="v2"></a> V2
#### BLOCK_TYPE
`constants.V2.BLOCK_TYPE` constants

Similar to `constants.BLOCK_TYPE.V2_BLOCK_TYPE`. 

### <a id="version"></a> VERSION
`constants.VERSION` constants

All schema version numbers. 

| Constants     | Description   |
|---------------|---------------|
| 1             | Version 1     |
| 2             | Version 2     |
| LATEST        | Latest schema version available |


## <a id="helpers"></a> helpers
### <a id="genId"></a> genId
`helpers.genId()` function

Used to generate ID for content block. 

__signature__
(blockType: _BLOCK_TYPE_, depth: _number_, index: _number_) => ID: _string_

### <a id="migrate"></a> migrate
#### v1ToV2
`helpers.migrate.v1ToV2()` function

Used to convert version 1 content schema to version 2 content schema. Returns version 2 content schema. 

__signature__
(v1ContentSchema: _contentSchema_) => v2ContentSchema: _contentSchema_
npm package: @massiveinfinity/sequelize-encrypted
Description: encrypted sequelize fields
Author: Massive Infinity Pte Ltd
Latest version: 1.0.3

# sequelize-encrypted

Encrypted fields for Sequelize ORM

```js
var Sequelize = require('sequelize');
var EncryptedField = require('sequelize-encrypted');

// secret key should be 32 bytes hex encoded (64 characters)
var key = process.env.SECRET_KEY_HERE;

var enc_fields = EncryptedField(Sequelize, key);

var User = sequelize.define('user', {
    name: Sequelize.STRING,
    encrypted: enc_fields.vault('encrypted'),

    // encrypted virtual fields
    private_1: enc_fields.field('private_1'),

    // Optional second argument allows you
    // to pass in a validation configuration
    // as well as an optional return type
    private_2: enc_fields.field('private_2', {
      type: Sequelize.TEXT,
      validate: {
        isInt: true  
      },
      defaultValue: null
    })
})

var user = User.build();
user.private_1 = 'test';
```

## How it works

The `safe` returns a sequelize BLOB field configured with getters/setters for decrypting and encrypting data. Encrypted JSON encodes the value you set and then encrypts this value before storing in the database.

Additionally, there are `.field` methods which return sequelize VIRTUAL fields that provide access to specific fields in the encrypted vault. It is recommended that these are used to get/set values versus using the encrypted field directly.

When calling `.vault` or `.field` you must specify the field name. This cannot be auto-detected by the module.

## Generating a key

By default, AES-SHA256-CBC is used to encrypt data. You should generate a random key that is 32 bytes.

```
openssl rand -hex 32
```

Do not save this key with the source code, ideally you should use an environment variable or other configuration injection to provide the key during app startup.

## Tips

You might find it useful to override the default `toJSON` implementation for your model to omit the encrypted field or other sensitive fields.

## License

MIT
npm package: @massiveinfinity/slo-autometrics
Description: Easily add metrics to your system -- and actually understand them using automatically customized Prometheus queries
Author: Fiberplane
Latest version: 1.0.1-mi.3

# `@autometrics/autometrics` 📈✨

This is the official TypeScript implementation for https://autometrics.dev/.

## Documentation

Full documentation for the `@autometrics/autometrics` library can be found here:
https://github.com/autometrics-dev/autometrics-ts

## Recipe: Server-side example with Prometheus

### Installation

```shell
# npm
npm install @autometrics/autometrics @autometrics/exporter-prometheus

# yarn
yarn add @autometrics/autometrics @autometrics/exporter-prometheus

# pnpm
pnpm add @autometrics/autometrics @autometrics/exporter-prometheus
```

### Usage

1. Anywhere in your source code:

```typescript
import { autometrics } from "@autometrics/autometrics";
import { init } from "@autometrics/exporter-prometheus";

init(); // starts the webserver with the `/metrics` endpoint on port 9464

async function createUserRaw(payload: User) {
  // ...
}

const createUser = autometrics(createUserRaw);
//    ^ instrumented function
```

## Recipe: Client-side example with the OpenTelemetry Collector

### Installation

```shell
# npm
npm install @autometrics/autometrics @autometrics/exporter-otlp-http

# yarn
yarn add @autometrics/autometrics @autometrics/exporter-otlp-http

# pnpm
pnpm add @autometrics/autometrics @autometrics/exporter-otlp-http
```

### Usage

1. Anywhere in your source code:

```typescript
import { autometrics } from "@autometrics/autometrics";
import { init } from "@autometrics/exporter-otlp-http";

init({ url: "https://<your-otel-collector>" });

async function createUserRaw(payload: User) {
  // ...
}

const createUser = autometrics(createUserRaw);
//    ^ instrumented function
```
npm package: @massiveinfinity/slo-exporter-prometheus
Description: Export metrics by pushing them to a Prometheus-compatible gateway
Author: Fiberplane
Latest version: 1.0.1-mi.3

# `@autometrics/exporter-prometheus`

Export metrics by opening up a Prometheus scrape endpoint.

This package will start a webserver on port 9464, with a Prometheus-compatible
`/metrics` endpoint.

You should configure your Prometheus instance to scrape this endpoint. For
instructions on how to do this, please refer to the Prometheus documentation:
https://prometheus.io/docs/prometheus/latest/configuration/configuration/#scrape_config

## Documentation

Full documentation for the `autometrics` library can be found here:
https://github.com/autometrics-dev/autometrics-ts.

## Installation

```shell
# npm
npm install @autometrics/autometrics @autometrics/exporter-prometheus

# yarn
yarn add @autometrics/autometrics @autometrics/exporter-prometheus

# pnpm
pnpm add @autometrics/autometrics @autometrics/exporter-prometheus
```

## Usage

1. Anywhere in your source code:

```typescript
import { autometrics } from "@autometrics/autometrics";
import { init } from "@autometrics/exporter-prometheus";

init(); // starts the webserver with the `/metrics` endpoint on port 9464

async function createUserRaw(payload: User) {
  // ...
}

const createUser = autometrics(createUserRaw);
   // ^ instrumented function
```
npm package: @massiveinfinity/slo-exporter-prometheus-push-gateway
Description: Export metrics by opening up a Prometheus scrape endpoint
Author: Fiberplane
Latest version: 1.0.1-mi.3

# `@autometrics/exporter-prometheus-push-gateway`

Export metrics by pushing them to a Prometheus-compatible push gateway.

For this exporter to work, you need to have a Prometheus-compatible push
gateway, such as: https://github.com/sinkingpoint/prometheus-gravel-gateway

## Documentation

Full documentation for the `autometrics` library can be found here:
https://github.com/autometrics-dev/autometrics-ts.

## Installation

```shell
# npm
npm install @autometrics/autometrics @autometrics/exporter-prometheus-push-gateway

# yarn
yarn add @autometrics/autometrics @autometrics/exporter-prometheus-push-gateway

# pnpm
pnpm add @autometrics/autometrics @autometrics/exporter-prometheus-push-gateway
```

## Usage

1. Anywhere in your source code:

```typescript
import { autometrics } from "@autometrics/autometrics";
import { init } from "@autometrics/exporter-prometheus-push-gateway";

init({ url: "https://<your-push-gateway>" });

async function createUserRaw(payload: User) {
  // ...
}

const createUser = autometrics(createUserRaw);
   // ^ instrumented function
```