Borrowing ideas from Flux