Download wp-calypso/client/state/comments/selectors/get-post-comment-items.js from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 365 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/wp-calypso/client/state/comments/selectors/get-post-comment-items.js
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset/wp-calypso/client/state/comments/selectors/get-post-comment-items.js
-
curl -L -o get-post-comment-items.js https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/wp-calypso/client/state/comments/selectors/get-post-comment-items.js
365 Bytes
| import 'calypso/state/comments/init'; | |
| /** | |
| * Gets comment items for post | |
| * @param {Object} state redux state | |
| * @param {number} siteId site identification | |
| * @param {number} postId site identification | |
| * @returns {Array} comment items | |
| */ | |
| export function getPostCommentItems( state, siteId, postId ) { | |
| return state.comments.items[ `${ siteId }-${ postId }` ]; | |
| } | |