I built a Simple web part using a tutorial and everything works fine. But I don't understand how my local web part can be opened in the context of the SharePoint online. My web part is only available locally.
The tutorial states
So far we were testing the web part in SharePoint Workbench locally, now let’s try to test it within the SharePoint Context. SharePoint Workbench is also hosted in SharePoint Online to preview the web part. It can be accessed by adding ‘ _layouts/15/workbench.aspx’ to the SharePoint Online URL.
This is my first time working with SharePoint and I don't understand how it is working. I have a unique tenant and how it can open my local webpart.
SharePoint Workbench is also hosted in SharePoint Online to preview the web part.
How it knows my local data?