1

I have generated a meanjs crud module with: yo meanjs:crud-module modulename.

How do i go about changing the meta data values for view.modulename.client.html since their generated on the server side (layout.server.view.html)? I can't seem to find ng-app="" any where, so I could just chuck that into the head tag along with a controller.

Everything else is hooked up quite nicely and its easy to create a basic CRUD app, except for the meta data. I'm trying to change them from the create.modulename.client.html via the form it provides, I get correct values in the body to show up but not in the head. What's best practice here?

Henrik Harju
  • 95
  • 1
  • 10

1 Answers1

0

For simplicity, I just used jQuery as discussed in these SO answers for title and description.

There are more 'angular' approaches listed here, but they require moving app / controller declarations to the html tag, creating directives, or downloading modules.

The jQuery approach allows you to keep the meta descriptions coupled with the controller primarily responsible for the page, all without making any changes to the meanjs default structure.

Community
  • 1
  • 1
poof
  • 69
  • 5