# memegen-m2k

> Generate Memes with the help of APIMeme Meme Generator

Latest version **1.0.2** (published 2024-12-07) · MIT license · 0 weekly downloads

## Install

```sh
npm install memegen-m2k
pnpm add memegen-m2k
yarn add memegen-m2k
bun add memegen-m2k
```

## Health

**Score 35/100 (D)** — status: maintenance-mode.

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

Warnings: low downloads; no esm support.

Negative: stale; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.2 |
| Published | 2024-12-07 |
| First published | 2024-04-07 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 28.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | M2K Developments |
| Maintainers | m2kdevelopments |
| Keywords | memegen, memes, generate, api, memegenerator |

## Links

- npm: https://www.npmjs.com/package/memegen-m2k
- Repository: https://github.com/M2KDevelopments/memegen
- Homepage: https://github.com/M2KDevelopments/memegen#readme
- Issues: https://github.com/M2KDevelopments/memegen/issues
- npm.io page: https://npm.io/package/memegen-m2k

## Dependencies (1)

- [typescript](https://npm.io/package/typescript.md) ^5.7.2

## Recent versions

- 1.0.2 (latest) — 2024-12-07
- 1.0.1 — 2024-12-07
- 1.0.0 — 2024-04-07

## README

# Memegen

Generate Memes with the help of API Meme Meme Generator.
Support the official API website <a href="https://apimeme.com/?ref=apilist.fun">here.</a>

<a href="https://www.buymeacoffee.com/m2kdevelopments" target="_blank">
<img src="https://cdn.buymeacoffee.com/buttons/v2/default-yellow.png" alt="Buy Me A Coffee" style="height: 60px !important;width: 217px !important;" />
</a>


## Installation
```
npm i memegen-m2k --save
```
or 
```
yarn add memegen-m2k
```


# How to use

## Import Library
```
const MemeGen = require('memegen-m2k');
```

## Get All the meme options
```
console.log(MemeGen.getMemeOptions().length)
```

## Generate Meme Image URL
```
const list = MemeGen.getMemeOptions();
const index = parseInt(Math.random() * list.length);
const meme = list[index]; // Pick one at random 

// top and bottom text of the meme
const topText = "When she says no"
const topBottom = "When he says no" 

// print out image link of the meme
console.log(MemeGen.generate(meme, topText, topBottom))
```

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