how to use decorators to dry my views with CI3 |
Hi all , thanks for reading
I want to implement decorator pattern to dry my views with CI3. after reading this tutorials and brain storming i came up with this ideas 1) decorate should be able to decorate single record as well as result set 2) make use of composer and/or psr autoloading 3) can be used with HMVC ( i use wiredesign extension) 4) use it with or without template system( template library , partial view , view fragment etc) 5) where to place decorators -- In decorators folder. And create a library to load decoraters from it. -- create each decorators as individual library and load it in controllers -- If using HMVC putting decorators in each modules -- in vendor folder (in case of composer) If you have use decorators please suggest me some code examples. (English is my third language.forgive me for mistake ) ![]() ![]() Learning best practices Rate my post if you found it helpfull |
Messages In This Thread |
how to use decorators to dry my views with CI3 - by jaynarayan - 12-15-2015, 10:27 PM
|