@wordpress/e2e-test-utils
Version:
End-To-End (E2E) test utils for WordPress.
15 lines (14 loc) • 441 B
JavaScript
/**
* Internal dependencies
*/
import { wpDataSelect } from './wp-data-select';
/**
* Returns a promise which resolves with the current post content (HTML string).
*
* @return {Promise} Promise resolving with current post content markup.
*/
export async function getCurrentPostContent() {
const post = await wpDataSelect('core/editor', 'getCurrentPost');
return post.content;
}
//# sourceMappingURL=get-current-post-content.js.map