Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions lib/project-data.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,10 @@ export class ProjectData implements IProjectData {
type: "Angular",
requiredDependencies: ["@angular/core", "nativescript-angular"]
},
{
type: "Vue.js",
requiredDependencies: ["nativescript-vue"]
},
{
type: "Pure TypeScript",
requiredDependencies: ["typescript", "nativescript-dev-typescript"]
Expand Down
8 changes: 8 additions & 0 deletions test/project-data.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,14 @@ describe("projectData", () => {
assertProjectType({ "nativescript-angular": "*" }, null, "Angular");
});

it("detects project as Vue.js when nativescript-vue exists as dependency", () => {
assertProjectType({ "nativescript-vue": "*" }, null, "Vue.js");
});

it("detects project as Vue.js when nativescript-vue exists as dependency and typescript is devDependency", () => {
assertProjectType({ "nativescript-vue": "*" }, { "typescript": "*" }, "Vue.js");
});

it("detects project as TypeScript when nativescript-dev-typescript exists as dependency", () => {
assertProjectType(null, { "nativescript-dev-typescript": "*" }, "Pure TypeScript");
});
Expand Down