linting update
This commit is contained in:
parent
3fd982f5f0
commit
406476d6a6
2 changed files with 11 additions and 16 deletions
|
|
@ -18,8 +18,8 @@ module.exports = {
|
||||||
'vue/attribute-hyphenation': ['warn', 'never'],
|
'vue/attribute-hyphenation': ['warn', 'never'],
|
||||||
'vue/v-on-event-hyphenation': ['warn', 'never'],
|
'vue/v-on-event-hyphenation': ['warn', 'never'],
|
||||||
'object-curly-newline': ['error', { consistent: true }],
|
'object-curly-newline': ['error', { consistent: true }],
|
||||||
'function-paren-newline': ['error', 'never'],
|
'function-paren-newline': ['error', 'multiline'],
|
||||||
'operator-linebreak': ['error', 'before', { overrides: { '=': 'after' }}],
|
'operator-linebreak': ['error', 'before', { overrides: { '=': 'after' } }],
|
||||||
'implicit-arrow-linebreak': ['off'],
|
'implicit-arrow-linebreak': ['off'],
|
||||||
'comma-dangle': ['error', 'never'],
|
'comma-dangle': ['error', 'never'],
|
||||||
indent: ['error', 4, { SwitchCase: 1 }],
|
indent: ['error', 4, { SwitchCase: 1 }],
|
||||||
|
|
@ -33,6 +33,7 @@ module.exports = {
|
||||||
'jsdoc/check-tag-names': ['error', {
|
'jsdoc/check-tag-names': ['error', {
|
||||||
definedTags: ['store', 'endpoint', 'category', 'subcategory', 'remarks']
|
definedTags: ['store', 'endpoint', 'category', 'subcategory', 'remarks']
|
||||||
}],
|
}],
|
||||||
|
'jsdoc/require-jsdoc': 0,
|
||||||
'vue/html-self-closing': ['error', {
|
'vue/html-self-closing': ['error', {
|
||||||
html: {
|
html: {
|
||||||
void: 'any',
|
void: 'any',
|
||||||
|
|
|
||||||
|
|
@ -160,24 +160,16 @@ router.overrideNavigation = (
|
||||||
optionalParams = {},
|
optionalParams = {},
|
||||||
optionalPageData = {}
|
optionalPageData = {}
|
||||||
) => {
|
) => {
|
||||||
navigate(
|
navigate(scenario, currentRoute, isSavingNavigation, optionalQuery, optionalParams, optionalPageData);
|
||||||
scenario, currentRoute, isSavingNavigation, optionalQuery, optionalParams, optionalPageData
|
|
||||||
);
|
|
||||||
next();
|
next();
|
||||||
};
|
};
|
||||||
|
|
||||||
router.navigate = (
|
router.navigate = (scenario, currentRoute, optionalQuery = {}, optionalParams = {}, optionalPageData = {}) => {
|
||||||
scenario, currentRoute, optionalQuery = {}, optionalParams = {}, optionalPageData = {}
|
navigate(scenario, currentRoute, optionalQuery, optionalParams, optionalPageData);
|
||||||
) => {
|
|
||||||
navigate(
|
|
||||||
scenario, currentRoute, optionalQuery, optionalParams, optionalPageData
|
|
||||||
);
|
|
||||||
};
|
};
|
||||||
|
|
||||||
// Navigate to the next route, depending on the scenario.
|
// Navigate to the next route, depending on the scenario.
|
||||||
function navigate(
|
function navigate(scenario, currentRoute, optionalQuery = {}, optionalParams = {}, optionalPageData = {}) {
|
||||||
scenario, currentRoute, optionalQuery = {}, optionalParams = {}, optionalPageData = {}
|
|
||||||
) {
|
|
||||||
/*eslint-disable-line*/
|
/*eslint-disable-line*/
|
||||||
if (!scenario) {
|
if (!scenario) {
|
||||||
window.console.error('No scenario provided. Please review the routing table.');
|
window.console.error('No scenario provided. Please review the routing table.');
|
||||||
|
|
@ -200,8 +192,10 @@ function navigate(
|
||||||
} else if (matchingScenarioMap.destinationIssPageValue) {
|
} else if (matchingScenarioMap.destinationIssPageValue) {
|
||||||
// Update page data to the store for next page if provided. Otherwise, keep existing page data or set to empty object
|
// Update page data to the store for next page if provided. Otherwise, keep existing page data or set to empty object
|
||||||
const existingPageDataForPage = useMainStore().pageData(matchingScenarioMap.destinationIssPageValue);
|
const existingPageDataForPage = useMainStore().pageData(matchingScenarioMap.destinationIssPageValue);
|
||||||
baseMixin.methods.savePageDataToStore(matchingScenarioMap.destinationIssPageValue,
|
baseMixin.methods.savePageDataToStore(
|
||||||
Object.keys(optionalPageData).length > 0 ? optionalPageData : existingPageDataForPage ?? {});
|
matchingScenarioMap.destinationIssPageValue,
|
||||||
|
Object.keys(optionalPageData).length > 0 ? optionalPageData : existingPageDataForPage ?? {}
|
||||||
|
);
|
||||||
|
|
||||||
// We're always pushing the same path, just changing query strings.
|
// We're always pushing the same path, just changing query strings.
|
||||||
// Make sure our optional query strings get combined with our issPage one.
|
// Make sure our optional query strings get combined with our issPage one.
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue