流星-设置文档标题 [英] Meteor - Setting the document title

查看:49
本文介绍了流星-设置文档标题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以更改Meteor应用程序中的<title>元素?似乎仅在<body>中处理模板.

Is there a way to change the <title> element in a Meteor app? Seems templates are only processed in the <body>.

推荐答案

客户端JavaScript代码中的几乎所有位置:

Pretty much anywhere in your client-side JavaScript code:

document.title = "My new title";

这篇关于流星-设置文档标题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆