UNPKG
nodobjc-x
Version:
latest (2.1.1)
2.1.1
The Node.js ⇆ Objective-C bridge
github.com/TooTallNate/NodObjC
TooTallNate/NodObjC
nodobjc-x
/
docs
/
assets
/
script.js
13 lines
(9 loc)
•
232 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
9
10
11
12
13
$(
function
(
) { $(
'button'
).
click
(
function
(
e
) {
var
code = $(
this
).
next
() code.
toggleClass
(
'shown'
)
var
shown = code.
hasClass
(
'shown'
) $(
this
).
text
((shown ?
'Hide'
:
'Show'
) +
' Code'
)
return
false
}) })