[wordpress插件] Async JS and CSS异步JS和CSS

wordpress 插件 文章 2020-02-22 11:00 561 0 全屏看文

AI助手支持GPT4.0

评分
84
描述

When your page is loaded by browser – all that stuff placed in HEAD tag is loaded before the page content – in blocking way.

通过浏览器加载页面时-放置在HEAD标记中的所有内容都在页面内容之前加载-处于阻塞状态。

So the content is delivered to user in the last moment, after all javascript and css files are loaded.

因此,所有的javascript和css文件加载完毕后,内容就会在最后一刻交付给用户。

If you are a webmaster or just want to make your web to make better your positions on search engines (yes, they preffer faster webs), just take a look on Google PageSpeed Insights – you'll see that one of the mos

如果您是网站站长,或者只是想让自己的网站在搜索引擎中占据更好的位置(是的,他们认为自己的网站速度更快),那么请看一下Google PageSpeed Insights –您会发现其中之一

important things is fastenes and one of the reason why your page is not so fast – is “Render-blocking JavaScript and CSS”.

重要的事情是Fastenes,而您的页面不能这么快的原因之一就是“渲染阻止JavaScript和CSS”。

This plugin makes ALL scripts loaded by other plugins to be loaded in asynchronous way just like Google PageSpeed Insights recommends.

此插件可以使所有其他插件加载的脚本以异步方式加载,就像Google PageSpeed Insights建议的那样。

All CSS files will be inserted inline into the document code or moved from the document beginning to the end, just before closing BODY tag (or just where you placed wp_foot() function).

所有CSS文件都将内联插入到文档代码中,或者从文档开始到结尾移动,恰好在关闭BODY标记之前(或在放置wp_foot()函数的位置)。

There are various methods to do that – they are all in plugin’s configuration page.

有多种方法可以做到–它们都在插件的配置页面中。

Plugin makes all scripts to be loaded asynchronously using wp_enqueue_script and also can detect scrips included inside of wp_head and wp_footer hooks.

插件使所有脚本都可以使用wp_enqueue_script异步加载,并且还可以检测wp_head和wp_footer挂钩中包含的脚本。

All CSS files loaded using wp_enqueue_style can be loaded just before closing BODY tag by four methods:

使用wp_enqueue_style加载的所有CSS文件都可以在关闭BODY标记之前通过以下四种方法加载:

* inserting  tag

  *插入标签

* inserting

*插入

钻级赞助商 我要加入

开发者在线工具

第三方支付技术请加QQ群

相关文章
[wordpress插件] Social Proof, WordPress Lead Generation Opt in,Exit-intent Email Popup , Emoji Feedback – Apprised社交证明,选择启用WordPress潜在客户,退出电子邮件弹出窗口,表情符号反馈–已提供
[wordpress插件] AWSM TeamAWSM团队
[wordpress插件] Douban Collections豆瓣收藏
[wordpress插件] AllProWebTools LeadboxesAllProWebTools Leadboxes
[wordpress插件] Bangladeshi Taka in WooCommerceWooCommerce中的孟加拉国塔卡
随便看看
上传图片接口,如何调用文档写得很不清楚!麻烦调整下。 324
wx.scanCode真机扫描普通二维码,没有path? 1047
微信8.0.16版本拖动时图片会闪烁,怎么解决? 725
小程序永久封号问题 474
微信商户收款后想分到别的商户里? 339
不填写request合法域名不填会怎么样? 264
小程序审核未通过? 1794
怎么在商品价格中间添加问号制作神秘感? 373
微信小程序版本审核? 303
小程序提示存在误导问题? 286