env-variable
Advanced tools
Comparing version 0.0.0 to 0.0.1
12
index.js
@@ -24,11 +24,11 @@ 'use strict'; | ||
if ('undefined' !== localStorage) { | ||
try { env.merge(environment, env.parse(localStorage.env || localStorage.debug)); } | ||
if (window.localStorage) { | ||
try { env.merge(environment, env.parse(window.localStorage.env || window.localStorage.debug)); } | ||
catch (e) {} | ||
} | ||
if ('string' === location.hash && location.hash.length) { | ||
env.merge(environment, env.parse(location.hash.chartAt(0) === '#' | ||
? location.hash.slice(1) | ||
: location.hash | ||
if (window.location && 'string' === window.location.hash && window.location.hash.length) { | ||
env.merge(environment, env.parse(window.location.hash.chartAt(0) === '#' | ||
? window.location.hash.slice(1) | ||
: window.location.hash | ||
)); | ||
@@ -35,0 +35,0 @@ } |
{ | ||
"name": "env-variable", | ||
"version": "0.0.0", | ||
"version": "0.0.1", | ||
"description": "Cross platform environment variables with process.env, window.name, location.hash and localStorage fallbacks", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
4547