Refactoring static page generator.