Skip to content

Commit a56da04

Browse files
authored
Typescript schema (#8)
* Rename Package * Remove Mongoose Schema Choice, It's must * Update Readme File * Temporary Disable Typescript Schema Option * Create Schema Within the root
1 parent 3d2d168 commit a56da04

File tree

2 files changed

+11
-10
lines changed

2 files changed

+11
-10
lines changed

src/cli.js

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -35,15 +35,16 @@ async function promptForMissingOptions(options) {
3535
// }
3636

3737
const questions = [];
38-
if (!options.language) {
39-
questions.push({
40-
type: "list",
41-
name: "language",
42-
message: "Please choose which language Schema to use",
43-
choices: ["JavaScript", "TypeScript"],
44-
default: defaultOptions.language,
45-
});
46-
}
38+
//@TODO: Temporary Disabled, Uncomment after adding Typescript Schema
39+
// if (!options.language) {
40+
// questions.push({
41+
// type: "list",
42+
// name: "language",
43+
// message: "Please choose which language Schema to use",
44+
// choices: ["JavaScript", "TypeScript"],
45+
// default: defaultOptions.language,
46+
// });
47+
// }
4748

4849
questions.push({
4950
type: "input",

src/main.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ async function createSchema(options, schemaKeyValues) {
1212
const schemaOptions = {
1313
...options,
1414
dirPath: path.resolve(__dirname, "../template"),
15-
outPath: path.resolve(process.cwd(), "./models/"`./${options.schema}.js`),
15+
outPath: path.resolve(process.cwd(), `./${options.schema}.js`),
1616
};
1717

1818
console.log();

0 commit comments

Comments
 (0)