{"id":18602220,"url":"https://github.com/codebyzach/sublime_php_constructors","last_synced_at":"2025-05-16T17:34:39.678Z","repository":{"id":66144435,"uuid":"163695729","full_name":"CodeByZach/sublime_php_constructors","owner":"CodeByZach","description":"Sublime plugin to auto generate PHP constructors based on the class attributes.","archived":false,"fork":false,"pushed_at":"2023-07-09T17:54:27.000Z","size":25,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-02-18T01:40:12.542Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/CodeByZach.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-12-31T20:27:43.000Z","updated_at":"2021-10-19T21:13:22.000Z","dependencies_parsed_at":"2024-11-07T02:10:58.145Z","dependency_job_id":"75cc08ad-282e-4098-889a-0e2c16a7f4b5","html_url":"https://github.com/CodeByZach/sublime_php_constructors","commit_stats":null,"previous_names":[],"tags_count":12,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CodeByZach%2Fsublime_php_constructors","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CodeByZach%2Fsublime_php_constructors/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CodeByZach%2Fsublime_php_constructors/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CodeByZach%2Fsublime_php_constructors/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CodeByZach","download_url":"https://codeload.github.com/CodeByZach/sublime_php_constructors/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254576846,"owners_count":22094471,"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-11-07T02:10:52.190Z","updated_at":"2025-05-16T17:34:39.658Z","avatar_url":"https://github.com/CodeByZach.png","language":"Python","readme":"# PHP Constructors\n[![Latest Release](https://img.shields.io/github/tag/CodeByZach/sublime_php_constructors.svg?label=version)](https://github.com/CodeByZach/sublime_php_constructors/releases)\n\nPHP Constructors is a Sublime Text plug-in that generates PHP class constructors, automagically.\n\n## Features:\n* Generate class constructor.\n* Description, type and var name automatically discovered from the variable docblock.\n\n## Usage Instruction:\n1. Write your class properties inside your PHP class:\n\n```\nclass test\n{\n\t/**\n\t * @var my\\long\\namespace Var that holds foo\n\t */\n\tprivate $foo;\n}\n```\n\n2. Go to _Tools \u003e Packages \u003e PHP Constructors_\n3. Select _Generate PHP Constructor for Class_\n\n```\nclass test\n{\n\t/**\n\t * @var my\\long\\namespace Var that holds foo\n\t */\n\tprivate $foo;\n\n\t/**\n\t * Class Constructor\n\t * @param my\\long\\namespace   $foo    Var that holds foo\n\t */\n\tpublic function __construct($foo)\n\t{\n\t\t$this-\u003efoo = $foo;\n\t}\n}\n```\n\nTake some time to document your class properties with in following format:\n\n```\nclass test\n{\n\t/**\n\t * @var varType Description of the var\n\t */\n\tprivate $foo;\n}\n```\n\n## Commands\n\nCommands available are:\n\n* Generate PHP Constructor for Class\n\nThis command can be accessed via the _Tools \u003e Packages \u003e PHP Constructors_ or via the Command Palette.\n\n## Available Settings\n\n#### optional_constructor_params\n_type_   : **boolean**\n\n_default_: **false**\n\n_description_: If set to true, constructors will be generated with optional parameters.\n\n#### ignore_visibility_notation\n_type_   : **boolean**\n\n_default_: **false**\n\n_description_: If set to true, will omit underscore prefix common on private variables for constructor parameters.\n\n#### parameter_as_array\n_type_   : **boolean**\n\n_default_: **false**\n\n_description_: If set to true, will pass all parameters to the constructor in a single array.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodebyzach%2Fsublime_php_constructors","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcodebyzach%2Fsublime_php_constructors","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodebyzach%2Fsublime_php_constructors/lists"}