Files
edx-platform/lms/static/js/courseware/courseware_factory.js
Andy Armstrong 89e5c0fd8d Convert course bookmarks into a feature
LEARNER-39
2017-03-22 16:09:13 -04:00

24 lines
718 B
JavaScript

(function(define) {
'use strict';
define([
'jquery',
'logger'
],
function($, Logger) {
return function() {
// This function performs all actions common to all courseware.
// 1. adding an event to all link clicks.
$('a:not([href^="#"])').click(function(event) {
Logger.log(
'edx.ui.lms.link_clicked',
{
current_url: window.location.href,
target_url: event.currentTarget.href
});
});
};
}
);
}).call(this, define || RequireJS.define);