{"id":25518648,"url":"https://github.com/sxxov/is-stupid","last_synced_at":"2025-04-11T00:05:16.905Z","repository":{"id":57277607,"uuid":"330244147","full_name":"sxxov/is-stupid","owner":"sxxov","description":"Roses are red, you are stupid","archived":false,"fork":false,"pushed_at":"2021-01-16T21:23:38.000Z","size":61,"stargazers_count":8,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-11T00:05:03.964Z","etag":null,"topics":["bruh","is-odd","is-true","is-useless","jsfuck","meme"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sxxov.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-01-16T19:50:58.000Z","updated_at":"2025-02-03T23:10:30.000Z","dependencies_parsed_at":"2022-09-11T19:51:15.448Z","dependency_job_id":null,"html_url":"https://github.com/sxxov/is-stupid","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sxxov%2Fis-stupid","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sxxov%2Fis-stupid/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sxxov%2Fis-stupid/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sxxov%2Fis-stupid/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sxxov","download_url":"https://codeload.github.com/sxxov/is-stupid/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248317707,"owners_count":21083528,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bruh","is-odd","is-true","is-useless","jsfuck","meme"],"created_at":"2025-02-19T16:54:08.206Z","updated_at":"2025-04-11T00:05:16.883Z","avatar_url":"https://github.com/sxxov.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Is stupid [![npm version](https://badge.fury.io/js/is-stupid.svg)](https://badge.fury.io/js/is-stupid)\r\n\r\n```\r\nA package to figure out if one is stupid.\r\n```\r\n\r\n\r\n\r\n## Get Started\r\n\r\n### Installation\r\n\r\n1. Install using `npm` :\r\n\r\n   ```bash\r\n   npm i is-stupid\r\n   ```\r\n\r\n2. Install using `yarn`:\r\n\r\n   ```bash\r\n   yarn install is-stupid\r\n   ```\r\n\r\n3. With `Deno`:\r\n\r\n   ```js\r\n   import isStupid from 'https://unpkg.com/is-stupid/dist/index.js'\r\n   ```\r\n\r\n   \r\n\r\n### Basic Usage\r\n\r\nThis package uses both default exports and named exports, as such, it requires ES modules to be used.\r\n\r\nFor modern environments with ES module support (such as `typescript`, or usage with bundlers):\r\n\r\n```js\r\nimport isStupid from 'is-stupid';\r\n\r\nif (isStupid) {\r\n    console.log('oh no');\r\n}\r\n```\r\n\r\nIn CommonJS environments (such as Node), you may use [`esm`](https://www.npmjs.com/package/esm) to import it:\r\n\r\n```js\r\nconst isStupid = require('esm')(module)('is-stupid');\r\n```\r\n\r\n\r\n\r\n## API\r\n\r\n### [default]: `boolean`\r\n\r\nA pre-calculated value for performance reasons.\r\n\r\n```js\r\nimport isStupid from 'is-stupid';\r\n\r\nisStupid;\r\n```\r\n\r\n\r\n\r\n### recalculate: `() =\u003e boolean`\r\n\r\nDo calculation during runtime for maximum accuracy.\r\n\r\n```js\r\nimport { recalculate } from 'is-stupid';\r\n\r\nrecalculate();\r\n```\r\n\r\n\r\n\r\n### smartRecalculate: `() =\u003e StupidItem`\r\n\r\nUse heuristics, as well as additional utility functions. Can be slower than above functions.\r\n\r\n```js\r\nimport { smartRecalculate } from 'is-stupid';\r\n\r\nsmartRecalculate();\r\n```\r\n\r\n\r\n\r\n### StupidItem: `class extends Boolean`\r\n\r\nAn item wrapping around `Boolean` to provide further functionality.\r\n\r\n#### StupidItem.IS_SURE: `boolean`\r\n\r\nA variable indicating how sure the item is.\r\n\r\n```js\r\nStupidItem.IS_SURE\r\n```\r\n\r\n#### StupidItem.prototype.isSureAboutBeingSure: `() =\u003e boolean`\r\n\r\nAttempt to persuade the item.\r\n\r\n```js\r\nsmartRecalculate()\r\n    .isSureAboutBeingSure()\r\n```\r\n\r\n#### StupidItem.prototype.takeSomeTimeToRethinkIsSure: `() =\u003e Promise\u003cboolean\u003e`\r\n\r\nAsynchronously give time for the item to think about it.\r\n\r\n```js\r\nawait smartRecalculate()\r\n    .takeSomeTimeToRethinkIsSure()\r\n```\r\n\r\n#### StupidItem.prototype.takeSomeTimeToRethinkIsSureSync: `() =\u003e boolean`\r\n\r\nSynchronously give time for the item to think about it.\r\n\r\n```js\r\nawait smartRecalculate()\r\n    .takeSomeTimeToRethinkIsSureSync()\r\n```\r\n\r\n#### StupidItem.prototype[Symbol.toPrimitive]: `() =\u003e boolean`\r\n\r\nConverts the item to a primitive.\r\n\r\n```js\r\nstupidItem[Symbol.toPrimitive]()\r\n```\r\n\r\n\r\n\r\n\r\n\r\n## Testing\r\n\r\nInstall dev-dependencies, then test:\r\n\r\n```bash\r\n$ npm i -D \u0026\u0026 npm t\r\n```\r\n\r\n\r\n\r\n## Contributing\r\n\r\nPull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/sxxov/is-stupid/issues/new).\r\n\r\n\r\n\r\n## Author\r\n\r\n**Jason Lim**\r\n\r\n* [github.com/sxxov](https://github.com/sxxov)\r\n* [twitter.com/_sxxov](https://twitter.com/_sxxov)\r\n\r\n\r\n\r\n## License\r\n\r\nCopyright © 2021 Jason Lim. Released under the WTFPL license.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsxxov%2Fis-stupid","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsxxov%2Fis-stupid","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsxxov%2Fis-stupid/lists"}