Introduction to Block Layouts
Get introduced to Blocks and learn how to customize the UI.
We'll cover the following
Blocks overview
Blocks is Gradio’s low-level API that allows more custom-built applications (and it is still entirely built in Python). Blocks offer more flexibility and customization compared to Interface
in the following ways:
Layout of the components: We don’t always just have a simple input on the left and output on the right!
Events that trigger the execution of functions: We can decide which UI components have events attached to them and what events they trigger (whereas in
Interface
, these are usually predetermined depending on the components).Data flows: They can be more complex than just input, function, and output.
Get hands-on with 1300+ tech skills courses.