{"id":28899245,"url":"https://github.com/skie/rule-flow","last_synced_at":"2025-07-23T14:34:43.703Z","repository":{"id":298734395,"uuid":"1000939634","full_name":"skie/rule-flow","owner":"skie","description":"CakePHP plugin for automatic server-to-client validation rule transformation using JSON Logic. Zero-config real-time form validation with custom rule support.","archived":false,"fork":false,"pushed_at":"2025-06-13T08:02:11.000Z","size":183,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-06-21T08:08:47.726Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/skie.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-06-12T14:54:31.000Z","updated_at":"2025-06-13T08:02:14.000Z","dependencies_parsed_at":"2025-06-12T15:50:51.626Z","dependency_job_id":"ddb3c003-7359-448c-9726-b03984edcd35","html_url":"https://github.com/skie/rule-flow","commit_stats":null,"previous_names":["skie/rule-flow"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/skie/rule-flow","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/skie%2Frule-flow","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/skie%2Frule-flow/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/skie%2Frule-flow/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/skie%2Frule-flow/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/skie","download_url":"https://codeload.github.com/skie/rule-flow/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/skie%2Frule-flow/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266694573,"owners_count":23969795,"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","status":"online","status_checked_at":"2025-07-23T02:00:09.312Z","response_time":66,"last_error":null,"robots_txt_status":null,"robots_txt_updated_at":null,"robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":"2025-06-21T08:08:47.475Z","updated_at":"2025-07-23T14:34:43.694Z","avatar_url":"https://github.com/skie.png","language":"PHP","funding_links":[],"categories":["Filtering and Validation","Plugins"],"sub_categories":["Filtering and Validation"],"readme":"# RuleFlow Plugin for CakePHP\n\n[![Latest Stable Version](https://img.shields.io/packagist/v/skie/rule-flow.svg)](https://packagist.org/packages/skie/rule-flow)\n[![Total Downloads](https://img.shields.io/packagist/dt/skie/rule-flow.svg)](https://packagist.org/packages/skie/rule-flow)\n[![License](https://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat-square)](LICENSE.txt)\n[![Build Status](https://img.shields.io/github/actions/workflow/status/skie/rule-flow/ci.yml?branch=master)](https://github.com/skie/rule-flow/actions)\n\nA CakePHP plugin that seamlessly transforms server-side validation rules into client-side JSON Logic validation, providing automatic form validation without requiring separate client-side validation code.\n\n## Features\n\n- **Automatic Rule Transformation**: Converts CakePHP validation rules to JSON Logic format\n- **Real-time Validation**: Client-side validation with immediate feedback\n- **Custom Rules Support**: Extend with custom PHP rules and JavaScript functions\n- **Dynamic Forms**: Support for dynamically added form fields\n- **Zero Configuration**: Works automatically with enhanced FormHelper\n- **Cross-Platform Patterns**: Consistent regex validation between PHP and JavaScript\n\n## Quick Start\n\n### Installation\n\n```bash\ncomposer require skie/rule-flow\n```\n\n### Basic Usage\n\n**1. Load the plugin in your CakePHP application:**\n\n```php\n// In config/bootstrap.php or Application.php\n$this-\u003eaddPlugin('RuleFlow');\n```\n\n**2. Use in your controller:**\n\n```php\n// Load the component\npublic function initialize(): void\n{\n    parent::initialize();\n    $this-\u003eloadComponent('RuleFlow.Rule');\n}\n\n// Configure validation rules for forms\npublic function add()\n{\n    $article = $this-\u003eArticles-\u003enewEmptyEntity();\n    $this-\u003eRule-\u003econfigureFormRules($this-\u003eArticles);\n    $this-\u003eset(compact('article'));\n}\n```\n\n**3. Use enhanced FormHelper in your view:**\n\n```php\n// In src/View/AppView.php\npublic function initialize(): void\n{\n    parent::initialize();\n    $this-\u003eloadHelper('RuleFlow.Form');\n}\n```\n\n**4. Create forms with automatic validation:**\n\n```php\n\u003c?= $this-\u003eForm-\u003ecreate($article) ?\u003e\n\u003c?= $this-\u003eForm-\u003econtrol('title') ?\u003e\n\u003c?= $this-\u003eForm-\u003econtrol('content') ?\u003e\n\u003c?= $this-\u003eForm-\u003ebutton('Submit') ?\u003e\n\u003c?= $this-\u003eForm-\u003eend() ?\u003e\n```\n\nThat's it! Your forms now have automatic client-side validation based on your CakePHP validation rules.\n\n## Documentation\n\n### Core Documentation\n- **[Plugin Documentation](docs/RuleFlow-Plugin-Documentation.md)** - Complete guide to using the plugin\n- **[JsonLogic Operations Reference](docs/JsonLogic-Operations-Reference.md)** - All available JsonLogic operations\n\n### Advanced Guides\n- **[Custom Rules Guide](docs/custom-rules-guide.md)** - Creating custom validation rules and functions\n- **[Regex Compatibility Guide](docs/regex-compatibility.md)** - Cross-platform regex patterns\n\n## Requirements\n\n- **PHP**: 8.3+\n- **CakePHP**: 4.5+\n- **Browser**: Modern browsers with ES6+ support\n\n## Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request.\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n## Links\n\n- [Packagist](https://packagist.org/packages/skie/rule-flow)\n- [GitHub Repository](https://github.com/skie/rule-flow)\n- [Issues](https://github.com/skie/rule-flow/issues)\n- [JSON Logic](http://jsonlogic.com/) - The underlying rule engine\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fskie%2Frule-flow","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fskie%2Frule-flow","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fskie%2Frule-flow/lists"}