How to add meta in my head?


#1

I’m using angular in my project. So I removed the blaze-html-templates and emacscript. My original index.html:

<!doctype html>
<html ng-app="video" ng-controller="MainCtrl">
  <head>
      <meta charset="utf-8">
      <title>{{Page.title()}}</title>
      <meta name="description" content={{Page.description()}}>
      <meta name="viewport" content="width=device-width">

I converted it to html in client/index.html:

<head ng-app="video" ng-controller="MainCtrl">
      <meta charset="utf-8">
      <title>{{Page.title()}}</title>
      <meta name="description" content={{Page.description()}}>
      <meta name="viewport" content="width=device-width">
</head>

But I got an error message:

While processing files with angular-templates (for target web.browser):
client/index.html:1: Attributes on not supported

What should I do? Thanks.


#2

manuelschoebel:ms-seo quite good and simple

https://atmospherejs.com/manuelschoebel/ms-seo


#3

Try https://github.com/kadirahq/meteor-dochead


#4

Bootstrap your application using Javascript rather than the ng-app tag.

// eslint-disable-next-line angular/document-service
angular.bootstrap(document.documentElement, ['video'], {
  strictDi: true
})