-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"name": "qoopido.demand", | ||
"version": "4.1.5", | ||
"version": "4.1.6", | ||
"homepage": "https://github.com/dlueth/qoopido.demand", | ||
"authors": [ | ||
"Dirk Lueth <[email protected]>" | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
<script type="module"> | ||
(function() { | ||
function definition() { | ||
return function() { | ||
console.log('main'); | ||
} | ||
} | ||
|
||
provide(definition); | ||
}()); | ||
</script> | ||
|
||
<script type="module" path="secondary"> | ||
(function() { | ||
function definition() { | ||
return function() { | ||
console.log('secondary'); | ||
} | ||
} | ||
|
||
provide(definition); | ||
}()); | ||
</script> | ||
|
||
<script type="css"> | ||
#blubb { color: #f00; } | ||
</script> | ||
|
||
<script type="html"> | ||
<h1>Headline</h1> | ||
</script> |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -56,7 +56,7 @@ | |
pattern: { | ||
'/nucleus': '//cdn.jsdelivr.net/qoopido.nucleus/2.0.1/', | ||
'/jquery': '//cdn.jsdelivr.net/jquery/1.11.3/jquery.min', | ||
'/jquery/ui': '//cdn.jsdelivr.net/jquery.ui/1.11.4/jquery-ui.min', | ||
'/jquery/ui': '//cdn.jsdelivr.net/jquery.ui/1.11.4/jquery-ui.min', | ||
'/velocity': '//cdn.jsdelivr.net/velocity/1.2.3/velocity.min.js', | ||
'/leaflet': '//cdn.jsdelivr.net/leaflet/0.7.3/leaflet.js', | ||
'/velocity+leaflet': '//cdn.jsdelivr.net/g/[email protected],[email protected]' | ||
|
@@ -180,11 +180,11 @@ | |
log('demand', '/app/js/simple', 'rejected'); | ||
} | ||
), | ||
// load text (HTML in this case) | ||
demand('text!../html/dummy.html') | ||
// load html | ||
demand('html!../html/dummy') | ||
.then( | ||
function(appHtmlDummy) { | ||
log('demand', '/app/html/dummy', 'resolved', 'text, cookie, compress, sri'); | ||
log('demand', '/app/html/dummy', 'resolved', 'html, cookie, compress, sri'); | ||
}, | ||
function() { | ||
log('demand', '/app/html/dummy', 'rejected'); | ||
|
@@ -243,6 +243,16 @@ | |
log('demand', '/nucleus/dom/element', 'rejected'); | ||
log('demand', '/nucleus/dom/collection', 'rejected'); | ||
} | ||
), | ||
// load components | ||
demand('component!/app/component/example') | ||
.then( | ||
function(primaryModule, secondaryModule, primaryCss, primaryHtml) { | ||
log('demand', '/app/component/example', 'resolved', 'component, 2 modules, CSS & HTML'); | ||
}, | ||
function() { | ||
log('demand', '/app/component/example', 'rejected'); | ||
} | ||
) | ||
]) | ||
}) | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.