discourse/app/assets/javascripts/wizard/initializers/load-helpers.js.es6
2016-11-25 14:29:45 -05:00

15 lines
329 B
JavaScript

import { registerHelpers } from 'discourse-common/lib/helpers';
export default {
name: 'load-helpers',
initialize(application) {
Object.keys(requirejs.entries).forEach(entry => {
if ((/\/helpers\//).test(entry)) {
require(entry, null, null, true);
}
});
registerHelpers(application);
}
};