2
I am new in the area of development and I am developing a project for learning.
Here I have a question about the layout division.
What is best practice?
Have separated the parts header sidebar footer content into different files and do include/require
Or in the index let done those parts (header, sidebar, footer) and give include/require in the content?
Has differences in performance?
When should I start worrying about performance?
I thank you all for sharing the knowledge! :]
There is no "right" in this case, it all depends on what content you are programming. You should not worry about performance at this level. Worry about how much your options facilitate the organization of your source. Having to do 1 include or 10 no on the same page will not make significant difference to the site user.
– Pagotti
Anything that repeats on multiple pages can turn to include.
– Antonio Alexandre