%PDF- %PDF-
Direktori : /var/www/html/node_modules/next/dist/server/web/spec-extension/ |
Current File : /var/www/html/node_modules/next/dist/server/web/spec-extension/user-agent.js |
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.isBot = isBot; exports.userAgentFromString = userAgentFromString; exports.userAgent = userAgent; var _uaParserJs = _interopRequireDefault(require("next/dist/compiled/ua-parser-js")); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function isBot(input) { return /Googlebot|Mediapartners-Google|AdsBot-Google|googleweblight|Storebot-Google|Google-PageRenderer|Bingbot|BingPreview|Slurp|DuckDuckBot|baiduspider|yandex|sogou|LinkedInBot|bitlybot|tumblr|vkShare|quora link preview|facebookexternalhit|facebookcatalog|Twitterbot|applebot|redditbot|Slackbot|Discordbot|WhatsApp|SkypeUriPreview|ia_archiver/i.test(input); } function userAgentFromString(input) { return { ...(0, _uaParserJs).default(input), isBot: input === undefined ? false : isBot(input) }; } function userAgent({ headers }) { return userAgentFromString(headers.get("user-agent") || undefined); } //# sourceMappingURL=user-agent.js.map