Creates an instance of post process file.
full absolute path to the file being processed
full YASSB configuration object
determins if in watch mode to skip roduction-only steps
full YASSB configuration object
Contents of the file to post process
Front Matter data found in fileContents
determins if in watch mode to skip roduction-only steps
full absolute path to the file being processed
Inits post process file logic.
init
Injects Front Matter data if any was fond in the file.
Front Matter data retrieved from the store for the current file.
Handles the logic to post process each file by calling the methods in charge of the actions to be performed.
Prepares the content to be saved. If in watch mode, addes the WebSocket listener for live reloading. Else minifies the content.
Runs custom post processors if set in congig.
Saves to disk the final version of file
Reads asynchronously the file and sets the contents on fileContents
.
file contents
Sets file data by fetching it from FRONT_MATTER_DATA_STORE
. In this way any Front Matter data is removed from the page and is available for the final injections.
Post processes each file passed by
PostProcessFiles