Created
April 1, 2018 14:49
-
-
Save alexzuza/d1592f21c732fa26e5a11a52dfc92c2b to your computer and use it in GitHub Desktop.
IDOM text
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function text(value) { | |
nextNode(); | |
const node = renderDOM('#text'); | |
// update | |
// checks for text updates | |
const data = getData(node); | |
if (data.text !== value) { | |
data.text = (value); | |
node.data = value; | |
} | |
// end update | |
return currentNode; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment