refactor to add a setting to have fixed header