When I was trying to decide an efficient way to determine if files were being served on localhost or prod, I came here and ended up with if(window.location.port) to test for localhost πI'm sure I will visit more in the future, great job creating an excellent, clear resource!
Nice! Glad you found the article helping and you were able to apply the knowledge right away! I also list all my tidbits on my site if you want another resource to check out π > samanthaming.com/
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
When I was trying to decide an efficient way to determine if files were being served on
localhost
or prod, I came here and ended up withif(window.location.port)
to test for localhost πI'm sure I will visit more in the future, great job creating an excellent, clear resource!Nice! Glad you found the article helping and you were able to apply the knowledge right away! I also list all my tidbits on my site if you want another resource to check out π > samanthaming.com/