Skip to content

Optimizations #251

Open
Open
@mikepetridisz

Description

@mikepetridisz
  1. Critical dependencies (SPOF) - may block the entire display of the page in case of failure:
- https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js
- fonts.googleapis.com/css?family=Fira+Sans:400,40[...]italic,500,500italic,700
  1. We could reduce 19% (29.5 KiB) by minifying the assets:
- /css/bootstrap/bootstrap.css
- /css/bootstrap/bootstrap-responsive.css
- /css/swc.css
  1. 78.7KiB of JavaScript is parsed during initial page load. We could defer parsing JavaScript to reduce blocking of page rendering:
- ajax.googleapis.co[...]n.js (78.5KiB)
- https://openastronomy.org/ (180B of inline JavaScript)
  1. These png-s are resized on browser side:
openastronomy.org/img/icons[...]s_icon.png (displayed size: 16x16)
openastronomy.org/img/icons[...]l_icon.png (displayed size: 16x16)
openastronomy.org/img/logo/[...]te_svg.png (displayed size: 125x60)
openastronomy.org/img/icons[...]c_icon.png (displayed size: 16x16)
  1. Jekyll - Content Security Policy could be set - e.g:
    We can partially implement it with meta http-equiv or by adding custom headers to _config.yml
    https://jekyllrb.com/docs/configuration/webrick/
# Custom headers
webrick:
  headers:
    Content-Security-Policy: default-src 'none'; script-src 'self'; connect-src 'self'; img-src 'self'; style-src 'self'; 
    My-Other-Header: My-Other-Value
  1. We could use this for caching:
    https://github.com/benbalter/jekyll-include-cache

  2. We should define a lang attribute on the html root

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions