HTML Minifier
Tare da minifier HTML, zaku iya rage lambar tushe na shafin HTML ɗinku. Tare da kwampressor na HTML, zaku iya hanzarta buɗe gidajen yanar gizon ku.
Menene minifier HTML?
Sannu masu bibiyar Softmedal, a cikin labarin yau, za mu fara magana game da kayan aikin mu na rage HTML kyauta da sauran hanyoyin matsa HTML.
Shafukan yanar gizon sun ƙunshi HTML, CSS, fayilolin JavaScript. A wasu kalmomi, zamu iya cewa waɗannan fayilolin da aka aika zuwa gefen mai amfani. Baya ga waɗannan fayilolin, akwai kuma Media (hoto, bidiyo, sauti, da sauransu). Yanzu, lokacin da mai amfani ya yi buƙatun zuwa gidan yanar gizon, idan muka yi la'akari da cewa ya sauke waɗannan fayilolin zuwa mai bincikensa, mafi girman girman fayil ɗin, yawan zirga-zirga zai karu. Hanyar na bukatar fadada, wanda zai zama sakamakon karuwar zirga-zirga.
Don haka, kayan aikin gidan yanar gizo da injuna (Apache, Nginx, PHP, ASP da sauransu) suna da fasalin da ake kira matsawa fitarwa. Tare da wannan fasalin, matsawa fayilolin fitarwa kafin aika su ga mai amfani zai samar da saurin buɗe shafi. Wannan yanayin yana nufin: Komai saurin gidan yanar gizon ku, idan abubuwan fitar da fayil ɗinku suna da girma, zai buɗe a hankali saboda zirga-zirgar intanet ɗin ku.
Akwai hanyoyi da yawa don saurin buɗe shafin. Zan yi ƙoƙari na ba da bayanai da yawa gwargwadon iyawa game da matsawa, wanda ɗayan waɗannan hanyoyin.
- Kuna iya fitar da abubuwan HTML ɗinku ta amfani da yaren software da kuka yi amfani da su, mai tarawa, da plug-ins na gefen uwar garken. Gzip ita ce hanyar da aka saba amfani da ita. Amma kana bukatar ka kula da tsarin a cikin Harshe, Compiler, Server trilogy. Tabbatar cewa matsi algorithm a kan harshe, da matsawa algorithm a kan mai tarawa da matsawa algorithms da Sabar ya samar sun dace da juna. In ba haka ba, kuna iya samun sakamakon da ba a so.
- Hakanan hanya ce don rage fayilolin HTML, CSS da Javascript gwargwadon yuwuwa, don cire fayilolin da ba a yi amfani da su ba, don kiran fayilolin da aka yi amfani da su lokaci-lokaci akan waɗannan shafuka kuma don tabbatar da cewa ba a yin buƙatun kowane lokaci. Ka tuna cewa fayilolin HTML, CSS da JS dole ne a adana su tare da tsarin da muke kira Cache akan masu bincike. Gaskiya ne cewa muna ƙara rubutun HTML, CSS da fayilolin JS a cikin daidaitattun mahallin ci gaban ku. Don wannan, bugawa zai kasance a cikin yanayin ci gaba har sai mun kira shi yana gudana (bugu). Yayin tafiya kai tsaye, zan ba da shawarar ku matsa fayilolinku. Za ku ga bambanci tsakanin girman fayil.
- A cikin fayilolin mai jarida, musamman gumaka da hotuna, zamu iya magana game da masu zuwa. Misali; Idan ka ce icon akai-akai kuma sanya alamar 16X16 akan rukunin yanar gizonku azaman 512×512, zan iya cewa za'a loda wannan alamar azaman 512 × 512 da farko sannan a haɗa shi azaman 16 × 16. Don wannan, kuna buƙatar rage girman fayil ɗin kuma daidaita ƙudurinku da kyau. Wannan zai ba ku babbar fa'ida.
- Hakanan matsi na HTML yana da mahimmanci a cikin yaren software a bayan gidan yanar gizon. Wannan matsi a zahiri wani abu ne da za a yi la'akari da shi lokacin rubutu. Anan ne taron da muke kira Clean Code ya shigo cikin wasa. Domin yayin da ake haɗa rukunin yanar gizon a gefen uwar garken, za a karanta da sarrafa lambobinku da ba dole ba ɗaya bayan ɗaya yayin CPU / Processor. Lambobin ku waɗanda ba dole ba za su tsawaita wannan lokacin yayin da mini, milli, micro, duk abin da kuka faɗa zai faru a cikin daƙiƙa.
- Don manyan kafofin watsa labaru irin su hotuna, ta amfani da kayan aiki na post-loading (LazyLoad da sauransu) plugins zai canza saurin buɗe shafin ku. Bayan buƙatun farko, yana iya ɗaukar lokaci mai tsawo kafin a canza fayilolin zuwa ɓangaren mai amfani dangane da saurin intanet. Tare da taron bayan lodawa, zai zama shawarara don hanzarta buɗe shafin da ja fayilolin mai jarida bayan buɗe shafin.
Menene matsawa HTML?
Matsewar Html muhimmin abu ne don hanzarta rukunin yanar gizon ku. Dukanmu muna cikin damuwa lokacin da rukunin yanar gizon da muke lilo akan intanet ke aiki a hankali kuma a hankali, kuma muna barin rukunin. Idan muna yin haka, me yasa sauran masu amfani zasu sake ziyartar lokacin da suka fuskanci wannan matsala akan namu rukunin yanar gizon. A farkon injunan bincike, Google, yahoo, bing, yandex da sauransu. Lokacin da bots suka ziyarci rukunin yanar gizon ku, yana kuma gwada saurin gudu da bayanan isa game da rukunin yanar gizon ku, kuma lokacin da ya sami kurakurai a cikin ka'idodin SEO don sanya rukunin yanar gizon ku cikin martaba, yana tabbatar da ko an jera ku a shafukan baya ko a cikin sakamakon. .
Matsa fayilolin HTML na rukunin yanar gizon ku, hanzarta gidan yanar gizon ku da matsayi mai girma a injunan bincike.
Menene HTML?
Ba za a iya bayyana HTML a matsayin yaren shirye-shirye ba. Domin shirin da ke aiki da kansa ba za a iya rubuta shi da lambobin HTML ba. Shirye-shiryen da za su iya gudana ta hanyar shirye-shiryen da za su iya fassara wannan harshe ne kawai za a iya rubuta su.
Tare da kayan aikin mu na matsawa na HTML, zaku iya damfara fayilolin html ɗinku ba tare da wata matsala ba. Amma ga sauran hanyoyin./p>
Yi amfani da caching browser
Don amfani da fasalin caching browser, zaku iya rage fayilolin JavaScript/Html/CSS ta ƙara wasu lambobin mod_gzip zuwa fayil ɗin .htaccess. Abu na gaba da kuke buƙatar yi shine kunna caching.
Idan kuna da tushen shafin wordpress, nan ba da jimawa ba za mu buga labarinmu game da mafi kyawun caching da matsawa plugins tare da cikakken bayani.
Idan kuna son jin sabuntawa da bayanai game da kayan aikin kyauta waɗanda zasu shigo cikin sabis, zaku iya biyo mu akan asusun kafofin watsa labarun mu da blog. Muddin ka bi, za ka kasance ɗaya daga cikin mutanen farko da za su san sababbin abubuwan da ke faruwa.
A sama, mun yi magana game da haɓakar rukunin yanar gizon da kayan aikin matsawa html da fa'idodin damfara fayilolin html. Idan kuna da wasu tambayoyi, zaku iya tuntuɓar mu ta hanyar aika saƙo daga hanyar tuntuɓar kan Softmedal.