Based on this SO question here is my implementation.
The solutions in the SO question does not use custuom validation rules.
The custom Rule is calling the global trans()
function. This is why it is in the helpers.php
and registered via Composer.
This trans()
function is also used to create the validator factory.
Here is fully working PHP SDK with my solution: https://github.com/TMRW-Life/ntak.guru-php-sdk