Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixed problem with widgets variable access
Previously, widgets were reading variables from themselves or their cascaded ancestors. That means that if a widget sets a variable and then reads the same variable, it will get the same variable back. That sounds reasonable, until you consider a widget that wants to modify a variable - eg the tiddler macro. For example: ``` <$tiddler tiddler={{!!report}}> <$transclude mode="block" /> </$tiddler> ``` Here we first evaluate the `{{!!report}}` reference, which involves reading the currentTiddler variable, looking up the tiddler, and retrieving it’s `report` field. The next the tiddler widget is refreshed, it will use the newly set currentTiddler as the basis for resolving the `{{!!reference}}` reference. The fix is to get variables from ancestors, but continue to set them on ourselves.
- Loading branch information
e60fc9f
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just did a
git bisect
and this commit breaks the build. Crashes with:Trace log: https://gist.github.com/sukima/17275a038e502fdc91d7
e60fc9f
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @sukima - what command/script is giving you that error?
e60fc9f
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Jermolene:
The above error is seen in the Chrome Dev Tools console after opening
http://localhost:8080/
e60fc9f
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @sukima fix coming up momentarily.