{"id":16760330,"url":"https://github.com/ryanve/modder","last_synced_at":"2025-06-19T19:39:19.237Z","repository":{"id":27636854,"uuid":"31121451","full_name":"ryanve/modder","owner":"ryanve","description":"JavaScript: mod your modules","archived":false,"fork":false,"pushed_at":"2017-02-18T05:48:37.000Z","size":6,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"gh-pages","last_synced_at":"2025-06-13T05:57:09.219Z","etag":null,"topics":["coupling","hooks","javascript","modularity"],"latest_commit_sha":null,"homepage":"http://ryanve.dev/modder/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ryanve.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-02-21T10:00:56.000Z","updated_at":"2024-02-04T18:31:02.000Z","dependencies_parsed_at":"2022-08-01T11:37:35.080Z","dependency_job_id":null,"html_url":"https://github.com/ryanve/modder","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/ryanve/modder","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanve%2Fmodder","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanve%2Fmodder/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanve%2Fmodder/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanve%2Fmodder/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ryanve","download_url":"https://codeload.github.com/ryanve/modder/tar.gz/refs/heads/gh-pages","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanve%2Fmodder/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260817965,"owners_count":23067623,"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":["coupling","hooks","javascript","modularity"],"created_at":"2024-10-13T04:23:08.822Z","updated_at":"2025-06-19T19:39:14.225Z","avatar_url":"https://github.com/ryanve.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# modder\n\u003cb\u003emodder\u003c/b\u003e is get/set interface for sharing functions and hooking custom behavior into JavaScript modules that provide hooks to do so. It lets you define an interface without implementing all the behavior at once or at all.\n\n```\nnpm install modder --save\n```\n\n## API\n\n### `modder(name?, value?)`\n- `modder(name)` get\n- `modder(name, value)` set\n\n#### example\n\n```js\n// define some API and provide a hook for overloading\nvar api = {\n  riot: function(size) {\n    if (size \u003e 1000) require('modder')('evacuate').call(this)\n    else this.chill()\n  }\n  chill: function() {\n  }\n}\n\n// implement behavior later\nvar modder = require('modder')\nmodder('evacuate', function() {\n  // follow evacuation procedure\n})\n```\n\n#### instances\n\nIf you need multiple `modder` instances:\n\n```js\nvar modder1 = modder()\nvar modder2 = modder()\n```\n\n## License\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fryanve%2Fmodder","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fryanve%2Fmodder","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fryanve%2Fmodder/lists"}