Skip to content

Commit

Permalink
chore: convert lint warnings to errors (freeCodeCamp#347)
Browse files Browse the repository at this point in the history
  • Loading branch information
ojeytonwilliams authored Nov 20, 2023
1 parent 866851e commit 46158f9
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion apps/frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"build": "next build",
"dev": "next dev",
"develop": "npm run dev",
"eslint": "next lint",
"eslint": "next lint --max-warnings 0",
"format": "prettier --write .",
"init": "shx cp -n sample.env .env",
"prettier-check": "prettier --check .",
Expand Down
2 changes: 1 addition & 1 deletion apps/frontend/src/components/editor-drawer.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ const EditorDrawer = ({

setAuthorName(post.attributes.author.data.attributes.name);
}
}, [post]);
}, [post, handlePostTagId]);

const handleFileInputChange = (event) => {
const file = event.target.files[0];
Expand Down
4 changes: 2 additions & 2 deletions apps/frontend/src/components/post-form.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,10 @@ const PostForm = ({ tags, user, authors, post }) => {
setUnsavedChanges(true);
};

const handlePostTagId = (value) => {
const handlePostTagId = useCallback((value) => {
setPostTagId([...value]);
setUnsavedChanges(true);
};
}, []);

const handleAuthorChange = (author) => {
setAuthor(author);
Expand Down

0 comments on commit 46158f9

Please sign in to comment.