File tree Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -90,6 +90,7 @@ const fs = require("fs");
9090/* NOTE: all fields are optional expect one of `output`, `url`, `spec` */
9191generateApi ({
9292 name: " MySuperbApi.ts" ,
93+ // set to `false` to prevent the tool from writing to disk
9394 output: path .resolve (process .cwd (), " ./src/__generated__" ),
9495 url: ' http://api.com/swagger.json' ,
9596 input: path .resolve (process .cwd (), ' ./foo/swagger.json' ),
Original file line number Diff line number Diff line change @@ -5,9 +5,12 @@ interface GenerateApiParamsBase {
55 name ?: string ;
66
77 /**
8- * path to folder where will been located the created api module
8+ * path to folder where will been located the created api module.
9+ *
10+ * may set to `false` to skip writing content to disk. in this case,
11+ * you may access the `files` on the return value.
912 */
10- output ?: string ;
13+ output ?: string | false ;
1114
1215 /**
1316 * path to folder containing templates (default: ./src/templates)
You can’t perform that action at this time.
0 commit comments