|
Download wp-calypso/client/components/data/query-email-accounts/README.md from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 839 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/wp-calypso/client/components/data/query-email-accounts/README.md
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset/wp-calypso/client/components/data/query-email-accounts/README.md
-
curl -L -o README.md https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/wp-calypso/client/components/data/query-email-accounts/README.md
839 Bytes
Query Email Accounts
<QueryEmailAccounts /> is a React component used in managing network requests for all Email Accounts across providers for a site.
Usage
Render the component, passing in the properties below. It does not accept any children, nor does it render any elements to the page.
import QueryEmailAccounts from 'calypso/components/data/query-email-accounts';
export default function listEmailAccounts( { emailAccounts } ) {
return (
<div>
<QueryEmailAccounts siteId={ siteId } />
{ emailAccounts.map( ( emailAccount ) => (
<li>{ `${ emailAccount.mailbox }@${ emailAccount.domain }` }</li>
) ) }
</div>
);
}
Props
siteId
| Type | Number |
|---|---|
| Required | Yes |
The ID of the site to fetch the email accounts users for.