aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/LoaderRef.purs
diff options
context:
space:
mode:
Diffstat (limited to 'src/LoaderRef.purs')
-rw-r--r--src/LoaderRef.purs24
1 files changed, 24 insertions, 0 deletions
diff --git a/src/LoaderRef.purs b/src/LoaderRef.purs
index 2567b1e..f1efa04 100644
--- a/src/LoaderRef.purs
+++ b/src/LoaderRef.purs
@@ -4,6 +4,9 @@ module PursLoader.LoaderRef
4 , async 4 , async
5 , cacheable 5 , cacheable
6 , query 6 , query
7 , clearDependencies
8 , addDependency
9 , resourcePath
7 ) where 10 ) where
8 11
9import Control.Monad.Eff (Eff()) 12import Control.Monad.Eff (Eff())
@@ -48,3 +51,24 @@ foreign import query """
48function query(ref){ 51function query(ref){
49 return ref.query; 52 return ref.query;
50}""" :: LoaderRef -> String 53}""" :: LoaderRef -> String
54
55foreign import clearDependencies """
56function clearDependencies(ref){
57 return function(){
58 return ref.clearDependencies();
59 };
60}""" :: forall eff. LoaderRef -> Eff (loader :: Loader | eff) Unit
61
62foreign import resourcePath """
63function resourcePath(ref){
64 return ref.resourcePath;
65}""" :: LoaderRef -> String
66
67foreign import addDependency """
68function addDependency(ref){
69 return function(dep){
70 return function(){
71 return ref.addDependency(dep);
72 };
73 };
74}""" :: forall eff. LoaderRef -> String -> Eff (loader :: Loader | eff) Unit