{"id":16433843,"url":"https://github.com/gund/ngx-router-meta","last_synced_at":"2025-10-27T02:30:46.503Z","repository":{"id":35097457,"uuid":"201142781","full_name":"gund/ngx-router-meta","owner":"gund","description":"Configure HTML meta tags like title and description in route configuration of Angular for SSR","archived":false,"fork":false,"pushed_at":"2022-12-10T00:55:25.000Z","size":1287,"stargazers_count":4,"open_issues_count":2,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-07T21:05:25.410Z","etag":null,"topics":["angular","configuration","description","meta-tags","metadata","router","seo-optimization","ssr","title"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/gund.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-08-07T23:34:08.000Z","updated_at":"2024-01-22T10:03:03.000Z","dependencies_parsed_at":"2023-01-15T13:47:34.636Z","dependency_job_id":null,"html_url":"https://github.com/gund/ngx-router-meta","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gund%2Fngx-router-meta","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gund%2Fngx-router-meta/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gund%2Fngx-router-meta/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gund%2Fngx-router-meta/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gund","download_url":"https://codeload.github.com/gund/ngx-router-meta/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":238422801,"owners_count":19469619,"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":["angular","configuration","description","meta-tags","metadata","router","seo-optimization","ssr","title"],"created_at":"2024-10-11T08:47:24.259Z","updated_at":"2025-10-27T02:30:41.197Z","avatar_url":"https://github.com/gund.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# NgxRouterMeta\n\n[![Build Status](https://travis-ci.org/gund/ngx-router-meta.svg?branch=master)](https://travis-ci.org/gund/ngx-router-meta)\n[![codecov](https://codecov.io/gh/gund/ngx-router-meta/branch/master/graph/badge.svg)](https://codecov.io/gh/gund/ngx-router-meta)\n[![Maintainability](https://api.codeclimate.com/v1/badges/75faccce723e7021b790/maintainability)](https://codeclimate.com/github/gund/ngx-router-meta/maintainability)\n[![Npm](https://img.shields.io/npm/v/ngx-router-meta.svg)](https://www.npmjs.com/package/ngx-router-meta)\n[![Npm Downloads](https://img.shields.io/npm/dt/ngx-router-meta.svg)](https://www.npmjs.com/package/ngx-router-meta)\n![Size](https://badgen.net/bundlephobia/minzip/ngx-router-meta)\n[![Licence](https://img.shields.io/npm/l/ngx-router-meta.svg?maxAge=2592000)](https://github.com/gund/ngx-router-meta/blob/master/LICENSE)\n[![semantic-release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg)](https://github.com/semantic-release/semantic-release)\n\n\u003e Configure HTML meta tags in route configuration of Angular for SSR\n\n## Features\n\n- Native support for SSR - so all meta data will be served to any crawler\n- Declarative configuration of meta tags without any restrictions\n- Templating in strings with dynamic data from context\n- Global templates for any type of meta tag\n- Contexts can be either plain objects or RxJs Observables of objects\n- Default (global) and local contexts (reset after every route navigation)\n\n## Install\n\n```\nnpm install ngx-router-meta\n```\n\n## Configure\n\n1. Just import `RouterMetaModule.forRoot()` in your `AppModule`:\n\n```ts\nimport { NgModule } from '@angular/core';\nimport { RouterMetaModule } from 'ngx-router-meta';\n\n@NgModule({\n  imports: [RouterMetaModule.forRoot()],\n})\nexport class AppModule {}\n```\n\n2. And then configure give your routes some ~~love~~ meta info:  \n   **TIP**: You can use `RoutesWithMeta` instead of default `Routes` type\n   from `@angular/router` package for extra type info!\n\n```ts\nimport { NgModule } from '@angular/core';\nimport { RouterModule } from '@angular/router';\nimport { RoutesWithMeta } from 'ngx-router-meta';\n\nimport { ShowRouteComponent } from './show-route.component';\n\nconst routes: RoutesWithMeta = [\n  {\n    path: '',\n    component: ShowRouteComponent,\n    data: {\n      meta: {\n        title: 'Home Page',\n        description: 'Tell everyone about your home!',\n      },\n    },\n  },\n  {\n    path: 'route1',\n    component: ShowRouteComponent,\n    data: {\n      meta: {\n        title: 'Route 1 Page',\n        'custom:tag': 'Works!',\n      },\n    },\n  },\n  {\n    path: 'route2',\n    component: ShowRouteComponent,\n    // Look, these tags are not even required, yay!!\n  },\n];\n```\n\n3. Serve your app (even with SSR) and enjoy your meta!\n\n## Documentation\n\n**Coming really soon =)**\n\n---\n\nThis project was generated with [Angular CLI](https://github.com/angular/angular-cli) version 8.2.0.\n\n## Development server\n\nRun `ng serve` for a dev server. Navigate to `http://localhost:4200/`. The app will automatically reload if you change any of the source files.\n\n## Code scaffolding\n\nRun `ng generate component component-name` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module`.\n\n## Build\n\nRun `ng build` to build the project. The build artifacts will be stored in the `dist/` directory. Use the `--prod` flag for a production build.\n\n## Running unit tests\n\nRun `ng test` to execute the unit tests via [Karma](https://karma-runner.github.io).\n\n## Running end-to-end tests\n\nRun `ng e2e` to execute the end-to-end tests via [Protractor](http://www.protractortest.org/).\n\n## Further help\n\nTo get more help on the Angular CLI use `ng help` or go check out the [Angular CLI README](https://github.com/angular/angular-cli/blob/master/README.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgund%2Fngx-router-meta","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgund%2Fngx-router-meta","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgund%2Fngx-router-meta/lists"}