lint: Fix "assign before exporting" warnings
This fixes all instances which caused the following lint warning: "Assign object/arrow function to a variable before exporting as module default"
This commit is contained in:
parent
7324e647a4
commit
a9dc4f4a14
15 changed files with 47 additions and 15 deletions
|
|
@ -32,7 +32,7 @@ const SourcesButton = () => {
|
|||
);
|
||||
};
|
||||
|
||||
export default {
|
||||
const awsStep = {
|
||||
StepTemplate,
|
||||
id: 'wizard-target-aws',
|
||||
title: 'Amazon Web Services',
|
||||
|
|
@ -185,3 +185,5 @@ export default {
|
|||
},
|
||||
],
|
||||
};
|
||||
|
||||
export default awsStep;
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ import StepTemplate from './stepTemplate';
|
|||
|
||||
import FileSystemConfigButtons from '../formComponents/FileSystemConfigButtons';
|
||||
|
||||
export default {
|
||||
const fileSystemConfigurationStep = {
|
||||
StepTemplate,
|
||||
id: 'wizard-systemconfiguration-filesystem',
|
||||
title: 'File system configuration',
|
||||
|
|
@ -116,3 +116,5 @@ export default {
|
|||
},
|
||||
],
|
||||
};
|
||||
|
||||
export default fileSystemConfigurationStep;
|
||||
|
|
|
|||
|
|
@ -82,7 +82,7 @@ PopoverInfo.propTypes = {
|
|||
appendTo: PropTypes.any,
|
||||
};
|
||||
|
||||
export default {
|
||||
const googleCloudStep = {
|
||||
StepTemplate,
|
||||
id: 'wizard-target-gcp',
|
||||
title: 'Google Cloud Platform',
|
||||
|
|
@ -182,3 +182,5 @@ export default {
|
|||
},
|
||||
],
|
||||
};
|
||||
|
||||
export default googleCloudStep;
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ const CharacterCount = () => {
|
|||
return <h1>{description?.length || 0}/250</h1>;
|
||||
};
|
||||
|
||||
export default {
|
||||
const imageNameStep = {
|
||||
StepTemplate,
|
||||
id: 'wizard-details',
|
||||
name: 'details',
|
||||
|
|
@ -71,3 +71,5 @@ export default {
|
|||
},
|
||||
],
|
||||
};
|
||||
|
||||
export default imageNameStep;
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ import { RHEL_9 } from '../../../constants.js';
|
|||
import DocumentationButton from '../../sharedComponents/DocumentationButton';
|
||||
import CustomButtons from '../formComponents/CustomButtons';
|
||||
|
||||
export default {
|
||||
const imageOutputStep = {
|
||||
StepTemplate,
|
||||
id: 'wizard-imageoutput',
|
||||
title: 'Image output',
|
||||
|
|
@ -69,3 +69,5 @@ export default {
|
|||
},
|
||||
],
|
||||
};
|
||||
|
||||
export default imageOutputStep;
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import isRhel from '../../../Utilities/isRhel.js';
|
||||
|
||||
export default (
|
||||
const imageOutputStepMapper = (
|
||||
{ 'target-environment': targetEnv, release } = {},
|
||||
{ skipAws, skipGoogle, skipAzure } = {}
|
||||
) => {
|
||||
|
|
@ -18,3 +18,5 @@ export default (
|
|||
|
||||
return isRhel(release) ? 'registration' : 'File system configuration';
|
||||
};
|
||||
|
||||
export default imageOutputStepMapper;
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ const SourcesButton = () => {
|
|||
);
|
||||
};
|
||||
|
||||
export default {
|
||||
const msAzureStep = {
|
||||
StepTemplate,
|
||||
id: 'wizard-target-msazure',
|
||||
title: 'Microsoft Azure',
|
||||
|
|
@ -260,3 +260,5 @@ export default {
|
|||
// TODO check oauth2 thing too here?
|
||||
],
|
||||
};
|
||||
|
||||
export default msAzureStep;
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ import StepTemplate from './stepTemplate';
|
|||
|
||||
import CustomButtons from '../formComponents/CustomButtons';
|
||||
|
||||
export default {
|
||||
const packagesStep = {
|
||||
StepTemplate,
|
||||
id: 'wizard-systemconfiguration-packages',
|
||||
title: 'Additional Red Hat packages',
|
||||
|
|
@ -38,3 +38,5 @@ export default {
|
|||
},
|
||||
],
|
||||
};
|
||||
|
||||
export default packagesStep;
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ import StepTemplate from './stepTemplate';
|
|||
|
||||
import CustomButtons from '../formComponents/CustomButtons';
|
||||
|
||||
export default {
|
||||
const packagesContentSourcesStep = {
|
||||
StepTemplate,
|
||||
id: 'wizard-systemconfiguration-content-sources-packages',
|
||||
title: 'Additional custom packages',
|
||||
|
|
@ -33,3 +33,5 @@ export default {
|
|||
},
|
||||
],
|
||||
};
|
||||
|
||||
export default packagesContentSourcesStep;
|
||||
|
|
|
|||
|
|
@ -59,7 +59,7 @@ const PopoverActivation = () => {
|
|||
);
|
||||
};
|
||||
|
||||
export default {
|
||||
const registrationStep = {
|
||||
StepTemplate,
|
||||
id: 'wizard-registration',
|
||||
title: 'Register',
|
||||
|
|
@ -179,3 +179,5 @@ export default {
|
|||
},
|
||||
],
|
||||
};
|
||||
|
||||
export default registrationStep;
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@ const VisitButton = () => {
|
|||
);
|
||||
};
|
||||
|
||||
export default {
|
||||
const repositoriesStep = {
|
||||
StepTemplate,
|
||||
id: 'wizard-repositories',
|
||||
title: 'Custom repositories',
|
||||
|
|
@ -55,3 +55,5 @@ export default {
|
|||
},
|
||||
],
|
||||
};
|
||||
|
||||
export default repositoriesStep;
|
||||
|
|
|
|||
|
|
@ -1,7 +1,11 @@
|
|||
export default ({ 'payload-repositories': customRepositories } = {}) => {
|
||||
const repositoriesStepMapper = ({
|
||||
'payload-repositories': customRepositories,
|
||||
} = {}) => {
|
||||
if (customRepositories?.length > 0) {
|
||||
return 'packages-content-sources';
|
||||
}
|
||||
|
||||
return 'details';
|
||||
};
|
||||
|
||||
export default repositoriesStepMapper;
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ import StepTemplate from './stepTemplate';
|
|||
|
||||
import CustomButtons from '../formComponents/CustomButtons';
|
||||
|
||||
export default {
|
||||
const reviewStep = {
|
||||
StepTemplate,
|
||||
id: 'wizard-review',
|
||||
name: 'review',
|
||||
|
|
@ -15,3 +15,5 @@ export default {
|
|||
},
|
||||
],
|
||||
};
|
||||
|
||||
export default reviewStep;
|
||||
|
|
|
|||
|
|
@ -96,7 +96,7 @@ async function cloneImage(composeId, body) {
|
|||
return request.data;
|
||||
}
|
||||
|
||||
export default {
|
||||
const apiCalls = {
|
||||
cloneImage,
|
||||
composeImage,
|
||||
getClones,
|
||||
|
|
@ -107,3 +107,5 @@ export default {
|
|||
getPackagesContentSources,
|
||||
getVersion,
|
||||
};
|
||||
|
||||
export default apiCalls;
|
||||
|
|
|
|||
|
|
@ -52,9 +52,11 @@ export const fetchClones = (id, limit, offset) => async (dispatch) => {
|
|||
});
|
||||
};
|
||||
|
||||
export default {
|
||||
const actions = {
|
||||
fetchClones,
|
||||
fetchCloneStatus,
|
||||
fetchComposes,
|
||||
fetchComposeStatus,
|
||||
};
|
||||
|
||||
export default actions;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue