Feature: Add ability to provide meta tags via `RouteMeta`

This issue has been tracked since 2023-01-16.

Which scope/s are relevant/related to the feature request?

router

Information

Add the ability to provide meta tags for a specific page via RouteMeta in the following way:

// routes/index.ts

export const routeMeta: RouteMeta = {
  title: 'Home',
  meta: [
    { name: 'description', content: 'Home Page Description' },
    { name: 'author', content: 'Marko' },
    // ...
  ],
};

@Component({ /* ... */ })
export default class HomeComponent {}

Meta tags can be also set via resolver:

export const routeMeta: RouteMeta = {
  title: 'Home',
  meta: () => inject(MetaService).getMetaTags(),
};

Describe any alternatives/workarounds you're currently using

No response

I would be willing to submit a PR to fix this issue

  • Yes
  • No
More Details About Repo
Owner Name analogjs
Repo Name analog
Full Name analogjs/analog
Language TypeScript
Created Date 2022-07-06
Updated Date 2023-03-28
Star Count 885
Watcher Count 18
Fork Count 67
Issue Count 33

YOU MAY BE INTERESTED

Issue Title Created Date Updated Date