@@ -15,20 +15,20 @@ npm i @tsukiroku/gist
1515> Account token required. See [ Docs] ( https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token )
1616
1717``` ts
18- import Gist from " @tsukiroku/gist" ;
18+ import Gist from ' @tsukiroku/gist' ;
1919
20- const gist = new Gist (" token" );
20+ const gist = new Gist (' token' );
2121```
2222
2323<br >
2424
2525## Create Gist
2626
27- | Parameter | Type |
28- | ------------- | ----------- |
29- | ` files ` | ` GistFile ` |
30- | ` description ` | ` string ` |
31- | ` options ` | ` GistOptions ` |
27+ | Parameter | Type |
28+ | ------------- | ------------- |
29+ | ` files ` | ` GistFile ` |
30+ | ` description ` | ` string ` |
31+ | ` options ` | ` GistOptions ` |
3232
3333> ** GistFile**
3434>
@@ -50,10 +50,10 @@ const gist = new Gist("token");
5050await gist
5151 .create (
5252 {
53- file_name: { content: " File Content" },
54- file_name_2: { content: " File Content 2" },
53+ file_name: { content: ' File Content' },
54+ file_name_2: { content: ' File Content 2' },
5555 },
56- " test file"
56+ ' test file'
5757 // { secret: true }
5858 )
5959 .then ((res ) => {
@@ -66,15 +66,15 @@ await gist
6666
6767## Get Gist
6868
69- | Parameter | Type |
70- | --------- | ------ |
71- | ` id ` | ` number ` |
69+ | Parameter | Type |
70+ | --------- | -------- |
71+ | ` id ` | ` number ` |
7272
7373> ** return:** [ ` Promise<GistResponse> ` ] ( ./src/types.ts )
7474
7575``` ts
7676await gist
77- .get (" gist id" )
77+ .get (' gist id' )
7878 .then ((res ) => console .log (` gist description: ${res .description } ` ))
7979 .catch ((err ) => console .log (err ));
8080```
@@ -83,14 +83,14 @@ await gist
8383
8484## Delete Gist
8585
86- | Parameter | Type |
87- | --------- | ------ |
88- | ` id ` | ` number ` |
86+ | Parameter | Type |
87+ | --------- | -------- |
88+ | ` id ` | ` number ` |
8989
9090``` ts
9191await gist
92- .delete (" gist id" )
93- .then ((_ ) => console .log (" deleted" ))
92+ .delete (' gist id' )
93+ .then ((_ ) => console .log (' deleted' ))
9494 .catch ((err ) => console .log (err ));
9595```
9696
@@ -103,20 +103,20 @@ await gist
103103# Example
104104
105105``` ts
106- import Gist from " @tsukiroku/gist" ;
106+ import Gist from ' @tsukiroku/gist' ;
107107
108108(async () => {
109- const gist = new Gist (" token" );
109+ const gist = new Gist (' token' );
110110
111- let gist_id: string = " " ;
111+ let gist_id: string = ' ' ;
112112
113113 await gist
114114 .create (
115115 {
116- " index.ts" : { content: " console.log('Hello, World!');" },
117- " main.rs" : { content: " fn main() {}" },
116+ ' index.ts' : { content: " console.log('Hello, World!');" },
117+ ' main.rs' : { content: ' fn main() {}' },
118118 },
119- " test gist" ,
119+ ' test gist' ,
120120 { secret: true }
121121 )
122122 .then ((res ) => {
@@ -132,7 +132,7 @@ import Gist from "@tsukiroku/gist";
132132
133133 await gist
134134 .delete (gist_id )
135- .then ((_ ) => console .log (" deleted" ))
135+ .then ((_ ) => console .log (' deleted' ))
136136 .catch ((err ) => console .log (err ));
137137})();
138138```
0 commit comments