# @ghii/http-loader

> A Funny http loader for ghii configuration manager

Latest version **1.0.0** (published 2026-05-05) · MIT license · 0 weekly downloads

## Install

```sh
npm install @ghii/http-loader
pnpm add @ghii/http-loader
yarn add @ghii/http-loader
bun add @ghii/http-loader
```

## Health

**Score 65/100 (B)** — status: active.

Positive: has types; esm support; no vulnerabilities; has provenance; high quality score.

Warnings: low downloads.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2026-05-05 |
| First published | 2020-12-16 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=18.0.0 |
| Dependencies | 0 |
| Unpacked size | 10.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Provenance | attested (GitHub Actions) |
| GitHub stars | 8 |
| Author | Daniele Fiungo |
| Maintainers | daniele.fiungo, irenelb, nicola.vurchio |
| Keywords | node, config |

## Links

- npm: https://www.npmjs.com/package/@ghii/http-loader
- Repository: https://github.com/iad-os/ghii-http-loader
- Homepage: https://github.com/iad-os/ghii-http-loader#readme
- Issues: https://github.com/iad-os/ghii-http-loader/issues
- npm.io page: https://npm.io/package/@ghii/http-loader

## Alternatives

- [jsforce](https://npm.io/package/jsforce.md) — 851.2K weekly downloads
- [react-native-qrcode-svg](https://npm.io/package/react-native-qrcode-svg.md) — 693.5K weekly downloads
- [@salesforce/plugin-data](https://npm.io/package/@salesforce/plugin-data.md) — 394.9K weekly downloads
- [@backstage/plugin-search-common](https://npm.io/package/@backstage/plugin-search-common.md) — 308.5K weekly downloads
- [@chain-registry/types](https://npm.io/package/@chain-registry/types.md) — 38.4K weekly downloads

## Recent versions

- 1.0.0 (latest) — 2026-05-05
- 0.0.8 — 2023-01-25
- 0.0.7 — 2023-01-24
- 0.0.6 — 2022-11-30
- 0.0.5 — 2022-11-30
- 0.0.4 — 2020-12-17
- 0.0.3 — 2020-12-17
- 0.0.2 — 2020-12-16
- 0.0.1 — 2020-12-16

## README

# GHII - HTTP LOADER

Http loader is a [ghii](https://github.com/iad-os/ghii) loader. It is used to load the configurations of a nodejs application by calling an endpoint which returns a json with the configurations to be injected into the application.

## How to install:

```sh
npm install @ghii/http-loader
```

Configuration in yaml:

```yaml
env: development
app:
  version: "0.0.1"
  name: "ghii-test"

```

in JSON:

```json
{
  "env": "development",
  "app": {
    "version": "0.0.1",
    "name": "ghii-test"
  }
}
```

## Usage example:

```TypeScript
import ghii from "@ghii/ghii";
import httpLoader from "@ghii/http-loader";

const options = ghii((T) =>
  T.Object({
    env: T.Union([T.Literal("development"), T.Literal("production")], {
      default: "development",
    }),
    app: T.Object(
      {
        name: T.String({ default: "test" }),
        version: T.String(),
      },
      { additionalProperties: false, default: {} }
    ),
  })
).loader(
  //example url http://localhost:4000/.wellknown.json
  httpLoader(process.env.WELLKNOWN_URL!, {
    throwOnError:  process.env.NODE_ENV !== 'development', //silent mode
    logger: (err, msg) => {
      if (err) {
        customLogger.error(err, msg);
      } else {
        customLogger.debug(msg);
      }
    },
  })
);

export default options;
```

## Related

- [ghii](https://github.com/iad-os/ghii)
- [ghii-yaml-loader](https://github.com/iad-os/ghii-yaml-loader)
- [ghii-envs-loader](https://github.com/iad-os/ghii-envs-loader)
- [ghii-package- json-loader](https://github.com/iad-os/ghii-package-json-loader)

---
_Source: https://npm.io/package/@ghii/http-loader · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
