AMZ123跨境卖家导航
拖动LOGO到书签栏,立即收藏AMZ123
首页跨境头条文章详情

JavaScript SEO怎么做

2045
2020-08-06 18:10
2020-08-06 18:10
2045

Hi. I’m Charles from Cross Border Digital. Are you using JavaScript to build your website? Or maybe you're thinking about using one of the modern JavaScript frameworks like Ember,or Node, or React, or Angular. Great frameworks for building very app-like interfaces on the web.

大家好,我是来自Cross Border Digital的Charles. 你是否在用JavaScript建站?或者你正在考虑用使用当前比较流行的JavaScript框架:Ember、Node、React 或者是Angular建站。这些都是非常优秀的框架,给网站访客提供类似App的操作体验。


But there are some specific challenges to using these JavaScript frameworks when it comes to SEO. Today, I want to share some insights and advice to help you use these frameworks in a way that will work with Google and ensure that you can rank your website.

但是,当涉及到SEO时,使用这些JavaScript框架存在一些特定的挑战。今天,我想分享一些见解和建议,以帮助您以与Google兼容的方式使用这些框架,确保网站在搜索引擎可以获得排名。


So when it comes to understanding the implications of using JavaScript to build your website, there's really two key things that we need to talk about.

因此,在理解使用JavaScript开发网站的意味着什么时,实际上需要讨论两个关键问题。


The first is how Google actually works, how they treat JavaScript, how they understand JavaScript.

首先是Google的实际工作方式,如何对待JavaScript,如何理解JavaScript。


And the second is understanding the difference between client-side and server-side rendering of the content and HTML on your website.

其次是了解网站上内容和HTML在客户端和服务器端渲染的区别。


These two things together if we can understand these, then we can understand how Google is going to interpret our JavaScript-powered website.

如果我们能理解这两点,那么就能了解Google如何读取JavaScript网站。


OK, so let's first talk about Google. There are in fact two parts to Google's crawling and indexing of the web.

首先来讨论一下谷歌运作方式。谷歌爬取收录网站可以分为两部分:


The first part, the crawler known as Google bot is the part of the infrastructure that follows every link it can find on the web to uncover every URL on your website and on every other website on the web. The Google bot crawler can't render JavaScript. It's simply visits a page. It will do a very quick pass of any HTML that it finds on the page to see if there are any other links it can follow, but otherwise, it simply passes the URLs that it does find back to the indexer.

第一部分,被称为Googlebot的爬虫,是搜索引擎基础结构的一部分,它通过页面上的链接,去发现更多的页面。Google bot爬虫无法渲染JavaScript。它只是访问页面。爬虫会快速查找HTML页面上的链接,继续抓取新的页面,没有新页面就会将爬取到的链接返回谷歌索引(indexer)。

 

The indexer is the part of Google's infrastructure that completely renders a page of all the content, all of the CSS, all of the layout to try in the content, to try and understand what that page is about. So that when someone does a query, it can return that page if it is relevant. Now the indexer can render JavaScript.

索引是Google搜索引擎基础结构的一部分,它负责渲染页面的所有内容,CSS,布局以了解该页面的核心信息。当用户在搜索引擎搜索时,才能返回客户搜索相关的页面。Indexer可以渲染JavaScript。


So it is true to say that Google can render JavaScript-powered web pages.

因此,谷歌支持渲染基于JavaScript开发的网页。

 

But to completely understand the implications of using JavaScript, it is also important to understand the difference between client-side and server-side rendering of JavaScript, because that makes a big difference to the way that Google will interpret your website.

但是要完全了解使用JavaScript对网站的影响,理解客户端和服务器端JavaScript渲染的区别也很重要,因为会导致Google读取网站的方式有很大的不同。


So generally speaking, these modern JavaScript frameworks like React, Node, and Ember, and Angular, they render in the client side. That means that when someone visits your web page that's built on one of these frameworks, the JavaScript application is delivered to the browser and then it renders everything in the browser. It calls the CSS, it calls the content, it calls the images, and any other resources required to lay out your web page into the browser and renders them on the client side.

因此,一般而言,这些现代JavaScript框架(例如React,Node和Ember和Angular)在客户端渲染。这意味着,当用户访问基于这些框架之一开发的网页时,JavaScript应用程序将交付给浏览器,然后在浏览器渲染所有内容。将CSS,文本,图片以及其他与页面展示有关的资源推送到浏览器,在客户端渲染。


A server side rendering is when all of that work is done on the server and the HTML of the complete page and all of the content is delivered to the browser.

服务器端渲染是指在服务器端完成所有渲染工作并将完整页面的HTML和所有内容都交付给浏览器。

 

Now this has big implications for Google because as we said, the Google bot can't render JavaScript. So that means that when Google bot visits your home page or your JavaScript-powered website, if you're rendering client side, it means that the Google bot will get that JavaScript application, but it can't render any content or any link. So it won't find any other links to crawl. It will have to send that single URL back to the indexer. The indexer will then render that page it will find any links and content on that page. It will send any links back to the crawler so that they can then continue to follow those you URLs to see if they can find any other links.

这就对Google收录网站产生了重大影响,因为前面所说,Google bot无法渲染JavaScript。因此,这意味着当Googlebot访问您的主页或基于JavaScript的网站时,如果网站是客户端渲染,则意味着Googlebot将获取该JavaScript应用程序,但无法渲染任何内容或任何链接。因此Google bot无法找到页面上的链接。只会返回一个URL给谷歌indexer。谷歌Indexer将渲染页面并发现页面上的更多链接和内容。发现新的链接则会返回给Google bot去继续抓取进一步发现更多的链接。


And in this way, it really slows down the process of crawling your website in a very big way.
And this is particularly relevant for large websites. So the other thing that I have to say about client-side rendering is that Google's indexer uses a version of Chrome for rendering JavaScript-powered websites that is about three years old.

这就极大地减慢了网站被谷歌抓取的速度,这对于大型网站影响尤为重大。另外,关于客户端渲染,Google的indexer用来来渲染JavaScript网站所使用的Chrome版本已有大约三年的历史。

 

And that means that it can't support all the latest features of these modern JavaScript frameworks. So if you're building a JavaScript-powered website that renders on the client side, it is very important that you ensure that it is set up in such a way that it degrades nicely for older versions of browsers so that Google can render your content and your HTML completely.

这意味着它不能支持那些现代JavaScript框架的所有最新功能。因此,如果您要构建一个以JavaScript为基础的网站,并在客户端进行渲染,那么确保Google可以完全渲染您的内容和HTML。


I've seen many cases where a client-side rendered JavaScript page, Google is able to crawl or index part of it but it doesn't see all of the continent because of some of the features that have been included in that page. So very important that your JavaScript-powered web page degrades nicely for all the versions of the browser.

我看过很多客户端渲染的JavaScript页面,Google能够对其进行抓取和编制索引,但是页面中包含的某些功能谷歌无法完整抓取。因此要确保你基于JavaScript开发网页对于所有版本的浏览器都可以很好地渲染。

 

So we know that Google bot can't render JavaScript. And whilst the Google indexer can render JavaScript, we also know that it is limited to older versions of Chrome. So it doesn't support all the latest features of these modern JavaScript frameworks. So if we are doing client-side rendering, it is more difficult to get all of our content indexed and it really does slow down the entire process of crawling and indexing your website, which includes any changes you make. So if you make changes to your website, particularly if you have a large website, it can take weeks or months for those changes to be reflected in the Google index.

我们知道Google bot无法渲染JavaScript。Google indexer可以呈现JavaScript,但我们也知道它仅限于旧版Chrome。因此,它不支持这些现代JavaScript框架的所有最新功能。因此,如果在进行客户端渲染,则很难对所有的内容建立索引,这确实会减慢对网站被抓取和索引的整个过程,其中包括您所做的任何更改。因此,如果您对网站进行更改,尤其大型网站,则这些更改可能需要数周或数月才能反映在Google索引中。

 

So what to do? Well, our strong recommendation is to use old-fashioned content management systems for public facing web sites, first and foremost. If you haven't yet started the build of your website, then we would strongly recommend you look at one of the content management systems like Ambraco, or Wordpress, or Drupal. Or if you're doing e-commerce, use one of the platforms like Shopify, or BigCommerce.

那么该怎么办?我们强烈建议普通网站使用老式的内容管理系统。如果您还没有开始网站的搭建,那么我们强烈建议您考虑内容管理系统,例如Ambraco,Wordpress或Drupal。如果是电商网站,可以考虑用Shopify, BigCommerce电商建站系统。

 

These content management applications render everything on the server side and deliver the complete HTML to the browser and to Google, which makes it much easier and faster for Google to completely crawl and index your website.

这些内容管理应用程序在服务器端呈现所有内容,并向浏览器和Google提供完整的HTML,这使Google能够更轻松,更快地完全抓取您的网站并为其建立索引。

 

If you have already built a JavaScript-powered website, or if you really want to for whatever reason, then our drawing recommendation is to configure that application to render everything on the server side and deliver the complete HTML and content to the browser and to Google in the same way that one of these older traditional content management systems does. If you can do that properly, then it will make it a lot easier and faster for Google to index your JavaScript-powered website.

如果您已经建立了JavaScript网站,或者出于特殊原因确实想要这样做,那么我们的建议是配置该应用程序在服务器端渲染所有内容,并将完整的HTML和内容提供给浏览器和Google 就像这些较旧的传统内容管理系统之一一样。这对于谷歌快速抓取收录你的JavaScript网站会有很大帮助。

 

Perhaps, you've already launched a JavaScript-powered website that is rendering everything on the client side. You're not sure how to configure it to do that on the server side. There are third party services like Prerender.io, which might help. They might be worth looking at as well.

又或许,您已经发布了一个在客户端渲染的基于JavaScript开发的网站,不知道如何改为在服务器端渲染。有一些第三方服务获取可以帮你解决这个问题,比如Prerender.io。可以了解一下。

 

So in a nutshell, a lot of SEO is about making it easy for Google and not putting hurdles in Google's way. And when it comes to using JavaScript on your website, there are quite a few pitfalls and traps that if you're not aware of them, it's easy to fall into.

简而言之,很多SEO都是为了帮助Google而不是阻碍Google抓取网站。在您的网站上使用JavaScript时,会有很多陷阱,稍不小心就掉入。


免责声明
本文链接:
本文经作者许可发布在AMZ123跨境头条,如有疑问,请联系客服。
最新热门报告作者标签
订单增长26%,波兰消费者开始偏好网购宠物用品
根据Wolt发布的数据,波兰宠物电商市场正在快速发展,越来越多消费者选择通过线上平台为宠物购买食品和日常用品,2025年宠物用品类别订单量同比增长26%。
《2026年亚马逊Prime Day研究报告》
Tinuiti发布了《2026年亚马逊Prime Day研究报告》。该报告基于2026年4月对1000名美国Amazon Prime会员的调研,从Prime Day购物意愿、消费预算、通胀影响、活动时间变化、跨平台比价、AI工具使用以及热门品类等多个方面,分析了2026年Prime Day消费者行为的最新变化。
AMZ123会员专享丨5月第2周资讯汇总
亚马逊亚马逊宣布,正式在英国启动无人机配送服务。5月8日,亚马逊已开始在英国达勒姆郡达灵顿(Darlington)配送中心进行无人机包裹配送飞行,这也是亚马逊Prime Air服务首次在英国使用最新一代MK30无人机开展配送业务。据外媒报道,美国加州针对高速电动自行车的安全监管进一步升级。亚马逊已同意停止在加州销售超过州法律限速的高速电动自行车(时速超过40英里),此举与当地接连发生的车祸事故有关。
字节上诉至欧盟最高法院,试图避免DMA严格监管
5月12日,TikTok母公司字节跳动出庭位于卢森堡的欧盟法院,希望推翻欧盟《数字市场法案》(DMA)认定的“大型互联网平台”身份。
巴西重启小额免税,TikTok卖家迎重磅利好!
20%进口联邦税一夜归零,TikTok巴西卖家又减负了
京东将在都柏林设立本地办公室
京东正在爱尔兰都柏林设立办公室,并计划招聘约30名员工,进一步扩展其欧洲业务版图。
亚马逊再度裁员,卖家服务团队将被削减
亚马逊再次宣布裁员,本次裁员涉及其卖家服务团队。此次调整影响“少量员工”,但未披露具体人数。
亚马逊把AI装进搜索栏:Alexa购物版支持降价提醒、定时下单、多轮对话,卖家如何抓住新流量红利?
亚马逊推出“Alexa for Shopping”,将AI助手嵌入核心搜索栏,支持智能推荐、降价提醒、自动复购,甚至全网代购。搜索流量格局将被彻底改写,卖家运营策略亟需升级。
Labubu冰箱卖疯了!泡泡玛特杀进小家电出海
泡泡玛特推出了首款Labubu主题冰箱,5999元一台、全球各限量999件,一上线就被抢爆,闲鱼上二手价已经炒到8999元。4月30日晚10点,泡泡玛特首款家电产品「The Monsters 生活家系列冷藏箱」(也就是大家说的 Labubu 冰箱)在京东、天猫、抖音同步开售。两个版本(Home 款 + House of The Monsters 款)各限量999台、单台5999元、每台带独立编号。参数其实很普通:121L 容量(106L 冷藏 + 15L 冷冻),按官方介绍更适合放美妆、保健品、零食,根本不是冲着厨房主力机去的。
亚马逊推出动态广告,可根据用户观看记录自动换广告
亚马逊Prime Video推出一项名为“Dynamic TV Creative(动态电视创意)”的新工具,可根据观众此前是否看过某个品牌或产品广告,自动调整后续展示的广告内容和形式。
官宣!2026年亚马逊Prime会员日定档6月,日本站锁定7月
亚马逊正式官宣Prime会员日将于6月全球举行,覆盖超20个国家。日本站延至7月。卖家提报、备货、成本三大板块迎重大变化,速看备战指南!
亚马逊推出ASCS供应链服务,向全行业企业开放
亚马逊推出全新的供应链服务“Amazon Supply Chain Services(ASCS)”,整合了运输、仓储、配送和末端派送能力,企业可以利用这一体系完成从原材料运输到成品交付的全流程操作,而不仅限于亚马逊平台卖家。
亚马逊测试AI搜索摘要功能
亚马逊正在测试将人工智能(AI)整合进网站搜索栏,推出了“Join the chat”功能,用户可以在收听AI生成的商品语音介绍时,通过文字或语音直接向AI提问。
暴雷了!大批亚马逊卖家货款惨遭收割
本期干货资料《亚马逊算法融合深度解析(COSMO&Rufus&A9)》
Prime Day提前了,中国卖家却更冷静了
亚马逊把2026年Prime会员日提前到了6月。亚马逊宣布,2026年Prime会员日将在6月于多个国家和地区举行。对平台来说,这是年中消费的一次提前启动,也是Prime会员体系继续证明价值的重要节点。但对中国卖家来说,今年的Prime Day可能不再像过去那样让人兴奋。图源:亚马逊全球开店不是因为Prime Day没有流量。只要亚马逊的会员体系还在,Prime Day仍然是全年最确定的销售窗口之一。消费者会等折扣,平台会集中资源,站内广告会迎来高峰,很多类目也依然可能在短时间内跑出平时难以达到的销量。真正变化的是,卖家不再轻易相信“大促一定能带来确定性增长”。
亚马逊德国保健品市场销售额第一,市场份额达43%
Kaske Group调查数据显示,2025年,亚马逊在德国非处方药领域的销售额达到25亿欧元,超过欧洲两大上市在线药房企业Redcare Pharmacy(Shop Apotheke)和DocMorris,位居市场第一。
《美客多墨西哥市场趋势洞察》PDF下载
美客多远不止是一个电商平台。这里映射着数百万墨西哥消费者的潮流趋势、喜好变化和日常消费选择。
《美客多巴西市场趋势报告》PDF下载
美客多远不止是一个电商平台。这里映射着数百万巴西消费者的潮流趋势、喜好变化和日常消费选择。
《TikTok Shop2024家居类报告东南亚》PDF下载
从各品类占比来看,越南市场GMV相对集中,GMV前五的品类已经接近80%,其中家居用品占比仅为TOP10品类的4%,家居品类在越南站点仍有很大的发展及进步空间。
《Temu商业模式迭代,应对监管挑战,持续高增长》PDF下载
Temu 持续高增长,全球跨境电商重要平台。Temu 自 2022 年上线以来飞速发展,依托供应链优势、全托管模 式以及广告投放帮助其取得了商业模式的巨大成功。从用户数和份额角度,Temu 都已成为全球最重要的跨境 电商平台之一。
《2025中国医疗器械出海现状与趋势蓝皮书》PDF下载
医疗器械出海不仅是企业拓展市场的战略选择,更是提升全球医疗水平、增进人类健康福祉的重要使命。然 而,这一过程充满挑战:不同国家和地区的法规标准、市场准入、文化差异以及技术要求,都对企业提出了 严峻考验。如何在复杂的国际环境中找到方向,实现从产品输出到品牌信任,是每一家出海企业必须面对的 核心问题。
AMZ123《全球电商市场报告——韩国篇》PDF下载
本报告从电商市场环境、消费者画像与营销选品策略等多个维度,聚焦这一市场进行系统性解读,为跨境卖家精准切入韩国市场,把握增量机遇提 供深度参考。
《TikTok Shop 2026年一季度报告》PDF下载
2026年第一季度,TikTok Shop在全球(基于所提供的10个站点数据)继续保持强劲的增长态势总GMV已达274.53亿美元,整体市场呈现出核心市场GMV体量巨大、新兴市场爆发式增长的特征美国站以69.85亿美元的GMV稳居榜首,对比25年第一季度增长了66%
《2026游戏出海产业深度解析报告》PDF下载
2025年,全球游戏市场彻底走出了调整期,迎来了确定性的复苏增长。根据Newzoo最新发布的全球营收趋势数据显示,2025年全球游戏市场总营收预计将达到1967亿美元,正式逼近2000亿大关。从长期增长曲线来看,行业复合年增长率(CAGR)正从2022-2025年间的4.2%加速攀升,预计在2025-2028年间将达到4.9%,显示出强劲的市场韧性。
跨境学院
跨境电商大小事,尽在跨境学院。
亚马逊资讯
AMZ123旗下亚马逊资讯发布平台,专注亚马逊全球热点事件,为广大卖家提供亚马逊最新动态、最热新闻。
亚马逊公告
AMZ123旗下亚马逊公告发布平台,实时更新亚马逊最新公告,致力打造最及时和有态度的亚马逊公告栏目!
欧洲电商资讯
AMZ123旗下欧洲跨境电商新闻栏目,专注欧洲跨境电商热点资讯,为广大卖家提供欧洲跨境电商最新动态、最热新闻。
AMZ123卖家导航
这个人很懒,还没有自我介绍
亚马逊全球开店
亚马逊全球开店官方公众号,致力于为中国跨境卖家提供最新,最全亚马逊全球开店资讯,运营干货分享及开店支持。
跨境平台资讯
AMZ123旗下跨境电商平台新闻栏目,专注全球跨境电商平台热点事件,为广大卖家提供跨境电商平台最新动态、最热新闻。
AMZ123选品观察员
选品推荐及选品技巧分享。
首页
跨境头条
文章详情
咨询
官方微信群
官方客服

扫码添加,立即咨询

加群
官方微信群
官方微信群

扫码添加,拉你进群

更多
订阅号服务号跨境资讯
二维码

为你推送和解读最前沿、最有料的跨境电商资讯

二维码

90% 亚马逊卖家都在关注的微信公众号

二维码

精选今日跨境电商头条资讯

回顶部