Skip to content

Conversation

@SeyedMojtaba1
Copy link
Collaborator

related #51

@SeyedMojtaba1 SeyedMojtaba1 linked an issue Dec 5, 2024 that may be closed by this pull request
this.name = n;
}

abstract get get_name(): string;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. You don't need a getter here, otherwise you have to access it like concept.get_name instead of concept.get_name(), which is unexpected—this should be fixed for all occurrences
  2. In JS, method names are camelCase by convention, not snake_case
  3. Is there a need to mark this method as abstract?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I fixed it.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In some other places, you still have used getters/setters, which is unexpected.

import { concept } from "./Concept";

class devConcept extends concept {
constructor(n: string, b: "architecture" | "clean-code" | "languages") {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This class doesn't need a name param. It's name is always devConcept.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that I didn't understand it.
But I fixed it.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's discuss it in our meeting.

Copy link
Collaborator

@mkermani144 mkermani144 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please address the new comments.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

TS: OOP

3 participants