diff --git a/src/index.js b/src/index.js index dfa05d6..9fe7643 100644 --- a/src/index.js +++ b/src/index.js @@ -17,7 +17,9 @@ const HttpsRedirect = ({ disabled, children }) => { window.location.href = window.location.href.replace( /^http(?!s)/, 'https' - ); + ).replace( + 'www.', + ''; return null; }