createPaginate directive implementation