Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.

Question Advice/question

Discussion in 'Web' started by bugfinders, Aug 28, 2023.

  1. bugfinders

    bugfinders

    Joined:
    Jul 5, 2018
    Posts:
    887
    So,

    having had a few issues, I built my current work in progress for webgl and got in my chrome console
    Code (Text):
    1. You can reduce startup time if you configure your web server to add "Content-Encoding: gzip" response header when serving "Build/Build.data.unityweb" file.
    2. Build.loader.js:1 You can reduce startup time if you configure your web server to add "Content-Encoding: gzip" response header when serving "Build/Build.framework.js.unityweb" file.
    3. Build.loader.js:1 You can reduce startup time if you configure your web server to add "Content-Encoding: gzip" response header when serving "Build/Build.wasm.unityweb" file.
    so I added

    Code (Text):
    1.  <FilesMatch "[^.]+\.unityweb$">
    2.   Header set Content-Encoding "gzip"
    3. </FilesMatch>
    4.  
    to my apache config and... 2 of them went away but not

    Code (Text):
    1. You can reduce startup time if you configure your web server to add "Content-Encoding: gzip" response header when serving "Build/Build.data.unityweb" file.
    Can anyone tell me why?
     
  2. jukka_j

    jukka_j

    Unity Technologies

    Joined:
    May 4, 2018
    Posts:
    951
    Try using Chrome DevTools Network tab to inspect the "Response Headers" of the web request (see https://developer.chrome.com/docs/devtools/network/#details ) to see if the `Content-Encoding: gzip` option actually stuck with the web server.

    If using Firefox or Safari, they will both have similar developer panels as well that allow viewing Response Headers of the Build.data.unityweb file.