Native Event Listener

Content Type: Widget
Categories: Utility

Overview

Listen for Native Events in your Mendix page. This greatly expands the possibilities, as you are able to execute Native Events simply from a Javascript Action in a Nanoflow. This widget works exactly the same as the Custom Event Listener, but this one is for Mendix Native.

  • The widget will listen for native events on the page
  • When this event is detected, it can execute an action (Nanoflow, microflow, etc...)
  • If you provide an attribute, it will put the value coming from Event.detail in this attribute before executing the action

Documentation

Native Event Listener

marketplace

Listen for native events on your page. This is similar to the Custom Event Listener (for web) on the Mendix MarketPlace

Features

  • The widget will listen for native events in your page
  • When this event is detected, it can execute an action (Nanoflow, microflow, etc...)
  • If you provide an attribute, it will put the value coming from Event.detail in this attribute before executing the action

Example

  • I have configured the widget to listen for a Native Event with name 'PressedButton'
  • When this event is detected, it will execute the Nanoflow OnAction

Somewhere else in the page (in this case the button), I execute a Nanoflow that will execute a Javascript Action with the following code:

Issues, suggestions and feature requests

Feedback can be provided on Github

License

The MIT License (MIT)

Copyright © CaffCode 2022. All Rights Reserved.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Releases

Version: 1.0.1
Framework Version: 9.6.12
Release Notes: - Bugfix for #1 (fixing removeEventListener for newer React Native versions)
Version: 1.0.0
Framework Version: 9.6.12
Release Notes: - 🔥 First release