remove unnecessary code and imports for rendering