Skip to content

Commit

Permalink
Update JSDoc comments
Browse files Browse the repository at this point in the history
  • Loading branch information
yscik committed Jun 2, 2020
1 parent 1a77c28 commit 31e634c
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 6 deletions.
2 changes: 1 addition & 1 deletion assets/onboarding/data/actions.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,8 @@ export const startSubmit = ( step, stepData ) => ( {
/**
* Success submit action creator.
*
* @return {{type: string}} Success submit action.
* @param {string} step Completed step.
* @return {{type: string, step: string}} Success submit action.
*/
export const successSubmit = ( step ) => ( {
type: SUCCESS_SUBMIT_SETUP_WIZARD_DATA,
Expand Down
6 changes: 4 additions & 2 deletions assets/onboarding/navigation/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,10 @@ import { useQueryStringRouter } from '../query-string-router';
/**
* Go to route when clicking steps that can be active (completed or next).
*
* @param {Array} steps
* @param {Function} goTo
* @param {Array} steps
* @param {Object} deps
* @param {Function} deps.goTo
*
* @return {Array} Steps with click handlers.
*/
const addClickHandlers = ( steps, { goTo } ) =>
Expand Down
5 changes: 3 additions & 2 deletions assets/onboarding/query-string-router/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,9 @@ const QueryStringRouterContext = createContext();
* - `goTo`: Functions that send the user to another route.
*
* @param {Object} props
* @param {string} props.paramName Param used as reference in the query string.
* @param {Object} props.children Render this children if it matches the route.
* @param {string} props.paramName Param used as reference in the query string.
* @param {string} props.defaultRoute Default route to open if there is nothing in the URL.
* @param {Object} props.children Render this children if it matches the route.
*/
const QueryStringRouter = ( { paramName, defaultRoute, children } ) => {
// Current route.
Expand Down
1 change: 0 additions & 1 deletion assets/onboarding/query-string-router/route.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import { useQueryStringRouter } from './index';
*
* @param {Object} props
* @param {string} props.route Route name.
* @param {boolean} props.defaultRoute Flag if it is the default route.
* @param {Object} props.children Render this children if it matches the route.
*
* @return {Object|null} Return the children if the routes match. Otherwise return null.
Expand Down

0 comments on commit 31e634c

Please sign in to comment.