Do you also hate all these dollars, arrows and $this everywhere in you PHP files? Well, PHP just isn't the sexiest one when compared to other languages. But still you're not going to switch language just because the syntax, right? Now you can switch syntax without leaving the language, meet LadyPHP!
LadyPHP is a preprocessor for PHP, that allows you to write code with cleaner syntax. It can do conversion in both ways, so you can start writing your current projects with lady syntax right away and save them back to PHP, your collaborators won't notice.
This software is still under heavy development, syntax and API can be changed.
|public f()||public function f()|
|[k: 'v']||['k' => 'v']|
|x ~ y||x . y|
Semicolons at the end of lines are optional.
To write operators
~, you have to escape them with
ladyphp file.lady # creates file.php ladyphp file.php # creates file.lady ladyphp -r dir/ # converts all php files in directory to ladyphp ladyphp -w dir/ # watches directory and converts updated lady files