예제 #1
0
    def dom(self):
        """
    Javascript Functions

    Return all the Javascript functions defined for an HTML Component.
    Those functions will use plain javascript by default.

    This is the only flexible component in which this DOM object can be changed.

    :return: A Javascript Dom object

    :rtype: JsHtml.JsHtml
    """
        if self._dom is None:
            self._dom = JsHtml.JsHtml(self.val, report=self._report)
        return self._dom
예제 #2
0
from epyk.core.js.html import JsHtml
from epyk.core.js import JsUtils

class HtmlComp(object):
  htmlCode = "test"


# ------------------------------------------------------------------------------------------------------------------
#
dom = JsHtml.JsHtml(HtmlComp())
f = JsUtils.JsFile("Dom", path=r"../outs")

f.writeJs([
  dom.hide(),
  dom.toggle()
])
f.close()