diff --git a/src/kajax.nim b/src/kajax.nim index 414b9d2..c226c50 100644 --- a/src/kajax.nim +++ b/src/kajax.nim @@ -23,7 +23,7 @@ proc ajax(meth, url: cstring; headers: openarray[(cstring, cstring)]; proc statechange(r: HttpRequest; cb: proc()) {.importcpp: "#.onreadystatechange = #".} proc send(r: HttpRequest; data: cstring) {.importcpp: "#.send(#)".} proc open(r: HttpRequest; meth, url: cstring; async: bool) {.importcpp: "#.open(@)".} - proc newRequest(): HttpRequest {.importcpp: "new XMLHttpRequest(@)",} + proc newRequest(): HttpRequest {.importcpp: "new XMLHttpRequest(@)".} var this {.importc: "this".}: ThisObj let ajax = newRequest() diff --git a/src/kdom.nim b/src/kdom.nim index 106666c..2c015a9 100644 --- a/src/kdom.nim +++ b/src/kdom.nim @@ -583,7 +583,7 @@ proc javaEnabled*(h: Navigator): bool # ClassList "methods" proc add*(c: ClassList, class: cstring) proc remove*(c: ClassList, class: cstring) -proc contains*(c: ClassList, class: cstring):bool +proc contains*(c: ClassList, class: cstring): bool proc toggle*(c: ClassList, class: cstring) # Style "methods" @@ -644,9 +644,9 @@ type proc getBoundingClientRect*(e: Node): BoundingRect {. importcpp: "getBoundingClientRect", nodecl.} proc clientHeight*(): int {. - importcpp: "(window.innerHeight || document.documentElement.clientHeight)@", nodecl} + importcpp: "(window.innerHeight || document.documentElement.clientHeight)@", nodecl.} proc clientWidth*(): int {. - importcpp: "(window.innerWidth || document.documentElement.clientWidth)@", nodecl} + importcpp: "(window.innerWidth || document.documentElement.clientWidth)@", nodecl.} proc inViewport*(el: Node): bool = let rect = el.getBoundingClientRect() diff --git a/src/localstorage.nim b/src/localstorage.nim index 5744124..e2fb62e 100644 --- a/src/localstorage.nim +++ b/src/localstorage.nim @@ -2,9 +2,9 @@ ## This module contains wrappers for the HTML 5 local storage. -proc getItem*(key: cstring): cstring {.importc: "localStorage.getItem"} -proc setItem*(key, value: cstring) {.importc: "localStorage.setItem"} +proc getItem*(key: cstring): cstring {.importc: "localStorage.getItem".} +proc setItem*(key, value: cstring) {.importc: "localStorage.setItem".} proc hasItem*(key: cstring): bool {.importcpp: "(localStorage.getItem(#) !== null)".} -proc clear*() {.importc: "localStorage.clear"} +proc clear*() {.importc: "localStorage.clear".} proc removeItem*(key: cstring) {.importc: "localStorage.removeItem".}