These 110/220 to 5v step down modules are available on ebay and aliexpress. Please refer to attached image and marked area in red, I found that distance between main input and curuit is too short, just wanted to know does it matters? is it safe to have too short distance from main input.
Thanks.
It depends on what you mean by safe?
Yes, the 5V side doesn't appear to have sufficient separation from the mains and it might not be isolated at all, but that isn't a problem in some applications. If it's used as part of a device, where everything connected to that module, is treated with the same precautions as mains, then it's perfectly safe. It's only if it's used in an application, where the user isn't well enough insulated from the output of that module, that it becomes a safety hazard.