mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-25 03:29:51 +01:00
feat: use dev definitions on localhost
This commit is contained in:
1 parent
c04192e15e
commit
5168fb4098
1 file changed
+3
-1
@@ -1,7 +1,9 @@
|
|||||||
|
const devHostStartNames = ['blitzkrieg-git', 'localhost'];
|
||||||
|
|
||||||
export default function isDev() {
|
export default function isDev() {
|
||||||
return (
|
return (
|
||||||
process.env.NODE_ENV === 'development' ||
|
process.env.NODE_ENV === 'development' ||
|
||||||
(typeof window !== 'undefined' &&
|
(typeof window !== 'undefined' &&
|
||||||
window.location.host.startsWith('blitzkrieg-git'))
|
devHostStartNames.some((name) => window.location.host.startsWith(name)))
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
Reference in new issue
Block a user