Download wp-calypso/client/lib/jetpack/trigger-scan-run.ts from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 522 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/wp-calypso/client/lib/jetpack/trigger-scan-run.ts
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset/wp-calypso/client/lib/jetpack/trigger-scan-run.ts
-
curl -L -o trigger-scan-run.ts https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/wp-calypso/client/lib/jetpack/trigger-scan-run.ts
522 Bytes
| import { recordTracksEvent } from 'calypso/state/analytics/actions'; | |
| import { | |
| requestJetpackScanEnqueue, | |
| startScanOptimistically, | |
| } from 'calypso/state/jetpack-scan/enqueue/actions'; | |
| import type { Dispatch } from 'redux'; | |
| export const triggerScanRun = | |
| ( siteId: number ) => | |
| ( dispatch: Dispatch< any > ): void => { | |
| dispatch( | |
| recordTracksEvent( 'calypso_jetpack_scan_run', { | |
| site_id: siteId, | |
| } ) | |
| ); | |
| dispatch( requestJetpackScanEnqueue( siteId ) ); | |
| dispatch( startScanOptimistically( siteId ) ); | |
| }; | |