aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authors-ol <s-ol@users.noreply.github.com>2018-10-30 07:05:27 +0000
committers-ol <s-ol@users.noreply.github.com>2018-10-30 07:05:27 +0000
commitc00dac92ca91ccf978673f59f9bfbe44101629e9 (patch)
treec74247ed15ce7457609eb96fa81d8561f6939e28 /lib
parentupdate text, add lots of TODOs (diff)
downloadmmm-c00dac92ca91ccf978673f59f9bfbe44101629e9.tar.gz
mmm-c00dac92ca91ccf978673f59f9bfbe44101629e9.zip
fix inline code
Diffstat (limited to 'lib')
-rw-r--r--lib/component.client.moon1
-rw-r--r--lib/dom.client.moon1
2 files changed, 2 insertions, 0 deletions
diff --git a/lib/component.client.moon b/lib/component.client.moon
index 617deb5..7357f50 100644
--- a/lib/component.client.moon
+++ b/lib/component.client.moon
@@ -93,6 +93,7 @@ class ReactiveElement
for unsub in *@_subscriptions do unsub!
set: (attr, value) =>
+ attr = 'className' if attr == 'class'
if 'table' == (type value) and ReactiveVar.isinstance value
table.insert @_subscriptions, value\subscribe (...) -> @set attr, ...
value = value\get!
diff --git a/lib/dom.client.moon b/lib/dom.client.moon
index b8f2bd5..a5a319b 100644
--- a/lib/dom.client.moon
+++ b/lib/dom.client.moon
@@ -10,6 +10,7 @@ element = (element) -> (...) ->
with e = document\createElement element
for k,v in pairs attributes
+ k = 'className' if k == 'class'
if k == 'style' and 'table' == type v
for kk,vv in pairs v
e.style[kk] = vv