In this recipe, we will create a custom-defined ruleset for YSlow and execute a performance analysis with it.
To run this recipe, we will need a target URL.
We will use the PhantomJS port of the YSlow library to execute the performance analysis on our target web page. However, as we are creating a custom ruleset, we must build the library from source. To obtain the YSlow library source code, we change directories into the sample code repository and initialize the submodule as shown in the following command:
git submodule init && git submodule update
Alternatively, we can click the download link on the project's GitHub page https://github.com/marcelduran/yslow.
If we download ...