segundofdez/reticulas-template/master/public/dist/.htaccess - Htaccess File

segundofdez/reticulas-template/master/public/dist/.htaccess

# ----------------------------------------------------------------------
# Use UTF-8 encoding for anything served text/plain or text/html
# ----------------------------------------------------------------------
AddDefaultCharset utf-8

# ----------------------------------------------------------------------
# Force UTF-8 for a number of file formats
# ----------------------------------------------------------------------
AddCharset utf-8 .atom .css .js .json .rss .vtt .xml .txt

# ----------------------------------------------------------------------
# JavaScript
# ----------------------------------------------------------------------
AddType application/javascript js jsonp
AddType application/json json

# ----------------------------------------------------------------------
# Audio
# ----------------------------------------------------------------------
AddType audio/ogg oga ogg
AddType audio/mp4 m4a f4a f4b

# ----------------------------------------------------------------------
# Video
# ----------------------------------------------------------------------
AddType video/ogg ogv
AddType video/mp4 mp4 m4v f4v f4p
AddType video/webm webm
AddType video/x-flv flv

# ----------------------------------------------------------------------
# SVG
# ----------------------------------------------------------------------
AddType image/svg+xml svg svgz
AddEncoding gzip svgz

# ----------------------------------------------------------------------
# Webfonts
# ----------------------------------------------------------------------
AddType application/vnd.ms-fontobject eot
AddType application/x-font-ttf ttf ttc
AddType font/opentype otf
AddType application/x-font-woff woff

# ----------------------------------------------------------------------
# Assorted types
# ----------------------------------------------------------------------
AddType image/x-icon ico
AddType image/webp webp
AddType text/cache-manifest appcache manifest
AddType text/x-component htc
AddType application/xml rss atom xml rdf
AddType application/x-chrome-extension crx
AddType application/x-opera-extension oex
AddType application/x-xpinstall xpi
AddType application/octet-stream safariextz
AddType application/x-web-app-manifest+json webapp
AddType text/x-vcard vcf
AddType application/x-shockwave-flash swf
AddType text/vtt vtt

# ----------------------------------------------------------------------
# Gzip compression
# ----------------------------------------------------------------------
<IfModule mod_deflate.c>

    # Force deflate for mangled headers developer.yahoo.com/blogs/ydn/posts/2010/12/pushing-beyond-gzipping/
    <IfModule mod_setenvif.c>
        <IfModule mod_headers.c>
            SetEnvIfNoCase ^(Accept-EncodXng|X-cept-Encoding|X{15}|~{15}|-{15})$ ^((gzip|deflate)s*,?s*)+|[X~-]{4,13}$ HAVE_Accept-Encoding
            RequestHeader append Accept-Encoding "gzip,deflate" env=HAVE_Accept-Encoding
        </IfModule>
    </IfModule>

    # Compress all output labeled with one of the following MIME-types
    # (for Apache versions below 2.3.7, you don't need to enable `mod_filter`
    # and can remove the `<IfModule mod_filter.c>` and `</IfModule>` lines as
    # `AddOutputFilterByType` is still in the core directives)
    <IfModule mod_filter.c>
        AddOutputFilterByType DEFLATE application/atom+xml 
                                      application/javascript 
                                      application/json 
                                      application/rss+xml 
                                      application/vnd.ms-fontobject 
                                      application/x-font-ttf 
                                      application/xhtml+xml 
                                      application/xml 
                                      font/opentype 
                                      image/svg+xml 
                                      image/x-icon 
                                      text/css 
                                      text/html 
                                      text/plain 
                                      text/x-component 
                                      text/xml 
                                      text/javascript 
                                      application/vnd.ms-fontobject 
                                      application/x-font-ttf 
                                      font/opentype 
                                      application/x-font-woff
    </IfModule>
</IfModule>

# ----------------------------------------------------------------------
# Cache
# ----------------------------------------------------------------------

<IfModule mod_expires.c>
    <FilesMatch ".(ico|pdf|flv|jpg|jpeg|svg|png|gif|swf|js|xml|txt|css|woff|ttf|ttc|eot|otf)$">
        Header set Cache-Control "max-age=604800, public"
    </FilesMatch>
</IfModule>

On Github License

Files

Download PDF of Htaccess file
DEFLATE

Comments

Apache