diff options
| author | s-ol <s-ol@users.noreply.github.com> | 2018-10-26 16:25:31 +0000 |
|---|---|---|
| committer | s-ol <s-ol@users.noreply.github.com> | 2018-10-26 16:25:31 +0000 |
| commit | 50f160f897e04b9b122b3f17077c92ac0bb23732 (patch) | |
| tree | 0fc4b05cfd1bd514c446c43879f76bf48b3e8709 /lib/html.client.moon | |
| parent | like, lots of new stuff 4 tablefs (diff) | |
| download | mmm-50f160f897e04b9b122b3f17077c92ac0bb23732.tar.gz mmm-50f160f897e04b9b122b3f17077c92ac0bb23732.zip | |
allow style props in html.client
Diffstat (limited to 'lib/html.client.moon')
| -rw-r--r-- | lib/html.client.moon | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/html.client.moon b/lib/html.client.moon index eb4d7fe..b8f2bd5 100644 --- a/lib/html.client.moon +++ b/lib/html.client.moon @@ -10,7 +10,10 @@ element = (element) -> (...) -> with e = document\createElement element for k,v in pairs attributes - if 'string' == type k + if k == 'style' and 'table' == type v + for kk,vv in pairs v + e.style[kk] = vv + elseif 'string' == type k e[k] = v -- if there is only one argument, |
