add options page to etf

This commit is contained in:
MuslemRahimi 2025-01-05 15:32:02 +01:00
parent 3150504bab
commit f6c9b03b64
3 changed files with 1031 additions and 19 deletions

View File

@ -15,10 +15,10 @@
if (state !== "overview" && subSectionMap[state]) {
displaySubSection = state;
//goto(`/etf/${$etfTicker}${subSectionMap[state]}`);
//goto(`/stocks/${$etfTicker}${subSectionMap[state]}`);
} else {
displaySubSection = state;
//goto(`/etf/${$etfTicker}/statistics`);
//goto(`/stocks/${$etfTicker}/statistics`);
}
}
@ -64,7 +64,7 @@
</a>
<a
href={`/etf/${$etfTicker}/options/hottest-contracts`}
href={`/stocks/${$etfTicker}/options/hottest-contracts`}
on:click={() => changeSubSection("hottest-contracts")}
class="p-2 px-5 cursor-pointer {displaySubSection ===
'hottest-contracts'
@ -135,7 +135,7 @@
<ArrowLogo class="w-8 h-8 mr-3 flex-shrink-0" />
</div>
<span class="text-white p-3 ml-3 mr-3">
Build your Stock Screener to find profitable etf.
Build your Stock Screener to find profitable stocks.
</span>
</a>
</div>

View File

@ -18,7 +18,8 @@ export const load = async ({ locals, params }) => {
});
let output = await response.json();
output = user?.tier !== "Pro" ? output?.slice(0, 3) : output;
output.volume = user?.tier !== "Pro" ? output?.volume?.slice(0, 3) : output?.volume;
output.openInterest = user?.tier !== "Pro" ? output?.openInterest?.slice(0, 3) : output?.openInterest;
return output;
};