Selaa lähdekoodia

Example of ajax sections

@soyjavi 14 vuotta sitten
vanhempi
commit
21318fe31e

+ 6 - 1
examples/kitchen-sink/app/app.js

@@ -3,7 +3,12 @@ var App = (function(lng, undefined) {
 
     lng.App.init({
         name: 'Kitchen Sink',
-        version: '1.1'
+        version: '1.1',
+        sections: [
+            'local.html',
+            'http://examples.tapquo.com/examples/kitchen-sink/app/sections/remote.html',
+            'http://examples.tapquo.com/examples/kitchen-sink/app/sections/error.html',
+        ]
     });
 
     var _getEnvironmentFromQuoJS = (function() {

+ 6 - 0
examples/kitchen-sink/app/events.js

@@ -1,5 +1,11 @@
 App.Events = (function(lng, undefined) {
 
+    /*
+    lng.dom(document).ready(function() {
+
+    });
+    */
+
     lng.dom('#event_touchstart').touch(function(event) { alert("touchstart!"); });
     //OR
     //lng.dom('#event_touchstart').on('touchstart', function(event) { alert("TOUCH_START!"); });

+ 5 - 0
examples/kitchen-sink/app/sections/local.html

@@ -0,0 +1,5 @@
+<section id="async-local">
+    <header data-back="home"  data-title="Async Local Section"></header>
+
+    <article></article>
+</section>

+ 4 - 0
examples/kitchen-sink/app/sections/remote.html

@@ -0,0 +1,4 @@
+<section id="async-remote">
+    <header data-back="home"  data-title="Async Remote Section"></header>
+    <article></article>
+</section>

+ 1 - 2
examples/kitchen-sink/index.html

@@ -473,8 +473,6 @@
         <article></article>
     </section>
 
-
-
     <!-- ============================= header footer ============================= -->
 
     <!-- ============================= lists ============================= -->
@@ -554,6 +552,7 @@
     <script src="../../src/data/Lungo.Data.Storage.js"></script>
     <script src="../../src/attributes/Lungo.Attributes.Data.js"></script>
     <script src="../../src/boot/Lungo.Boot.js"></script>
+    <script src="../../src/boot/Lungo.Boot.Async.js" ></script>
     <script src="../../src/boot/Lungo.Boot.Stats.js" ></script>
     <script src="../../src/boot/Lungo.Boot.Layout.js"></script>
     <script src="../../src/boot/Lungo.Boot.Events.js"></script>