# @qiwi/module-federation-manifest-plugin

> Module Federation manifest plugin

Latest version **1.1.2** (published 2023-11-29) · MIT license · 0 weekly downloads

## Install

```sh
npm install @qiwi/module-federation-manifest-plugin
pnpm add @qiwi/module-federation-manifest-plugin
yarn add @qiwi/module-federation-manifest-plugin
bun add @qiwi/module-federation-manifest-plugin
```

## Health

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

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

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.1.2 |
| Published | 2023-11-29 |
| First published | 2022-11-22 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 2 |
| Unpacked size | 94.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 2 |
| Maintainers | antongolub, qiwibot, pismenskiy |
| Keywords | federation, module-federation, manifest, webpack, plugin |

## Links

- npm: https://www.npmjs.com/package/@qiwi/module-federation-manifest-plugin
- Repository: https://github.com/qiwi/module-federation-manifest-plugin
- Homepage: https://github.com/qiwi/module-federation-manifest-plugin/#readme
- Issues: https://github.com/qiwi/module-federation-manifest-plugin/issues
- npm.io page: https://npm.io/package/@qiwi/module-federation-manifest-plugin

## Dependencies (2)

- [tslib](https://npm.io/package/tslib.md) ^2.4.0
- [tapable](https://npm.io/package/tapable.md) ^2.2.1

## Alternatives

- [raw-loader](https://npm.io/package/raw-loader.md) — 4.3M weekly downloads
- [plop](https://npm.io/package/plop.md) — 1.4M weekly downloads
- [webpack-deadcode-plugin](https://npm.io/package/webpack-deadcode-plugin.md) — 80.3K weekly downloads
- [@storybook/preact-vite](https://npm.io/package/@storybook/preact-vite.md) — 54.2K weekly downloads
- [vite-plugin-transform](https://npm.io/package/vite-plugin-transform.md) — 2.4K weekly downloads

## Recent versions

- 1.1.2 (latest) — 2023-11-29
- 1.1.1 — 2023-11-22
- 1.1.0 — 2022-11-28
- 1.0.3 — 2022-11-25
- 1.0.2 — 2022-11-22
- 1.0.1 — 2022-11-22
- 1.0.0 — 2022-11-22

## README

# module-federation-manifest-plugin

[![CI](https://github.com/qiwi/module-federation-manifest-plugin/actions/workflows/ci.yaml/badge.svg?branch=master)](https://github.com/qiwi/module-federation-manifest-plugin/actions/workflows/ci.yaml)
[![Maintainability](https://api.codeclimate.com/v1/badges/b393ef93cb69397b2738/maintainability)](https://codeclimate.com/github/qiwi/module-federation-manifest-plugin/maintainability)
[![Test Coverage](https://api.codeclimate.com/v1/badges/b393ef93cb69397b2738/test_coverage)](https://codeclimate.com/github/qiwi/module-federation-manifest-plugin/test_coverage)
[![npm (tag)](https://img.shields.io/npm/v/@qiwi/module-federation-manifest-plugin/latest.svg)](https://www.npmjs.com/package/@qiwi/module-federation-manifest-plugin)

> Webpack plugin to generate manifest about module federation: shared, exposed, remote modules

### Install

```bash
yarn add -D @qiwi/module-federation-manifest-plugin
npm i -D @qiwi/module-federation-manifest-plugin
```

### Usage

Add plugin to webpack config. This plugin works together with `ModuleFederationPlugin`. In case of usage without it error will be raised

```typescript
import webpack from 'webpack'
import path from 'path'
import { ModuleFederationManifestPlugin } from '@qiwi/module-federation-manifest-plugin'

export const config: webpack.Configuration = {
  plugins: [
    new webpack.container.ModuleFederationPlugin({
      /** Your options here */
    }),
    new ModuleFederationManifestPlugin({
      filename: 'manifest.json',
    }),
  ],
}
```

## Manifest schema

You can find schema description [here](https://github.com/qiwi/module-federation-manifest-plugin/blob/main/src/main/ts/schema.ts) and real examples in [tests](https://github.com/qiwi/module-federation-manifest-plugin/blob/main/src/test/ts/e2e.spec.ts)

## API

### Hooks

#### onManifestCreated

Invokes after manifest created, but not emitted

```javascript
compiler.hooks.compilation.tap('MyPlugin', (compilation) => {
  ModuleFederationManifestPlugin.getHooks(compilation).onManifestCreated.tap('MyPlugin', (manifest) => {
    console.log(manifest)
  })
})
```

## License

[MIT](./LICENSE)

---
_Source: https://npm.io/package/@qiwi/module-federation-manifest-plugin · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
