lit-weather
Advanced tools
Comparing version 1.0.0-alpha.1 to 1.0.0-alpha.2
{ | ||
"name": "lit-weather", | ||
"version": "1.0.0-alpha.1", | ||
"version": "1.0.0-alpha.2", | ||
"description": "lit-weather is a web component using lit-html to display current weather and a forecast with the openWeather apis", | ||
@@ -5,0 +5,0 @@ "author": "lit-weather", |
@@ -382,3 +382,4 @@ import { html, css, LitElement } from 'lit-element'; | ||
// eslint-disable-next-line no-restricted-globals | ||
const isZipCode = !isNaN(query.charAt(0) - parseFloat(query.charAt(0))); | ||
const firstChar = query.toString().charAt(0); | ||
const isZipCode = !isNaN(firstChar - parseFloat(firstChar)); | ||
return isZipCode ? `zip=${query}` : `q=${query}`; | ||
@@ -412,2 +413,3 @@ } | ||
}; | ||
this.dispatchEvent(new CustomEvent('data-changed', { detail: { value: this.data } })); | ||
}) | ||
@@ -414,0 +416,0 @@ .catch(error => { |
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
459286
45
661