Black Lives Matter. Please consider donating to Black Girls Code today.

@callbacks tied to adjacent function definition?

Not sure if I missed this in the tutorials or if I’m missing something more fundamental in python.

I’m working through the tutorials (https://dash.plot.ly/interactive-graphing) and seeing multiple @app.callback tied to functions.

The tutorial pages mention a callback ‘wrapping’ a function, other than the adjacency in code, I’m not seeing a naming convention to tie a callback to a function.

last forum discussion seems to be over a year ago.


above thread mentions slapdash

Hey @aspiringguru

It might help you to read up on the decorator syntax in Python. Maybe this past answer will clarify things a bit?