Skip to content

Commit

Permalink
Merge pull request #4238 from Automattic/update/wordpress-scripts
Browse files Browse the repository at this point in the history
Update @wordpress/scripts and JSDoc alignments
  • Loading branch information
renatho authored Jul 5, 2021
2 parents d1b4a17 + 859284e commit 99cbb9d
Show file tree
Hide file tree
Showing 8 changed files with 8,650 additions and 8,234 deletions.
13 changes: 11 additions & 2 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,17 @@ module.exports = {
},
],
'import/no-extraneous-dependencies': 'off',
'jsdoc-alignment/lines-alignment': 'error',
'jsdoc/check-line-alignment': [
'warn',
'always',
{
tags: [ 'param', 'arg', 'argument', 'property', 'prop' ],
preserveMainDescriptionPostDelimiter: true,
},
],
'jsdoc/require-yields': 'off',
'jsdoc/tag-lines': 'off',
'react-hooks/exhaustive-deps': 'warn',
},
plugins: [ 'jest', 'jsdoc-alignment' ],
plugins: [ 'jest' ],
};
2 changes: 1 addition & 1 deletion assets/data-port/import/data/normalizer.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ export const parseCompletedSteps = ( data ) => {
};

/**
* * Normalize importer data.
* Normalize importer data.
*
* @param {Object} input Importer data.
* @param {number} input.id The job id.
Expand Down
10 changes: 5 additions & 5 deletions assets/data-port/import/data/reducer.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,9 @@ const DEFAULT_STATE = {

/**
*
* @param {Object} state Current state.
* @param {{type: string}} levelKey Level to update.
* @param {Object} attributes Attributes to set.
* @param {Object} state Current state.
* @param {{type: string}} levelKey Level to update.
* @param {Object} attributes Attributes to set.
* @return {Object} State updated.
*/
const updateLevelState = ( state, levelKey, attributes ) => ( {
Expand All @@ -86,8 +86,8 @@ const updateLevelState = ( state, levelKey, attributes ) => ( {
/**
* Data importer reducer.
*
* @param {Object} state Current state.
* @param {{type: string}} action Action to update the state.
* @param {Object} state Current state.
* @param {{type: string}} action Action to update the state.
*
* @return {Object} State updated.
*/
Expand Down
4 changes: 1 addition & 3 deletions assets/js/grading-general.js
Original file line number Diff line number Diff line change
Expand Up @@ -178,9 +178,7 @@ jQuery( document ).ready( function ( $ ) {
};

/**
* Resets all graded questions
* @param obj scope Scope of questions to reset
* @return void
* Resets all graded questions.
*/
jQuery.fn.resetGrades = function () {
jQuery( '.question_box' )
Expand Down
2 changes: 1 addition & 1 deletion assets/js/modules-admin.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*
* Credit: http://stackoverflow.com/questions/901115/how-can-i-get-query-string-values-in-javascript
*
* @param name
* @param {string} name
* @returns {string}
*/

Expand Down
4 changes: 2 additions & 2 deletions assets/setup-wizard/data/reducer.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,8 @@ const updatePreInstallation = ( selected, options ) =>
/**
* Setup wizard reducer.
*
* @param {Object} state Current state.
* @param {{type: string}} action Action to update the state.
* @param {Object} state Current state.
* @param {{type: string}} action Action to update the state.
*
* @return {Object} State updated.
*/
Expand Down
Loading

0 comments on commit 99cbb9d

Please sign in to comment.