-
Notifications
You must be signed in to change notification settings - Fork 165
Update: cleanups, improvements #1966
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
The preview deployment failed. 🔴 Last updated at: 2025-06-03 07:26:31 CET |
The preview deployment failed. 🔴 Last updated at: 2025-06-03 07:26:30 CET |
src/routes/(console)/project-[region]-[project]/functions/templates/+page.ts
Outdated
Show resolved
Hide resolved
src/routes/(console)/project-[region]-[project]/functions/templates/+page.ts
Outdated
Show resolved
Hide resolved
src/routes/(console)/project-[region]-[project]/overview/+page.ts
Outdated
Show resolved
Hide resolved
TODO: load region based console variable early rather than per project. |
for (const project of projects) { | ||
project.region ??= 'default'; | ||
} | ||
sdk.forConsole.console.variables().then((vars) => consoleVariables.set(vars)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
using stores in +layout doesnt work that well 👍🏻
fetch(`${endpoint}/health/version`, { | ||
headers: { 'X-Appwrite-Project': project } | ||
}) | ||
.then((res) => res.json().catch(() => null)) | ||
.then((data) => version.set(data?.version)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same here we stores
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if we wanna put async data into stores, it should happen with the store, in the load functions 👍🏻
<svelte:fragment slot="header" let:root> | ||
<Table.Header.Cell column="dueDate" {root}>Due date</Table.Header.Cell> | ||
<Table.Header.Cell column="status" {root}>Status</Table.Header.Cell> | ||
<Table.Header.Cell column="amount" {root}>Amount due</Table.Header.Cell> | ||
<Table.Header.Cell column="action" {root} /> | ||
</svelte:fragment> | ||
|
||
{#if isLoadingInvoices} | ||
{#each Array.from({ length: 2 }) as _} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
because svelte 5 actually wants us to have keys for each. also a _
is not that clean :P
we would need to do:
{#each Array.from({ length: 2 }) as _} | |
{#each Array.from({ length: 2 }).keys() as index (index)} |
to have it clean ;-)
What does this PR do?
(Provide a description of what this PR does.)
Test Plan
(Write your test plan here. If you changed any code, please provide us with clear instructions on how you verified your changes work.)
Related PRs and Issues
(If this PR is related to any other PR or resolves any issue or related to any issue link all related PR and issues here.)
Have you read the Contributing Guidelines on issues?
(Write your answer here.)