Skip to content

Commit

Permalink
Fixed bug that caused a runtime error when trying to view non-exisita…
Browse files Browse the repository at this point in the history
…nt records
  • Loading branch information
Merton committed May 4, 2017
1 parent 3aa2f44 commit 932845c
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions Settings/StaticFiles.hs
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
module Settings.StaticFiles where

import Settings (appStaticDir, compileTimeAppSettings)
import Yesod.Static (staticFiles)

-- This generates easy references to files in the static directory at compile time,
-- giving you compile-time verification that referenced files exist.
-- Warning: any files added to your static directory during run-time can't be
-- accessed this way. You'll have to use their FilePath or URL to access them.
--
-- For example, to refer to @static/js/script.js@ via an identifier, you'd use:
--
-- js_script_js
--
-- If the identifier is not available, you may use:
--
-- StaticFile ["js", "script.js"] []
staticFiles (appStaticDir compileTimeAppSettings)

0 comments on commit 932845c

Please sign in to comment.