App component PropTypes needs documentation
Closed this issue · 1 comments
b5 commented
Most (all?) of our component PropTypes are under-documented. We should expand those with inline comments so these props are a little clearer. I think starting at the top with App.js
makes the most sense:
Let's add these comments:
App.propTypes = {
// flag for unsaved changes to the editor
editorDirty: PropTypes.bool,
// application-wide error message shown in a flash message eg: "dataset not found"
errorMessage: PropTypes.string,
// application-wide message shown in a flash message eg: "dataset renamed"
message: PropTypes.string,
// react-router provided children
children: PropTypes.node,
// currently logged-in user session profile ID
sessionProfile: PropTypes.string,
// dismiss error message
resetErrorMessage: PropTypes.func.isRequired,
// dismiss message
resetMessage: PropTypes.func.isRequired,
// hide the main menu. not currently in use
hideMenu: PropTypes.func.isRequired,
// fetch the current user profile
loadSessionProfile: PropTypes.func.isRequired,
// api connection status indicator
apiConnection: PropTypes.number.isRequired,
// navigate back in browser history
goBack: PropTypes.func,
// navigate forward in browser history
goForward: PropTypes.func
}
Steps to complete:
- Fork this repo
- Read DEVELOPER.md to set up your dev environment
- Get Qri up & running locally.
- run
qri connect --disable-webapp
in one terminal - from the frontend repo folder run
yarn web:dev
in a separate terminal, openlocalhost:2505
in a browser to see live changes whenever you save files in the frontend repo.
- Write a commit that adds the comments outlined in this issue, be sure to follow our commit guidelines. Something like
docs(app): document app component PropTypes
would work great. - Open a Pull Request!