Download wp-calypso/client/dashboard/data/site-launchpad.tsx from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 462 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/wp-calypso/client/dashboard/data/site-launchpad.tsx
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset/wp-calypso/client/dashboard/data/site-launchpad.tsx
-
curl -L -o site-launchpad.tsx https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/wp-calypso/client/dashboard/data/site-launchpad.tsx
462 Bytes
| import wpcom from 'calypso/lib/wp'; | |
| export interface LaunchpadTask { | |
| completed: boolean; | |
| } | |
| export interface Launchpad { | |
| checklist?: LaunchpadTask[] | null; | |
| } | |
| export async function fetchSiteLaunchpad( | |
| siteId: number, | |
| checklistSlug: string | |
| ): Promise< Launchpad > { | |
| return wpcom.req.get( | |
| { | |
| path: `/sites/${ siteId }/launchpad`, | |
| apiNamespace: 'wpcom/v2', | |
| }, | |
| { | |
| checklist_slug: checklistSlug, | |
| launchpad_context: 'sites-dashboard', | |
| } | |
| ); | |
| } | |