10x Performance Increases: Optimizing a Static Site
10x Performance Increases: Optimizing a Static Site
A couple months ago, I was traveling outside of the U.S. and wanted to show a friend a link on my personal (static) site. I tried navigating to my website, but it took much longer than I anticipated. There’s absolutely nothing dynamic about it — it has animations and some responsive design, but the content always stays the same. I was pretty appalled at the results, ~4s to DOMContentLoaded, and 6.8s for a full page load. There were 20 requests for a static site, with 1mb of total data transferred. I was accustomed to my 1Gb/s, low latency internet in Los Angeles connecting to my server in San Francisco, which made this monstrosity seem lightning fast. In Italy, at 8mb/s, it was a different picture entirely.
... read the whole story at hackernoon.com.An Introduction to NGINX for Developers
An Introduction to NGINX for Developers – freeCodeCamp
Picture this - you’ve created a web application and are now searching for the right web server to host it from.
Your application might consist of multiple static files — HTML, CSS, and JavaScript, a backend API service or even multiple webservices. Using Nginx might be what you are looking for, and there are couple of reasons for that.
NGINX is a powerful web server and uses a non-threaded, event-driven architecture that enables it to outperform Apache if configured correctly. It can also do other important things, such as load balancing, HTTP caching, or be used as a reverse proxy.
In this article, I’ll cover a few basic steps about how to install and configure the most common parts of NGINX.
... read the whole story at medium.freecodecamp.org.Load Balancing Node Apps with NGINX and Docker
Load Balancing Node.js Applications with NGINX and Docker
114
100+
16
10
details
Share on
Facebook,
Twitter or
Google+
TL;DR: In this article we will see how easy it is to load balance dockerized Node.js applications with NGINX. We will create a simple Node.js application that serves an HTML file, containerize it with Docker, and containerize an NGINX instance that uses round-robin algorithm to load balance between two running instances of this application.
Docker and ContainersDocker is a software container platform. Developers use Docker to eliminate “works on my machine” problem when collaborating with co-workers. This is done by putting pieces of a software architecture on containers (a.k.a. dockerize or containerize).
... read the whole story at auth0.com.An opinionated analysis on Mutation Observer for handling component content changes and the Custom Elements API
Writing a JavaScript Framework - The Benefits of Custom Elements
This is the sixth chapter of the Writing a JavaScript framework series. In this chapter, I am going to discuss the usefulness of Custom Elements and their possible role in a modern front-end framework's core.
The series is about an open-source client-side framework, called NX. During the series, I explain the main difficulties I had to overcome while writing the framework. If you are interested in NX please visit the home page.
The series includes the following chapters:
The era of componentsComponents took over the web in the recent years. All of the modern front-end frameworks - like React, Vue or Polymer - utilize component based modularization. They provide distinct APIs and work differently under the hood, but they all share the following features with many of the other recent frameworks.
... read the whole story at blog.risingstack.com.Automatically inline Critical CSS for your server-rendered React app with NGINX and ngx_pagespeed
Automatically inline Critical CSS for your server-rendered React app with NGINX and ngx_pagespeed.
Then let’s go back to our top level custom NGINX directory;
cd /opt/custom_nginx/nginx-1.10.3/
Then let’s build our package. This might take a while. If you get a question during installation on whether to “Use the available Release binaries?”, just say Y.
sudo dpkg-buildpackage -b
When the build is finished we go up a level to our top level custom_nginx folder;
cd /opt/custom_nginx
There should be several NGINX debian packages in this folder now.
Let’s install our custom full version (choose the version that matches your Ubuntu version);
sudo dpkg --install nginx-full_1.10.3-0+xenial0_amd64.deb
That’s it! Our custom NGINX build is now installed.
... read the whole story at medium.com.