Uploaded image for project: 'Alloy'
  1. Alloy
  2. ALOY-809

Debugger stops because of an exception when adding event listeners in the view

    Details

    • Sprint:
      2013 Sprint 22

      Description

      Description of the problem

      Due to a recent chance in the way event listeners in the view are added (using try/catch instead of the ternary operator), the debugger is now suspending the flow when the app starts, because of the handled exception.

      Steps to reproduce

      1) Create new Alloy project
      2) open index.xml and replace "doClick" with "exports.doClick"
      3) open index.js and replace "function doClick(e)" with "exports.doCLick = function(e)"
      4) Run the app

      The resulting file will contain:

      try {
              $.__views.label.addEventListener("click", exports.doClick);
      } catch ( e ) {
              __defers["$.__views.label!click!exports.doClick"] = true;
      }
      

      Previously, this was handled using a ternary operator, thus avoiding the try/catch.

        Attachments

          Activity

            People

            • Assignee:
              tlukasavage Tony Lukasavage
              Reporter:
              dcassenti Davide Cassenti
            • Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Backbone Issue Sync

                • Backbone Issue Sync is enabled for your project, but we do not have any synchronization info for this issue.

                  Git Integration