Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Answer:1 projection with signals and all v17 features #775

Closed
wants to merge 3 commits into from

Conversation

tomalaforge
Copy link
Owner

solution projection

  • with signals and signals queries
  • strongly typed template outlet

@tomalaforge tomalaforge added 1 exercice projection answer author answer of author labels Apr 14, 2024
@github-actions github-actions bot added answer answer contributor highly contributing to the project labels Apr 14, 2024
@tomalaforge tomalaforge removed answer answer contributor highly contributing to the project labels Apr 14, 2024
@tomalaforge tomalaforge changed the title Answer:1 projection Answer:1 projection with signals and all v17 features Apr 15, 2024
@github-actions github-actions bot added contributor highly contributing to the project answer answer labels Apr 15, 2024
@tomalaforge tomalaforge removed answer answer contributor highly contributing to the project labels Apr 15, 2024
}

addOne(student: Student) {
this.students.next([...this.students.value, student]);
this.students.set([...this.students(), student]);
Copy link
Contributor

Choose a reason for hiding this comment

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

Why not use update here?

Choose a reason for hiding this comment

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

you can use "update" too to get previous value and add new student, but since u current have the students list, u can also use the set() method

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1 exercice projection answer author answer of author
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants