UI Drafter Blog

Deploy Assets Before Documents

October 28, 2020
Eric Fortis

Unstyled pages. Not all of them are FOUCs. Some happen while deploying due to temporary 404s of images, CSS, or JS.

UI Drafter avoids those issues by nesting assets in subdirectories:

…and deploying them in two steps:

# Subdirectories first
rsync -r --include '*/' --exclude '/*' $SRC/ $DEST/

# Then the top level files (HTML documents)
rsync --times $SRC/* $DEST