'use strict'; const _ = require('lodash'); module.exports = seoData => { const defaultSeoData = { /* eslint-disable */ title: 'YOHO!有货 | 年轻人潮流购物中心,中国潮流购物风向标,官方授权正品保证', keywords: 'Yoho! 有货官网,潮流志,潮流男装,潮牌,美国潮牌,日本潮牌,香港潮牌,潮牌店,新品首发,欧美潮流,全球购,代购,时尚,流行,特卖,B2C,正品,购物网站,网上购物,货到付款', description: 'YOHO! 有货,年轻人潮流购物中心,中国最大的潮流商品购物网站。100%品牌正品保证,支持货到付款。作为YOHO!旗下的购物平台,汇集了全球潮流时尚商品和中国最流行的商品,也是国内最大的原创文化商品平台,也是香港,台湾地区流行商品的集中地。同时包含日本、韩国等众多国外潮流品牌,带给您全新潮流购物体验。' /* eslint-enable */ }; _.merge(defaultSeoData, seoData); return (req, res, next) => { if (!req.xhr) { res.locals.title = seoData.title; res.locals.keywords = seoData.keywords; res.locals.description = seoData.description; } next(); }; };