{"id":15022911,"url":"https://github.com/ember-polyfills/ember-router-service-refresh-polyfill","last_synced_at":"2025-10-24T20:32:13.041Z","repository":{"id":41903594,"uuid":"349238091","full_name":"ember-polyfills/ember-router-service-refresh-polyfill","owner":"ember-polyfills","description":"Polyfill for RFC 631 https://emberjs.github.io/rfcs/0631-refresh-method-for-router-service.html","archived":false,"fork":false,"pushed_at":"2022-11-15T17:13:42.000Z","size":505,"stargazers_count":11,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-10-05T15:53:42.237Z","etag":null,"topics":["ember","emberjs","polyfill"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ember-polyfills.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-03-18T22:50:34.000Z","updated_at":"2024-05-30T03:14:00.000Z","dependencies_parsed_at":"2022-08-11T20:40:56.637Z","dependency_job_id":null,"html_url":"https://github.com/ember-polyfills/ember-router-service-refresh-polyfill","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ember-polyfills%2Fember-router-service-refresh-polyfill","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ember-polyfills%2Fember-router-service-refresh-polyfill/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ember-polyfills%2Fember-router-service-refresh-polyfill/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ember-polyfills%2Fember-router-service-refresh-polyfill/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ember-polyfills","download_url":"https://codeload.github.com/ember-polyfills/ember-router-service-refresh-polyfill/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":219868660,"owners_count":16555694,"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","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":["ember","emberjs","polyfill"],"created_at":"2024-09-24T19:58:31.262Z","updated_at":"2025-10-24T20:32:12.281Z","avatar_url":"https://github.com/ember-polyfills.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"ember-router-service-refresh-polyfill\n==============================================================================\n\nPolyfills the RouterService#refresh method as described in [RFC 631](https://emberjs.github.io/rfcs/0631-refresh-method-for-router-service.html).\n\n\nCompatibility\n------------------------------------------------------------------------------\n\n* Ember.js v3.4 or above. The polyfill is disabled in Ember 4.1 and above.\n* Ember CLI v3.4 or above\n* Embroider safe and optimized\n* Node.js v12 or above\n\n\nInstallation\n------------------------------------------------------------------------------\n\n```\nember install ember-router-service-refresh-polyfill\n```\n\n\nUsage\n------------------------------------------------------------------------------\n\nThis addon polyfills the RouterService#refresh method which refreshes all currently active routes, doing a full transition.\n\nIf a `routeName` is provided and refers to a currently active route,\nit will refresh only that route and its descendents.\n\nIt returns a [Transition](https://api.emberjs.com/ember/release/classes/Transition) that will be resolved once the refresh is complete.\nAll resetController, beforeModel, model, afterModel, redirect, and setupController\nhooks will be called again. You will get new data from the model hook.\n\n### Example\n\n```js\nimport { action } from '@ember/object';\nimport { inject as service } from '@ember/service';\nimport Component from '@glimmer/component';\n\nexport default class VeryRealComponent extends Component {\n  @service('router') routerService;\n\n  @action\n  refreshAllActiveRoutes() {\n    this.routerService.refresh();\n  }\n\n  @action\n  refreshNamedActiveRoute() {\n    this.routerService.refresh('some-active-route-name');\n  }\n}\n```\n\nContributing\n------------------------------------------------------------------------------\n\nSee the [Contributing](CONTRIBUTING.md) guide for details.\n\n\nLicense\n------------------------------------------------------------------------------\n\nThis project is licensed under the [MIT License](LICENSE.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fember-polyfills%2Fember-router-service-refresh-polyfill","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fember-polyfills%2Fember-router-service-refresh-polyfill","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fember-polyfills%2Fember-router-service-refresh-polyfill/lists"}