diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-10-21 07:08:36 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-10-21 07:08:36 +0000 |
commit | 48aff82709769b098321c738f3444b9bdaa694c6 (patch) | |
tree | e00c7c43e2d9b603a5a6af576b1685e400410dee /doc/user/project/pages/introduction.md | |
parent | 879f5329ee916a948223f8f43d77fba4da6cd028 (diff) | |
download | gitlab-ce-48aff82709769b098321c738f3444b9bdaa694c6.tar.gz |
Add latest changes from gitlab-org/gitlab@13-5-stable-eev13.5.0-rc42
Diffstat (limited to 'doc/user/project/pages/introduction.md')
-rw-r--r-- | doc/user/project/pages/introduction.md | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/doc/user/project/pages/introduction.md b/doc/user/project/pages/introduction.md index cea6bab1a50..b97d5328c07 100644 --- a/doc/user/project/pages/introduction.md +++ b/doc/user/project/pages/introduction.md @@ -173,7 +173,7 @@ Most modern browsers support downloading files in a compressed format. This speeds up downloads by reducing the size of files. Before serving an uncompressed file, Pages will check whether the same file -exists with a `.gz` extension. If it does, and the browser supports receiving +exists with a `.br` or `.gz` extension. If it does, and the browser supports receiving compressed files, it will serve that version instead of the uncompressed one. To take advantage of this feature, the artifact you upload to the Pages should @@ -182,14 +182,17 @@ have this structure: ```plaintext public/ ├─┬ index.html +│ | index.html.br │ └ index.html.gz │ ├── css/ │ └─┬ main.css +│ | main.css.br │ └ main.css.gz │ └── js/ └─┬ main.js + | main.js.br └ main.js.gz ``` @@ -202,6 +205,7 @@ pages: script: # Build the public/ directory first - find public -type f -regex '.*\.\(htm\|html\|txt\|text\|js\|css\)$' -exec gzip -f -k {} \; + - find public -type f -regex '.*\.\(htm\|html\|txt\|text\|js\|css\)$' -exec brotli -f -k {} \; ``` By pre-compressing the files and including both versions in the artifact, Pages @@ -255,9 +259,8 @@ instead. Here are some examples of what will happen given the above Pages site: | `/other/index` | `200 OK` | `public/other/index.html` | | `/other/index.html` | `200 OK` | `public/other/index.html` | -NOTE: **Note:** -When `public/data/index.html` exists, it takes priority over the `public/data.html` -file for both the `/data` and `/data/` URL paths. +Note that when `public/data/index.html` exists, it takes priority over the `public/data.html` file +for both the `/data` and `/data/` URL paths. ## Frequently Asked Questions |