Skip to content

YASIR252

Download Software Terbaru & Game Gratis

    • Adobe
    • Android
    • Driver PC
    • iOS
    • Mac
    • Windows 10
    • Windows 11
    • CD DVD Tools
    • File and Folder
    • Games
    • Microsoft Office
    • System Tools
    • Utilities
    • Privacy Policy
    • Terms And Conditions

    Recent Posts

    • This is the main logo of the software being provided
      Download FileZilla Pro Full Crack Terbaru Versi(3.63.2) Gratis
       March 31, 2023 No Comments
    • Download Ableton Live 10 Crack Windows
      Download Ableton Live 10 Full Versi Gratis Latest 2023
       March 29, 2023 No Comments
    • Latest Free Download Virtual DJ Pro 8 Full Version Crack
       March 28, 2023 No Comments
    • Download Microsoft Office 2007 Full Crack
       March 25, 2023 No Comments
    • Mass Effect Andromeda Retakan + Terbaru Download
       February 5, 2023 No Comments

    Categories

    • Software
    • Apps
    • Tutorial
    • Games
    • PC Games
    • editing
    • Other Software
    • Android
    • Sistem Operasi
    • Design Graphic
    • Internet
    • operating system
    • Converter
    • Informasi
    • multimedia
    • Office
    • System Tools
    • antivirus
    • audio
    • Windows 10
    • File and Folder
    • download manager
    • Utilities
    • Windows 11
    • iOS
    • Video Editor
    • Adobe
    • animasi
    • Tech
    • PDF Software
    • Tips Trik
    • data backup
    • media player
    • Mac
    • browser
    • Game PC
    • Windows 8
    • data recovery
    • Windows 7
    • screen recorder
    • activator
    • Microsoft Office
    • macOS
    • tune up
    • desktop
    • Desain
    • hack
    • Driver PC
    • Tools
    • burning
    • Corel
    • foto
    • SlideShow Maker
    • Screen Capture
    • Anti Virus
    • CD DVD Tools
    • Desktop Environment
    • emulator
    • Programming
    • Audio Editor
    • Development
    • DVD Tools
    • Autodesk
    • Update Driver
    • Linux
    • Copy Software
    • Design Web
    • Uncategorized
    • Bisnis Online
    • Pes 2017
    • pluggin
    • SketchUp
    • Fonts
    • Pes 2021
    • Pes 2019
    • Jaringan
    • Remote PC
    • web desain
    • video
    • chatting

    Cara Mempercepat Website WordPress terbaru 2022

    Tutorial
    admin in 21 Oct 2022

    Cara Mempercepat Website WordPress terbaru 2022

    Metode Defer Javascript & Async Javascript

    Pada artikel yang sebelumnya kita telah membahas Cara Mempercepat Website WordPress dengan metode Image Optimization. Tentunya hal itu sangat mempengaruhi kecepatan website. Namun tidak lengkap rasanya apabila kita tidak melanjutkan teknik mempercepat website selanjutnya, yaitu dengan cara Defer Javascript atau Async Javascript.

    Di dalam dunia developing website, JavaScript dianggap sebagai “parser blocking resource”. Ini berarti bahwa Javascript memiliki kemampuan untuk memblokir atau menghentikan sementara Loading HTML (halaman website) sehingga menyebabkan bottleneck. HTML akan mulai kembali berjalan ketika Javascript telah selesai di loading.

    Bottleneck tentunya tidak ramah terhadap user. Faktanya, website yang baik itu memiliki rata-rata kecepatan sekitar 3 – 5 detik untuk memuat seluruh isi halamannya.

    Nah, untuk mengatasi bottleneck pada javascript, untung saja ada 2 buah metode attribut. yang pertama adalah Async Javascript (JS dan HTML loading secara simultan) dan juga Defer Javascript (HTML di loading dulu hingga selesai, baru Javascript dijalankan.) Mari kita lihat lebih rinci perbedaan dari Async Javascript dan Defer Javascript.

    Normal Javascript Load

    Oke, sebelum kita masuk ke pembahasan Async dan Defer, kita telitit dulu gimana cara kerja loading Javascript di sebuah website. Standarnya, Javascript itu ketika mulai di loading, secara otomatis akan menghentikan semua proses parsing html. menyebabkan website loading, tanpa ada apapun yang muncul.

    Contoh Normal Javascript

    <html>
    <head> ... </head>
    <body>
        ...
        <script src="https://www.yasir252.org/tutorial/website/wordpress/cara-mempercepat-website-async-defer-javascript/script.js">
        ....
    </body>
    </html>

    Javascript di loading di dalam konten Body, yang nantinya akan mengakibatkan bottleneck seperti dibawah ini

    Jika kita lihat grafik diatas, maka HTML Parsing (loading element halaman web) mengalami Pause ketika Javascript mulai dimuat di tengah jalan. Setelah javascript telah berjalan (execution), maka barulah HTML parsing kembali berjalan dan menyelesaikan loading website.

    Async Javascript Load

    Lain halnya dengan Async Javascript yang memungkinkan Javacript Fetch untuk dijalankan bersamaan dengan HTML Parsing. Jadi HTML parsing itu engga perlu pause saat javascript sedang di loading. Namun perlu kalian ketahui, metode Async Javascript ini tetap akan mengizinkan Javascript untuk dieksekusi sebelum penutupan HTML Parsing. Yang menyebabkan terkadang, metode async tidak bekerja dengan baik pada sebagian Javascript plugin, malah justru bikin website semakin lemot.

    Biasanya, metode Async ini sangat cocok digunakan untuk plugin javascript yang berada di simpan atau ditarik dari source eksternal. Tapi kembali lagi, kalian harus melakukan riset terlebih dahulu sebelum mengetahui perubahan pada kecepatan website kalian.

    Yuk kita lihat grafik dari Async Javascript :

    Defer Javascript Load

    Metode yang akan kita bahas dalam “cara mempercepat website wordpress” satu lagi adalah Defer Javascript. Nah sedikit berbeda dengan metode sebelumnya, Defer Javascript juga memungkinkan sebuah plugin untuk load bersamaan dengan HTML Parsing. Namun bedanya, Defer Javascript akan menahan semua Javascript supaya di eksekusi ketika HTML parsing telah selesai.

    Jadi simplenya, Defer Javascript engga akan kasih Javascript untuk loading sebelum HTML selesai di parsing. Resikonya adalah terjadi kerusakan plugin Javascript, dan sudah dapat dipastikan JQuery tidak akan mungkin dapat berjalan. Yah mau gimana ya, HTML udah selesai di loading, JQuery baru di eksekusi, besar kemungkinannya pasti gak bisa running.

    Nah, Defer Javascript ini cocoknya untuk plugin-plugin yang tidak mempengaruhi tampilan website. Misalnya, Google Analytics.js, Adsense.js, Popup.js atau widget eksternal yang tidak mempengaruhi tampilan website secara umumnya.

    Coba kita lihat grafik dari Defer Javascript :

    Cara Menggunakan Async & Defer Javascript

    Oke setelah paham perbedaan ketiganya, kita lanjut ke tutorialnya.

    1. Untuk mengetahui Javascript apa yang perlu di defer atau async, Anda dapat menganalisa website WordPress Anda menggunakan GTMetrix terlebih dahulu. Skor rata-rata yang direkomendasikan pada GTMetrix sekitar 71%. Jika terjadi dibawah nilai itu, maka website kalian sangat direkomendasikan untuk melakukan Defer dan Async Javascript.
    2. Buka wordpress kalian > Lalu tambahkan plugin baru bernama Async Javascript
    3. Install dan Aktifkan seperti biasa
    4. Masuk ke halaman Setting Plugin itu di Settings > Async Javascript
    5. Dari settingan ini, kalian ceklist Enable Async Javascript
    6. Gunakan Method : Defer (untuk metode global pakai defer)
    7. jQuery bisa kalian aktifkan metode Async
    8. Untuk Script To Async kalian bisa pilih .js yang secara umum bisa mempengaruhi tampilan web. Misalkan extend-lib.js, retina.min.js, ajax.js, webfont.js
    9. Sedang untuk Script to Defer kalian bisa paksa plugin yang agak bandel dan engga ngaruh ke tampilan website, misalkan Google Analytics.js atau PopUp.js
    10. Kalian juga bisa disable plugin tertentu dengan menginput Plugin Exclusions
    11. Selesai, dan hasil akhirnya setelah di test kembali di GTMetrix

    Oke, sangat mudah kan? nah jika kalian bertanya, apakah bisa melakukan Defer Javascript dan Async Javascript tanpa menggunakan plugin. Jawabannya BISA!

    Untuk melakukan defer parsing JavaScript, kalian bisa copy code di bawah ini dan letakkan pada baris di bawah script dalam file wp-includes/functions.php.

    function defer_parsing_of_js ( $url ) {
    if ( FALSE === strpos( $url, '.js' ) ) return $url;
    if ( strpos( $url, 'jquery.js' ) ) return $url;
    return "$url' defer ";
    }
    add_filter( 'clean_url', 'defer_parsing_of_js', 11, 1 );

    Tapi saya engga rekomendasi input ini secara manual ya. Apalagi kalau ada sebagian dari kita yang masih pemula, rasanya cukup beresiko untuk mengedit file core semacam functions.php. Sebetulnya kalaupun plugin yang saya rekomendasikan tidak berfungsi, masih ada lagi plugin lain yang bisa kalian gunakan. Misalnya : WP Deferred JavaScript. atau Speed Booster Pack

    Sip. Sekian tutorial kita mengenai cara mempercepat website wordpress episode kedua kali ini dengan melakukan Defer Javascript. Selanjutnya saya akan membahas cara mempercepat website wordpress dengan metode Leverage Browsing Cache. Stay tuned aja ya!

    Baca Juga :

    Mempercepat WordPress dengan Image Optimization

    Membersihkan Kode Internal WordPress

    Disable External Request Jetpack di WordPress

    Like this:

    Like Loading...

    Related

    Short URL https://yasir252.org/?p=322
    Tags1 page website template wordpress1 pagina website wordpress1 wordpress website1und1 website wordpress2 language website wordpress2 talige website wordpress5 page wordpress website costan website wordpressbackup my website wordpressblog vs website wordpressbuat web di wordpressbuild a website wordpressbuilding a website wordpresscara membuat website wordpress 2 bahasacara memperbaiki website wordpress yang di hackcontoh web wordpresscreate a website wordpresscreate a website wordpress freecreate e learning website wordpresscreate wordpress website 2020create wordpress website xamppcreate wordpress website youtubecreating a website wordpressdaftar website wordpresse commerce website using wordpresse learning website templates wordpresse learning website wordpresse-commerce website template wordpresse-commerce website wordpresse-commerce wordpress website the complete course downloadedit my website wordpresshack wordpress website kali linuxhow to make website wordpress youtubeincomedia website x5 wordpressjasa website wordpressjenis website wordpressjob website wordpress templatejobs website wordpress themeslog into my wordpress websitelogin to my website wordpresslost my website wordpressmake a website wordpressmaking a website wordpressmembuat website wordpress dengan xamppmembuat website wordpress gratismy website wordpressspeed up my website wordpresstăng tốc website wordpress 100tutorial wordpress website xamppwebex wordpresswebsite and wordpresswebsite at wordpresswebsite dengan wordpresswebsite email wordpresswebsite for wordpresswebsite games wordpress pluginwebsite i wordpresswebsite icon wordpresswebsite in wordpresswebsite in wordpress exampleswebsite using wordpresswebsite vs wordpresswebsite vs wordpress hostingwebsite with wordpresswebsite with wordpress exampleswebsite with wordpress tutorialwebsite wordpress adalahwebsite wordpress admin loginwebsite wordpress back-upwebsite wordpress bearbeitenwebsite wordpress beispielewebsite wordpress beveiligenwebsite wordpress bewerkenwebsite wordpress bị hackwebsite wordpress builderwebsite wordpress checkerwebsite wordpress dashboardwebsite wordpress deaktivierenwebsite wordpress demowebsite wordpress designwebsite wordpress design serviceswebsite wordpress disadvantageswebsite wordpress diviwebsite wordpress elementorwebsite wordpress erstellenwebsite wordpress erstellen lassenwebsite wordpress erstellen tutorialwebsite wordpress examplewebsite wordpress exampleswebsite wordpress for hostingwebsite wordpress freewebsite wordpress free templateswebsite wordpress geolocationwebsite wordpress gratiswebsite wordpress hostingwebsite wordpress how to editwebsite wordpress jobswebsite wordpress kerenwebsite wordpress không vào đượcwebsite wordpress kopenwebsite wordpress kostenwebsite wordpress kostenloswebsite wordpress kursuswebsite wordpress là gìwebsite wordpress laten makenwebsite wordpress lemotwebsite wordpress listwebsite wordpress loginwebsite wordpress login adminwebsite wordpress login urlwebsite wordpress löschenwebsite wordpress makenwebsite wordpress managerwebsite wordpress niet veiligwebsite wordpress not showingwebsite wordpress offlinewebsite wordpress offline setzenwebsite wordpress offline stellenwebsite wordpress offline zettenwebsite wordpress online zettenwebsite wordpress or htmlwebsite wordpress or joomlawebsite wordpress or notwebsite wordpress permissionswebsite wordpress plugin speedwebsite wordpress pluginswebsite wordpress postswebsite wordpress preiswebsite wordpress preisewebsite wordpress pricewebsite wordpress templatewebsite wordpress templateswebsite wordpress terbaikwebsite wordpress themewebsite wordpress theme finderwebsite wordpress tidak bisa dibukawebsite wordpress tidak muncul di googlewebsite wordpress tutorialwebsite wordpress umziehenwebsite wordpress uploadenwebsite wordpress versionwebsite wordpress vertalenwebsite wordpress verwijderenwebsite wordpress very slowwebsite wordpress voorbeeldenwebsite wordpress vorlagenwebsite wordpress vs htmlwebsite wordpress vs joomlawebsite wordpress youtubewebsite wordpress.comwebsite wordpress.orgwebsite x5 wordpresswebsite zu wordpress umziehenwordpress 2 website erstellenwordpress can't update my websitewordpress website 101wordpress website 123 regwordpress website 2 languageswordpress website 2 sprachigwordpress website 2 taligwordpress website 2020wordpress website 2021wordpress website 3dwordpress website 403 forbidden errorwordpress website 404 errorwordpress website 500 internal server errorwordpress website 99designswordpress website and blogwordpress website and domainwordpress website and hostingwordpress website android appwordpress website appwordpress website builder freewordpress website checkwordpress website copierwordpress website costwordpress website coursewordpress website createwordpress website create freewordpress website designwordpress website editingwordpress website editorwordpress website error 500wordpress website erstellen - 2020 - xxl tutorial für anfänger deutsch germanwordpress website fiverrwordpress website for beginnerswordpress website free downloadwordpress website free hostingwordpress website githubwordpress website giving 500 errorwordpress website goodwordpress website google searchwordpress website got hackedwordpress website hackwordpress website hacked redirectwordpress website header sizewordpress website hostwordpress website hosting freewordpress website how towordpress website http error 500wordpress website icon changewordpress website image sizewordpress website images not showingwordpress website in 10 minuteswordpress website is downwordpress website is slowwordpress website just white screenwordpress website keeps loadingwordpress website maintenancewordpress website maintenance serviceswordpress website makerwordpress website makingwordpress website managementwordpress website mobile friendlywordpress website name changewordpress website not securewordpress website not secure fixwordpress website not showing imageswordpress website not updating changeswordpress website not workingwordpress website pricingwordpress website qr codewordpress website quorawordpress website quotationwordpress website quotation pdfwordpress website quotation samplewordpress website quotewordpress website quote examplewordpress website quote templatewordpress website redesignwordpress website redirectwordpress website redirected too many timeswordpress website redirecting to spamwordpress website resetwordpress website responsivewordpress website reviewwordpress website root directorywordpress website top 10wordpress website tutorial 2020wordpress website tutorial youtubewordpress website under constructionwordpress website under construction templatewordpress website under maintenancewordpress website upworkwordpress website url changewordpress website with blogwordpress website with databasewordpress website with domainwordpress website with ecommercewordpress website with loginwordpress website xamppwordpress website yapımıwordpress website yearwordpress website your connection is not privatewordpress website zelf makenwordpress website zentrierenwordpress website zugang nur mit passwortwordpress website zügelnwordpress website zurücksetzenwordpress website zustandwordpress website zweisprachigwordpresss log in

    Leave a Reply Cancel reply

    Your email address will not be published. Required fields are marked *

    ← Previous Post Next Post →

    Search

    Recent Posts

    • This is the main logo of the software being provided
      Download FileZilla Pro Full Crack Terbaru Versi(3.63.2) Gratis
    • Download Ableton Live 10 Crack Windows
      Download Ableton Live 10 Full Versi Gratis Latest 2023
    • Latest Free Download Virtual DJ Pro 8 Full Version Crack
    • Download Microsoft Office 2007 Full Crack
    • Mass Effect Andromeda Retakan + Terbaru Download

    Recent Comments

    No comments to show.

    Archives

    • March 2023 (4)
    • February 2023 (4)
    • January 2023 (1)
    • December 2022 (6)
    • October 2022 (1944)

    Categories

    • activator (8)
    • Adobe (14)
    • Android (36)
    • animasi (13)
    • Anti Virus (4)
    • antivirus (20)
    • Apps (353)
    • audio (20)
    • Audio Editor (3)
    • Autodesk (2)
    • Bisnis Online (2)
    • browser (10)
    • burning (4)
    • CD DVD Tools (3)
    • chatting (1)
    • Converter (23)
    • Copy Software (2)
    • Corel (4)
    • data backup (13)
    • data recovery (9)
    • Desain (7)
    • Design Graphic (27)
    • Design Web (2)
    • desktop (7)
    • Desktop Environment (3)
    • Development (2)
    • download manager (16)
    • Driver PC (6)
    • DVD Tools (2)
    • editing (40)
    • emulator (3)
    • File and Folder (17)
    • Fonts (1)
    • foto (4)
    • Game PC (9)
    • Games (126)
    • hack (6)
    • Informasi (22)
    • Internet (26)
    • iOS (15)
    • Jaringan (1)
    • Linux (2)
    • Mac (11)
    • macOS (7)
    • media player (12)
    • Microsoft Office (8)
    • multimedia (22)
    • Office (21)
    • operating system (25)
    • Other Software (36)
    • PC Games (58)
    • PDF Software (13)
    • Pes 2017 (2)
    • Pes 2019 (1)
    • Pes 2021 (1)
    • pluggin (1)
    • Programming (3)
    • Remote PC (1)
    • Screen Capture (4)
    • screen recorder (8)
    • Sistem Operasi (32)
    • SketchUp (1)
    • SlideShow Maker (4)
    • Software (718)
    • System Tools (21)
    • Tech (13)
    • Tips Trik (13)
    • Tools (5)
    • tune up (7)
    • Tutorial (132)
    • Uncategorized (2)
    • Update Driver (2)
    • Utilities (16)
    • video (1)
    • Video Editor (15)
    • web desain (1)
    • Windows 10 (19)
    • Windows 11 (15)
    • Windows 7 (8)
    • Windows 8 (9)

    © 2021-2023 YASIR252

    Powered by WordPress Whiteboard Theme

    ↑
    Go to mobile version
    %d bloggers like this: