mirror of
https://github.com/moodle/moodle.git
synced 2025-01-19 06:18:28 +01:00
3adb62b727
I have spent quite a lot of time working through the current list of eslint options and configuring them for Moodle style and I think this is a very good basis to start us at (as well as taking some of out jshint options out with https://www.npmjs.com/package/polyjuice ). Thanks to Andrew Nicols, Mark Johnson and Frédéric Massart for some refinements. With this configuration the grunt build will fail if errors are present in the js (though you can of course tell jshint to ignore some errors, as I have done in admin/tool/lp/amd/src/competency_rule_points.js and defining the Y global in lib/amd/src/yui.js ). The grunt task will not report warnings by default, but a new --show-lint-warnings flag will help achieve that. Editor integrations/stanadalone eslint tool will surely be a better way of getting eslint errors rather than using the grunt task.