Find a file
RenovateBot 8c440c0539
All checks were successful
continuous-integration/drone/push Build is passing
Update dependency np to v9 (#135)
This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [np](https://github.com/sindresorhus/np) | devDependencies | major | [`^8.0.0` -> `^9.0.0`](https://renovatebot.com/diffs/npm/np/8.0.4/9.2.0) |

---

### Release Notes

<details>
<summary>sindresorhus/np (np)</summary>

### [`v9.2.0`](https://github.com/sindresorhus/np/releases/tag/v9.2.0)

[Compare Source](https://github.com/sindresorhus/np/compare/v9.1.0...v9.2.0)

-   Fix yarn npm publish for scoped packages  [`8d3a984`](https://github.com/sindresorhus/np/commit/8d3a984)
-   Fix broken revert code after publish failure  [`819ed29`](https://github.com/sindresorhus/np/commit/819ed29)

### [`v9.1.0`](https://github.com/sindresorhus/np/releases/tag/v9.1.0)

[Compare Source](https://github.com/sindresorhus/np/compare/v9.0.0...v9.1.0)

-   Add Yarn Berry support ([#&#8203;723](https://github.com/sindresorhus/np/issues/723))  [`0d9522b`](https://github.com/sindresorhus/np/commit/0d9522b)

### [`v9.0.0`](https://github.com/sindresorhus/np/releases/tag/v9.0.0)

[Compare Source](https://github.com/sindresorhus/np/compare/v8.0.4...v9.0.0)

##### Breaking

-   Require Node.js 18 and npm 9  [`6c2e00e`](https://github.com/sindresorhus/np/commit/6c2e00e)

##### Improvements

-   Group unpublished files in folders ([#&#8203;716](https://github.com/sindresorhus/np/issues/716))  [`c31c2bc`](https://github.com/sindresorhus/np/commit/c31c2bc)
-   improve messages related to new files and dependencies ([#&#8203;702](https://github.com/sindresorhus/np/issues/702))  [`ad7b09e`](https://github.com/sindresorhus/np/commit/ad7b09e)

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box

---

This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4wLjAiLCJ1cGRhdGVkSW5WZXIiOiIzNy4wLjAiLCJ0YXJnZXRCcmFuY2giOiJkZXZlbG9wIn0=-->

Reviewed-on: https://gitea.vylpes.xyz/RabbitLabs/random-bunny/pulls/135
Co-authored-by: Renovate Bot <renovate@vylpes.com>
Co-committed-by: Renovate Bot <renovate@vylpes.com>
2024-01-16 19:15:10 +00:00
.gitea Add Gitea templates 2023-02-24 17:33:39 +00:00
.github Create FUNDING.yml 2021-05-10 21:50:20 +01:00
.gitlab Update default.md 2021-01-15 18:15:14 +00:00
src Add higher limit on json (#139) 2024-01-12 17:48:37 +00:00
tests Add higher limit on json (#139) 2024-01-12 17:48:37 +00:00
.drone.yml Add push event to .drone.yml 2023-04-29 14:43:47 +01:00
.eslintignore Setup Jest (#57) 2023-04-22 13:20:30 +01:00
.eslintrc Setup Jest (#57) 2023-04-22 13:20:30 +01:00
.gitignore Add error codes and error messages to failed results (#89) 2023-09-15 15:18:57 +01:00
.gitlab-ci.yml Add aslant to gitlab project ci 2021-01-13 21:08:47 +00:00
.npmignore Setup Jest (#57) 2023-04-22 13:20:30 +01:00
CODE_OF_CONDUCT.md Update documentation with up to date information 2022-08-18 17:45:05 +01:00
CONTRIBUTING.md Fix documentation code breaks (#58) 2023-04-28 17:31:34 +01:00
jest.config.cjs Setup Jest (#57) 2023-04-22 13:20:30 +01:00
jest.setup.js Setup Jest (#57) 2023-04-22 13:20:30 +01:00
LICENSE Update licence copyright to 2023 (#59) 2023-04-28 17:31:55 +01:00
package.json Update dependency np to v9 (#135) 2024-01-16 19:15:10 +00:00
readme.md Updatr documentation to remove maxTries variable 2023-02-22 18:19:47 +00:00
renovate.json Update 'renovate.json' 2022-12-28 18:43:41 +00:00
tsconfig.json Setup Jest (#57) 2023-04-22 13:20:30 +01:00
yarn.lock Update dependency np to v9 (#135) 2024-01-16 19:15:10 +00:00

random-bunny

Get a random image url from a subreddit of your choosing.

Install

npm install --save random-bunny

or if you're using yarn

yarn add random-bunny

Usage

import randomBunny from "random-bunny";

// ... In an async function
const result = await randomBunny('rabbits', 'hot');
console.log(result);

API

randomBunny()

Returns a json string for a random post. Accepts 2 arguments: subreddit, and sortby ('new', 'hot', 'top')

The json string which gets returned consists of:

  • archived
  • downs
  • hidden
  • permalink
  • subreddit
  • subredditSubscribers
  • title
  • ups
  • url

sortBy will default to 'hot' if not given or invalid

Notes

License

MIT © Vylpes