{"id":21307779,"url":"https://github.com/jdegand/default-onpush","last_synced_at":"2026-05-09T19:03:40.128Z","repository":{"id":194632460,"uuid":"690820306","full_name":"jdegand/default-onpush","owner":"jdegand","description":"Angular Challenges #34 Default vs OnPush","archived":false,"fork":false,"pushed_at":"2024-03-31T03:46:32.000Z","size":126,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-15T20:13:19.171Z","etag":null,"topics":["angular","angular-challenges","angular-material","change-detection","tailwind"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jdegand.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-09-13T00:25:53.000Z","updated_at":"2023-09-13T00:36:25.000Z","dependencies_parsed_at":"2024-11-21T16:38:00.232Z","dependency_job_id":"be3cd417-8482-45f7-91fa-e2c94252e5f0","html_url":"https://github.com/jdegand/default-onpush","commit_stats":{"total_commits":4,"total_committers":1,"mean_commits":4.0,"dds":0.0,"last_synced_commit":"5110957b1e7decdf0c50b6dc0256bbc384874134"},"previous_names":["jdegand/default-onpush"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/jdegand/default-onpush","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jdegand%2Fdefault-onpush","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jdegand%2Fdefault-onpush/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jdegand%2Fdefault-onpush/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jdegand%2Fdefault-onpush/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jdegand","download_url":"https://codeload.github.com/jdegand/default-onpush/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jdegand%2Fdefault-onpush/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":268308964,"owners_count":24230163,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-01T02:00:08.611Z","response_time":67,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["angular","angular-challenges","angular-material","change-detection","tailwind"],"created_at":"2024-11-21T16:34:08.020Z","updated_at":"2026-05-09T19:03:35.064Z","avatar_url":"https://github.com/jdegand.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Default Onpush\n\n[Angular Challenges](https://github.com/tomalaforge/angular-challenges) #34 Default vs OnPush\n\n## Built With\n\n- [Angular](https://angular.io)\n- [Angular CLI](https://github.com/angular/angular-cli) version 16.2.0.\n\n## Directions\n\nIn this challenge, we will explore the differences and impacts of using ChangeDetectionStrategy.Default versus ChangeDetectionStrategy.OnPush. To provide a clearer demonstration, I have added color enlightment to each component and each row in our application. However, in real-world scenarios, you will not have such visualization. This is where the [Angular DevTools profiler](https://chrome.google.com/webstore/detail/angular-devtools/ienfalfjdbdpebioblfackkekamfmbnh) comes to the rescue.\n\n### Statement\n\nThe goal of this challenge is to improve the clustering of change detection within the application.\n\n## Thoughts\n\n- Adding ChangeDetection.onPush seemed to help limit MatFormField from re-rendering but PersonListComponent was unaffected.\n- PersonListComponent is the one changing the most.  \n- I took the gap after `\u003capp-random\u003e` in app.component as a hint as to where an input component should go. \n\n```html\n\n    \u003capp-random /\u003e\n  \n    \u003cdiv class=\"flex\"\u003e\n      \u003capp-person-list [names]=\"girlList\" title=\"Female\" /\u003e\n      \u003capp-person-list [names]=\"boyList\" title=\"Male\" /\u003e\n    \u003c/div\u003e\n```\n\n## Useful Resources\n\n- [byby](https://byby.dev/at-rule-tailwind) - @tailwind workarounds \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjdegand%2Fdefault-onpush","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjdegand%2Fdefault-onpush","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjdegand%2Fdefault-onpush/lists"}