forked from hackaugusto/jade.php
-
Notifications
You must be signed in to change notification settings - Fork 11
Open
Description
I am running into many problems with the automatic variable name substitution, and start to believe it's not a good idea to do this. For example, this code is causing issues:
open = pages->findOpen()
items = open ? open->children()->visible() : falseThis gets wrongly translated to:
$__=$pages->findOpen();
$open = $__
$__=$open ? open->children()->visible() : false;
$items = $__
?>As you can see, in the second statement, the second occurrence of open does not get replaced.
I have therefore created my own version of jade.php that removes this variable translation, and explicitly use the $-sign in the templates: https://github.com/lehni/jade.php
Don't you think this would make more sense for a PHP based Jade? I am wondering what the official take is on these kind of problems?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels