# plugin-party

> Plugin mixin for reusable plugin pattern

Latest version **0.1.0** (published 2015-08-10) · MIT license · 0 weekly downloads

## Install

```sh
npm install plugin-party
pnpm add plugin-party
yarn add plugin-party
bun add plugin-party
```

## Health

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

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.0 |
| Published | 2015-08-10 |
| First published | 2015-08-09 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Known vulnerabilities | 0 (+6 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Robin Qu |
| Maintainers | robinqu |
| Keywords | plugin, mixin |

## Links

- npm: https://www.npmjs.com/package/plugin-party
- Repository: https://github.com/RobinQu/plugin-party
- Homepage: https://github.com/RobinQu/plugin-party#readme
- Issues: https://github.com/RobinQu/plugin-party/issues
- npm.io page: https://npm.io/package/plugin-party

## Dependencies (1)

- [lodash](https://npm.io/package/lodash.md) ^3.10.1

## Recent versions

- 0.1.0 (latest) — 2015-08-10
- 0.0.2 — 2015-08-09
- 0.0.1 — 2015-08-09

## README

# plugin-party

[![Build Status](https://travis-ci.org/RobinQu/plugin-party.svg?branch=master)](https://travis-ci.org/RobinQu/plugin-party)

A drop-in support for plugin mechanism.

## Usage

```
var installPlugin = require('plugin-party');


//Declare FooPlugin
var FooPlugin = function() {

};

//optional `configure` method
FooPlugin.prototype.configure = function(options) {

}

//Special properties on plugin class
FooPlugin.pluginType = 'foo';
FooPlugin.pluginName = 'bar';

//install plugin
var obj = {};
installPlugin(obj);

//register plugin
obj.register(FooPlugin);

//get a plugin instance
var plugin = obj.plugin('foo', 'bar');

//get again, with options
//as options are given, `configure` method is called
obj.plugin('foo', 'bar', {hello: 'world'});
```

More use case can be found in [test cases](test)

## License

MIT

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