File tree Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change 1
1
quicksnip
2
2
slugifyed
3
- sublanguage
3
+ sublanguage
4
+ fastapi
Original file line number Diff line number Diff line change @@ -8,6 +8,11 @@ import { SnippetType } from "@types";
8
8
import { LeftAngleArrowIcon } from "./Icons" ;
9
9
import SnippetModal from "./SnippetModal" ;
10
10
11
+ const extensions : { [ key : string ] : string } = {
12
+ REACT : "tsx" ,
13
+ FASTAPI : "py" ,
14
+ } ;
15
+
11
16
const SnippetList = ( ) => {
12
17
const { language, snippet, setSnippet } = useAppContext ( ) ;
13
18
const { fetchedSnippets } = useSnippets ( ) ;
@@ -87,7 +92,7 @@ const SnippetList = () => {
87
92
< SnippetModal
88
93
snippet = { snippet }
89
94
handleCloseModal = { handleCloseModal }
90
- language = { language . name }
95
+ language = { extensions [ language . name ] || language . name }
91
96
/>
92
97
) }
93
98
</ AnimatePresence >
You can’t perform that action at this time.
0 commit comments