js-syms.lisp
37 lines
| 698 B
| text/x-common-lisp
|
CommonLispLexer
/ src / js-syms.lisp
r25 | ||||
(in-package sugar-qsp.js) | ||||
;;; Contains symbols from standard JS library to avoid obfuscating | ||||
;;; and/or namespacing them | ||||
(cl:defmacro syms (cl:&rest syms) | ||||
`(cl:progn | ||||
,@(cl:loop :for sym :in syms | ||||
:collect `(cl:export ',sym)))) | ||||
(syms | ||||
;; main | ||||
window | ||||
*object | ||||
now | ||||
onload | ||||
keys includes | ||||
has-own-property | ||||
;; api | ||||
document get-element-by-id | ||||
onclick onchange | ||||
atob btoa | ||||
alert prompt | ||||
set-timeout set-interval clear-interval | ||||
*promise *j-s-o-n | ||||
href parse | ||||
set-prototype-of | ||||
body append-child remove-child | ||||
create-element set-attribute | ||||
*file-reader read-as-text | ||||
style display src | ||||
;; lib | ||||
*number parse-int | ||||
to-upper-case concat | ||||
click target current-target files index-of | ||||
) | ||||