Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Register
  • Sign in
  • renderjs renderjs
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Merge requests 1
    • Merge requests 1
  • Deployments
    • Deployments
    • Releases
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Activity
  • Graph
  • Commits
Collapse sidebar
  • nexedinexedi
  • renderjsrenderjs
  • Merge requests
  • !6

onEvent, onStateChange, declareJob, element

  • Review changes

  • Download
  • Patches
  • Plain diff
Merged Romain Courteaud requested to merge romain/renderjs:wip into master Oct 11, 2016
  • Overview 2
  • Commits 4
  • Changes 4

4 main changes are provided by this merge request.

  1. deprecate getElement method. Access the DOM with the .element property directly
  2. add onEvent service. It simplify the DOM event handler, by no manually writing loopEventListener. The event target will be the gadget event.
  3. add declareJob, which are method with a deferred execution, triggered when the gadget is inside the DOM
  4. add a gadget state property. It can be initialized with the setState class method. Gadget state must be modified with the changeState method, which can trigger an onStateChange callback if a modification has been detected

/cc @cedric.leninivin @vincentB

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: wip
GitLab Nexedi Edition | About GitLab | About Nexedi | 沪ICP备2021021310号-2 | 沪ICP备2021021310号-7