whimsical-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ru...@apache.org
Subject [whimsy] 01/02: export view properly
Date Tue, 10 Oct 2017 14:57:25 GMT
This is an automated email from the ASF dual-hosted git repository.

rubys pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/whimsy.git

commit 08e34d94c6018bda47208e01cf3dc4f2f46b14fc
Author: Sam Ruby <rubys@intertwingly.net>
AuthorDate: Tue Oct 10 10:56:10 2017 -0400

    export view properly
    
    TODO: investigate whether or not it should be elmintated
---
 www/board/agenda/views/layout/main.js.rb | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/www/board/agenda/views/layout/main.js.rb b/www/board/agenda/views/layout/main.js.rb
index 5e2e2c5..3a9e52e 100644
--- a/www/board/agenda/views/layout/main.js.rb
+++ b/www/board/agenda/views/layout/main.js.rb
@@ -19,8 +19,7 @@ class Main < Vue
 
       view = nil
       _main do
-        Vue.createElement(@item.view, props: {item: @item,
-         ref: proc {|component| Main.view=component}})
+        Vue.createElement(@item.view, props: {item: @item}, ref: 'view')
       end
 
       _Footer item: @item, buttons: @buttons, options: @options
@@ -86,9 +85,10 @@ class Main < Vue
 
   # additional client side initialization
   def mounted()
-    # export navigate and refresh methods
+    # export navigate and refresh methods as well as view
     Main.navigate = self.navigate
     Main.refresh  = self.refresh
+    Main.view  = $refs.view
 
     # store initial state in history, taking care not to overwrite
     # history set by the Search component.

-- 
To stop receiving notification emails like this one, please contact
"commits@whimsical.apache.org" <commits@whimsical.apache.org>.

Mime
View raw message