项目档案
项目二
知乎,中文互联网高质量的问答社区和创作者聚集的原创内容平台,于2011 年1 月正式上线,以「让人们更好的分享知识、经验和见解,找到自己的解答」为品牌使命。
- 项目分类
项目说明
What happens when your write @widget('SomeWidget') in your views
Given that we have disabled caching in the widgetize config file...
1 - It first looks for "SomeWidget" class to get config from.
2 - Then calls the widget's controller method and gets some data from it.
3 - Using that data it "compiles" (in other word "renders") the blade file ($template). (to produce some html)
4 - (If caching is enabled for the widget) it puts a copy of the resulting html in cache, for future use.
5 - At last, it returns the final HTML. (or maybe json)