docs: added docs for build hook.

closed #557.