SU-SWS/decanter

View on GitHub
core/src/js/components/secondary-nav/common/events/OnEnter.js

Summary

Maintainability
A
1 hr
Test Coverage
import EventAbstract from './EventAbstract';

/**
 * OnEnter
 *
 * Event action handler class.
 */
export default class OnEnter extends EventAbstract {

  /**
   * Execute the action to the event.
   */
  exec() {
    this.event.stopPropagation();
    this.event.preventDefault();
    window.location = this.target.getAttribute('href');
  }

}