Commit 0218a3d9 authored by Mike Greiling's avatar Mike Greiling

refactor instances of CJS module.exports to ES module syntax

parent 6985dfe7
......@@ -14,7 +14,6 @@ import './components/stage_test_component';
import './components/total_time_component';
import './cycle_analytics_service';
import './cycle_analytics_store';
import './default_event_objects';
Vue.use(Translate);
......
module.exports = {
export default {
issue: {
created_at: '',
url: '',
......
......@@ -2,9 +2,7 @@
* exports HTTP status codes
*/
const statusCodes = {
export default {
NO_CONTENT: 204,
OK: 200,
};
module.exports = statusCodes;
......@@ -8,7 +8,7 @@ const defaults = {
fileBlobPermalinkUrl: null,
};
class ShortcutsBlob extends Shortcuts {
export default class ShortcutsBlob extends Shortcuts {
constructor(opts) {
const options = Object.assign({}, defaults, opts);
super(options.skipResetBindings);
......@@ -25,5 +25,3 @@ class ShortcutsBlob extends Shortcuts {
}
}
}
module.exports = ShortcutsBlob;
class VersionCheckImage {
export default class VersionCheckImage {
static bindErrorEvent(imageElement) {
imageElement.off('error').on('error', () => imageElement.hide());
}
......@@ -6,5 +6,3 @@ class VersionCheckImage {
window.gl = window.gl || {};
gl.VersionCheckImage = VersionCheckImage;
module.exports = VersionCheckImage;
class ClassSpecHelper {
export default class ClassSpecHelper {
static itShouldBeAStaticMethod(base, method) {
return it('should be a static method', () => {
expect(Object.prototype.hasOwnProperty.call(base, method)).toBeTruthy();
......@@ -7,5 +7,3 @@ class ClassSpecHelper {
}
window.ClassSpecHelper = ClassSpecHelper;
module.exports = ClassSpecHelper;
class FilteredSearchSpecHelper {
export default class FilteredSearchSpecHelper {
static createFilterVisualTokenHTML(name, value, isSelected) {
return FilteredSearchSpecHelper.createFilterVisualToken(name, value, isSelected).outerHTML;
}
......@@ -53,5 +53,3 @@ class FilteredSearchSpecHelper {
`;
}
}
module.exports = FilteredSearchSpecHelper;
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment