Spaces:
Configuration error
Configuration error
Download frontend/src/components/features/github/code-not-in-github-link.tsx from flyingdarkdev/README: direct link, hf CLI and curl.
- Browser
- Download file 912 Bytes
-
https://huggingface.co/spaces/flyingdarkdev/README/resolve/main/frontend/src/components/features/github/code-not-in-github-link.tsx
- Command line
-
hf download hf://spaces/flyingdarkdev/README/frontend/src/components/features/github/code-not-in-github-link.tsx
-
curl -L -o code-not-in-github-link.tsx https://huggingface.co/spaces/flyingdarkdev/README/resolve/main/frontend/src/components/features/github/code-not-in-github-link.tsx
912 Bytes
| import React from "react"; | |
| import { useDispatch } from "react-redux"; | |
| import { useCreateConversation } from "#/hooks/mutation/use-create-conversation"; | |
| import { setInitialPrompt } from "#/state/initial-query-slice"; | |
| const INITIAL_PROMPT = ""; | |
| export function CodeNotInGitHubLink() { | |
| const dispatch = useDispatch(); | |
| const { mutate: createConversation } = useCreateConversation(); | |
| const handleStartFromScratch = () => { | |
| // Set the initial prompt and create a new conversation | |
| dispatch(setInitialPrompt(INITIAL_PROMPT)); | |
| createConversation({ q: INITIAL_PROMPT }); | |
| }; | |
| return ( | |
| <div className="text-xs text-neutral-400"> | |
| Code not in GitHub?{" "} | |
| <span | |
| onClick={handleStartFromScratch} | |
| className="underline cursor-pointer" | |
| > | |
| Start from scratch | |
| </span>{" "} | |
| and use the VS Code link to upload and download your code. | |
| </div> | |
| ); | |
| } | |