{"id":23507683,"url":"https://github.com/timesplinter/pimple-js","last_synced_at":"2025-05-13T00:40:53.695Z","repository":{"id":40420399,"uuid":"374993906","full_name":"TiMESPLiNTER/pimple-js","owner":"TiMESPLiNTER","description":"A simple DIC written in TypeScript based on PHP's Pimple","archived":false,"fork":false,"pushed_at":"2024-02-09T16:01:25.000Z","size":424,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-02-16T19:22:48.626Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","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/TiMESPLiNTER.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-06-08T12:02:58.000Z","updated_at":"2024-01-31T22:01:18.000Z","dependencies_parsed_at":"2022-08-09T20:00:18.102Z","dependency_job_id":null,"html_url":"https://github.com/TiMESPLiNTER/pimple-js","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TiMESPLiNTER%2Fpimple-js","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TiMESPLiNTER%2Fpimple-js/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TiMESPLiNTER%2Fpimple-js/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TiMESPLiNTER%2Fpimple-js/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TiMESPLiNTER","download_url":"https://codeload.github.com/TiMESPLiNTER/pimple-js/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253850841,"owners_count":21973667,"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":[],"created_at":"2024-12-25T10:34:01.699Z","updated_at":"2025-05-13T00:40:53.672Z","avatar_url":"https://github.com/TiMESPLiNTER.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# pimple-js\n\nBased on the work of\n\n* M.PARAISO \u003cmparaiso@online.fr\u003e\n* SerafimArts \u003cnesk@xakep.ru\u003e\n\nand the original PHP Pimple container by Fabien Potencier.\n\n## Usage\n\n```ts\nimport Pimple from '@timesplinter/pimple';\n\ntype ServiceMap = {\n   'foo': string, \n   'bar': string,\n};\n\nconst container: Container = new Pimple\u003cServiceMap\u003e({env: 'dev'});\n\ncontainer.set('foo', () =\u003e {\n    return `baz (${container.get('env')})`;\n});\n\ncontainer.set('bar', (container: Pimple\u003cServiceMap\u003e) =\u003e {\n    return `bar: ${container.get('foo')}`;\n});\n\nconsole.log(container.get('foo')); // 'bar (dev)';\n```\n\n## Transpiling\n```bash\n$ npm run transpile\n```\n\n## Tests\n```bash\n$ npm run test     # runs tests\n$ npm run coverage # runs coverage\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftimesplinter%2Fpimple-js","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftimesplinter%2Fpimple-js","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftimesplinter%2Fpimple-js/lists"}