   (prepare-pages (get-basic-pages)))
 
 (def app
-  (optimus/wrap (stasis/serve-pages final-pages)
-                get-assets
-                optimisations/all
-                serve-live-assets))
+  (-> (stasis/serve-pages final-pages)
+      (optimus/wrap get-assets optimisations/none serve-live-assets)
+      (wrap-default-charset "UTF-8")))
 
 (def export-dir "dist")
 

(defn meta-post->page-loc
  "Convert a meta-post to a pair of a HTML page and a URI fragment. See omhome.meta-post/empty-post for a default post structure."
  [meta-post]
  [(-> meta-post :post-url
       ;; File. .getAbsolutePath
       ;; (str/replace  #"\.clj$" "/")
       ) ;; Stasis' page map requires absolute paths to files
   (fn [req] (layout-page req (read-string (slurp (:post-filepath meta-post))) meta-post))])

(defn meta-posts->page-map
  "Convert a vector of meta-posts into a map of URI fragment and HTML page pairs, suitable for inclusion in Stasis' page map."
  [meta-posts]
  (into {} (map meta-post->page-loc meta-posts)))

(defn hiccup->pages
  "Generate HTML pages from the supplied Hiccup fragments."
  [hiccup-content]
  (zipmap (map  #(str/replace % #"\.clj$" "/") (keys hiccup-content))
          (map #(fn [req] (layout-page req (-> % read-string ))) (vals hiccup-content))))

;; rework the stasis map of filenames to source content created using markdown to use paths and html
(defn markdown->pages [markdown-content]

(ns omhome.ssgen
  (:require [stasis.core :as stasis]
            [ring.middleware.default-charset :refer [wrap-default-charset]]
            [hiccup.page :refer [html5]]
            [me.raynes.cegdown :as md]
            [omhome.highlight :refer [highlight-code-blocks]]
