diff --git a/src/lib/components/ImpliedVolatility.svelte b/src/lib/components/ImpliedVolatility.svelte index 7470afc3..914ae790 100644 --- a/src/lib/components/ImpliedVolatility.svelte +++ b/src/lib/components/ImpliedVolatility.svelte @@ -241,9 +241,9 @@ function findLowestAndhighestIV(data, lastDateStr) { $: { - if($assetType === 'stock' ? $stockTicker :$etfTicker && typeof window !== 'undefined') { + if($assetType === 'stock' ? $stockTicker : $etfTicker && typeof window !== 'undefined') { isLoaded=false; - const ticker = $assetType === 'stock' ? $stockTicker :$etfTicker + const ticker = $assetType === 'stock' ? $stockTicker : $etfTicker const asyncFunctions = [ getImpliedVolatility(ticker) ]; diff --git a/src/routes/etf/[tickerID]/+page.svelte b/src/routes/etf/[tickerID]/+page.svelte index c7578582..e0fec27a 100644 --- a/src/routes/etf/[tickerID]/+page.svelte +++ b/src/routes/etf/[tickerID]/+page.svelte @@ -3,7 +3,7 @@ import {AreaSeries, Chart, PriceLine, CandlestickSeries} from 'svelte-lightweight-charts'; import { TrackingModeExitMode } from 'lightweight-charts'; - import {getCache, setCache, optionsNetFlowComponent, optionComponent, sentimentComponent, varComponent, retailVolumeComponent, trendAnalysisComponent, priceAnalysisComponent, assetType, screenWidth, globalForm, userRegion, numberOfUnreadNotification, displayCompanyName, isCrosshairMoveActive, realtimePrice, priceIncrease, currentPortfolioPrice, currentPrice, clientSideCache, etfTicker, isOpen, isBeforeMarketOpen, isWeekend} from '$lib/store'; + import {getCache, setCache, impliedVolatilityComponent, optionsNetFlowComponent, optionComponent, sentimentComponent, varComponent, retailVolumeComponent, trendAnalysisComponent, priceAnalysisComponent, assetType, screenWidth, globalForm, userRegion, numberOfUnreadNotification, displayCompanyName, isCrosshairMoveActive, realtimePrice, priceIncrease, currentPortfolioPrice, currentPrice, clientSideCache, etfTicker, isOpen, isBeforeMarketOpen, isWeekend} from '$lib/store'; import { onDestroy, onMount } from 'svelte'; import ETFKeyInformation from '$lib/components/ETFKeyInformation.svelte'; import Lazy from '$lib/components/Lazy.svelte'; @@ -1304,6 +1304,14 @@ async function initializePrice() { + + +
+ {#await import('$lib/components/ImpliedVolatility.svelte') then {default: Comp}} + + {/await} +
+