Best Practices for CSS and Templates?
Hi,
I run a Pokemon fan website and have a listing of Pokemon products that have been released each month. So I'll have a page on 2017's products with each H2 showing a month ("May 2017") and then each product released in that month under the header. Each product listing shows the product's image, release date, price, etc.
So to display a month's worth of products under each H2 header, I have a "product header" template that starts the div HTML for that month and calls up the CSS to display the products, then each "product item" template, then a closing "product footer" template that closes the div. So it's something like: "product header" template, "product item" template for product #1, "product item" template for product #2, "product item" template for item #3, and then the closing "product footer" template.
Now here's my questions:
1. The "product header" template is what starts up the div for each month and calls up the CSS for the product display. If you're making a template, would you store the CSS directly in that template? Do you put the CSS somewhere else in Vaultwiki? Do you call up the CSS via a style tag and put the CSS file on the server? What's the best way to do this?
2. Now here's my other problem. The "product" CSS is called up 12 times on each year's product page because it's called up every single time under every single month. Is this how it should work? Shouldn't Vaultwiki only allow it to be called up once?
Basically I'm just trying to figure out how to organize my wiki before it opens to the public so that we're doing things correctly. A big wiki can get very messy very quickly, so I want to understand what's the best way to work on templates, store their CSS, etc., especially when there will be hundreds of templates.
Thank you!