moved roboto link tag from CSS import to prefetched link tag, re: nodebb/nodebb#5733

main
Julian Lam 7 years ago
parent 788399c86d
commit 98aa41222e

@ -1,5 +1,3 @@
@import url(https://fonts.googleapis.com/css?family=Roboto:300,400,500,700);
html {
overflow-y: scroll;
min-height: 100%;

@ -117,4 +117,14 @@ library.addUserToTopic = function(data, callback) {
}
};
library.getLinkTags = function (data, callback) {
data.links.push({
rel: 'prefetch stylesheet',
type: '',
href: 'https://fonts.googleapis.com/css?family=Roboto:300,400,500,700',
});
callback(null, data);
};
module.exports = library;

@ -7,7 +7,8 @@
{ "hook": "filter:config.get", "method": "getThemeConfig" },
{ "hook": "static:app.load", "method": "init" },
{ "hook": "filter:admin.header.build", "method": "addAdminNavigation" },
{ "hook": "filter:topic.build", "method": "addUserToTopic" }
{ "hook": "filter:topic.build", "method": "addUserToTopic" },
{ "hook": "filter:meta.getLinkTags", "method": "getLinkTags"}
],
"scripts": [
"lib/persona.js",

Loading…
Cancel
Save