aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/PursLoader/Options.purs
diff options
context:
space:
mode:
authoreric thul <thul.eric@gmail.com>2015-12-25 19:24:02 -0500
committereric thul <thul.eric@gmail.com>2015-12-25 19:24:02 -0500
commitd78112147d02e263a5b000cb0b3b9ff84aa5c89a (patch)
tree108fbfe1442e5c7ef42a33dfde0655fa378d3fdc /src/PursLoader/Options.purs
parent9764d2a7d5e6d9cf081dcbc162dac01f95d452b3 (diff)
downloadpurs-loader-d78112147d02e263a5b000cb0b3b9ff84aa5c89a.tar.gz
purs-loader-d78112147d02e263a5b000cb0b3b9ff84aa5c89a.tar.zst
purs-loader-d78112147d02e263a5b000cb0b3b9ff84aa5c89a.zip
Updating bundle output option name
Diffstat (limited to 'src/PursLoader/Options.purs')
-rw-r--r--src/PursLoader/Options.purs16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/PursLoader/Options.purs b/src/PursLoader/Options.purs
index 132096c..706ddd2 100644
--- a/src/PursLoader/Options.purs
+++ b/src/PursLoader/Options.purs
@@ -11,20 +11,20 @@ import Data.Maybe (maybe)
11 11
12import PursLoader.Path (joinPath) 12import PursLoader.Path (joinPath)
13 13
14newtype Options = Options { pscBundle :: String } 14newtype Options = Options { bundleOutput :: String }
15 15
16type Options_ = { pscBundle :: String } 16type Options_ = { bundleOutput :: String }
17 17
18runOptions :: Options -> Options_ 18runOptions :: Options -> Options_
19runOptions (Options options) = options 19runOptions (Options options) = options
20 20
21instance isForeignOptions :: IsForeign Options where 21instance isForeignOptions :: IsForeign Options where
22 read obj = 22 read obj =
23 Options <$> ({ pscBundle: _ } 23 Options <$> ({ bundleOutput: _ }
24 <$> (maybe pscBundleDefault id <<< runNullOrUndefined <$> readProp pscBundle obj)) 24 <$> (maybe bundleOutputDefault id <<< runNullOrUndefined <$> readProp bundleOutput obj))
25 where 25 where
26 pscBundle :: String 26 bundleOutput :: String
27 pscBundle = "pscBundle" 27 bundleOutput = "bundleOutput"
28 28
29 pscBundleDefault :: String 29 bundleOutputDefault :: String
30 pscBundleDefault = joinPath "output" "bundle.js" 30 bundleOutputDefault = joinPath "output" "bundle.js"