during precompile, wrap directive templates into pages. Fixes #136