moved render main component into template to easily pass settings through