{"id":21988860,"url":"https://github.com/indragunawan/facade-bundle","last_synced_at":"2025-07-18T09:33:24.076Z","repository":{"id":47411025,"uuid":"117192790","full_name":"IndraGunawan/facade-bundle","owner":"IndraGunawan","description":"Support Facades for Symfony service","archived":false,"fork":false,"pushed_at":"2022-06-13T10:41:18.000Z","size":17,"stargazers_count":17,"open_issues_count":1,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-07-01T06:45:47.148Z","etag":null,"topics":["facades","php","symfony","symfony-bundle"],"latest_commit_sha":null,"homepage":"","language":"PHP","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/IndraGunawan.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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":"2018-01-12T04:36:06.000Z","updated_at":"2022-06-13T10:41:22.000Z","dependencies_parsed_at":"2022-08-21T12:20:26.671Z","dependency_job_id":null,"html_url":"https://github.com/IndraGunawan/facade-bundle","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/IndraGunawan/facade-bundle","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IndraGunawan%2Ffacade-bundle","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IndraGunawan%2Ffacade-bundle/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IndraGunawan%2Ffacade-bundle/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IndraGunawan%2Ffacade-bundle/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/IndraGunawan","download_url":"https://codeload.github.com/IndraGunawan/facade-bundle/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IndraGunawan%2Ffacade-bundle/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263715325,"owners_count":23500241,"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":["facades","php","symfony","symfony-bundle"],"created_at":"2024-11-29T19:23:03.721Z","updated_at":"2025-07-05T09:04:51.191Z","avatar_url":"https://github.com/IndraGunawan.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# FacadeBundle\n\n[![license](https://img.shields.io/github/license/IndraGunawan/facade-bundle.svg?style=flat-square)](https://github.com/IndraGunawan/facade-bundle/blob/master/LICENSE.md)\n[![Travis](https://img.shields.io/travis/IndraGunawan/facade-bundle.svg?style=flat-square)](https://travis-ci.org/IndraGunawan/facade-bundle)\n[![Scrutinizer Coverage](https://img.shields.io/scrutinizer/coverage/g/IndraGunawan/facade-bundle.svg?style=flat-square)](https://scrutinizer-ci.com/g/IndraGunawan/facade-bundle/?branch=master)\n[![Scrutinizer](https://img.shields.io/scrutinizer/g/IndraGunawan/facade-bundle.svg?style=flat-square)](https://scrutinizer-ci.com/g/IndraGunawan/facade-bundle/?branch=master)\n[![Source](https://img.shields.io/badge/source-IndraGunawan%2Ffacade--bundle-blue.svg)](https://github.com/IndraGunawan/facade-bundle)\n[![Packagist](https://img.shields.io/badge/packagist-indragunawan%2Ffacade--bundle-blue.svg)](https://packagist.org/packages/indragunawan/facade-bundle)\n\nSupport Facades for Symfony service.\n\nthanks to:\n\n- [Service Locator](https://symfony.com/blog/new-in-symfony-3-3-service-locators) - for making all the referenced facade service lazy-loaded.\n- [Service Autoconfiguration](https://symfony.com/blog/new-in-symfony-3-3-service-autoconfiguration) - for making all classes that extend `Indragunawan\\FacadeBundle\\AbstractFacade` class automatically tagged as facade.\n\n## Documentation\n\n- [Installation](#installation)\n- [Creating Facade](#creating-facade)\n\n### Installation\n\nIf your project already uses Symfony Flex, execute this command to\ndownload, register and configure the bundle automatically:\n\n```bash\ncomposer require indragunawan/facade-bundle\n```\n\nIf you install without using Symfony Flex, first add the bundle by using composer then enable the bundle by adding `new Indragunawan\\FacadeBundle\\IndragunawanFacadeBundle()` to the list of registered bundles in the app/AppKernel.php file of your project\n\n### Creating Facade\n\nTo create a facade create a class that extends base `Indragunawan\\FacadeBundle\\AbstractFacade` class and implement the `getFacadeAccessor` method that returns the `service id`, support **private** and **public** service.\n\n```php\n\u003c?php\n\nnamespace App\\Facades;\n\nuse Indragunawan\\FacadeBundle\\AbstractFacade;\n\nclass Foo extends AbstractFacade\n{\n    protected static function getFacadeAccessor()\n    {\n        return 'App\\Service\\Foo'; // service id - supports private and public service.\n    }\n}\n```\n\nNow the facade now ready. Simply import the facade namespace. When you call any static method on the `Foo` facade, then it will resolve the service that you define in `getFacadeAccessor` method and call the requested method from the service.\n\n## License\n\nThis bundle is under the MIT license. See the complete [license](LICENSE)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Findragunawan%2Ffacade-bundle","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Findragunawan%2Ffacade-bundle","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Findragunawan%2Ffacade-bundle/lists"}