I am running localhost from a custom host (https://myapp.local).
The way the localhost detection is currently implemented, the tracker does not recognize if I am on localhost or not, and therefore sends the request.
|
const isLocalhost = |
|
/^localhost$|^127(?:\.[0-9]+){0,2}\.[0-9]+$|^(?:0*:)*?:?0*1$/.test( |
|
location.hostname |
|
) || location.protocol === 'file:'; |
Possible Implementation
I would suggest to add an option where a user can change their localhost url and therefore making isLocalhost true. Happy to add a PR if you agree.