Prefer default export to make XO happy (#931)

* Comply with prefer-default-export rule for findBySession function

* Remove XO's prefer-default-export rule

* Comply with prefer-default-export rule for init function

* Comply with prefer-default-export rule for getRootGroups function

* Comply with prefer-default-export rule for INIT constant

* Comply with prefer-default-export rule for isExecutable function

* Fix default export for constants

* Comply with prefer-default-export rule for last function

* Comply with prefer-default-export rule for getColorList function
This commit is contained in:
David Gómez 2016-10-25 08:53:15 -04:00 committed by Leo Lamprecht
parent de5b384ccd
commit 8f28573fc0
16 changed files with 24 additions and 21 deletions

View file

@ -1,3 +1,3 @@
export function last(arr) {
export default function last(arr) {
return arr[arr.length - 1];
}

View file

@ -19,7 +19,7 @@ const colorList = [
'grayscale'
];
export function getColorList(colors) {
export default function getColorList(colors) {
// For backwards compatibility, return early if it's already an array
if (Array.isArray(colors)) {
return colors;

View file

@ -10,7 +10,7 @@
* PR: https://github.com/kevva/executable/pull/10
*/
export function isExecutable(fileStat) {
export default function isExecutable(fileStat) {
if (process.platform === 'win32') {
return true;
}

View file

@ -1,4 +1,4 @@
export function findBySession(termGroupState, sessionUid) {
export default function findBySession(termGroupState, sessionUid) {
const {termGroups} = termGroupState;
return Object.keys(termGroups)
.map(uid => termGroups[uid])