mirror of
https://github.com/modrinth/code.git
synced 2026-08-28 10:34:53 +00:00
chore: reduce frontend server memory & tracing (#7014)
* chore: reduce memory usage * feat: worker tracing * fix: eslint * fix: remove compat flag * fix: prettier
This commit is contained in:
@@ -103,7 +103,7 @@ import { useQuery } from '@tanstack/vue-query'
|
||||
import dayjs from 'dayjs'
|
||||
|
||||
import RevenueTransaction from '~/components/ui/dashboard/RevenueTransaction.vue'
|
||||
import { useGeneratedState } from '~/composables/generated'
|
||||
import { tremendousIdMap } from '~/generated/state.json'
|
||||
import { findRail } from '~/utils/muralpay-rails'
|
||||
|
||||
const { formatMessage } = useVIntl()
|
||||
@@ -114,7 +114,6 @@ const formatMonth = useFormatDateTime({
|
||||
})
|
||||
|
||||
const client = injectModrinthClient()
|
||||
const generatedState = useGeneratedState()
|
||||
|
||||
const messages = defineMessages({
|
||||
transactionsHeader: {
|
||||
@@ -281,7 +280,7 @@ function transactionsToCSV() {
|
||||
break
|
||||
case 'tremendous':
|
||||
if (txn.method_id) {
|
||||
const info = generatedState.value.tremendousIdMap?.[txn.method_id]
|
||||
const info = tremendousIdMap?.[txn.method_id]
|
||||
if (info) {
|
||||
methodOrSource = `Tremendous (${info.name})`
|
||||
break
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
<script setup lang="ts">
|
||||
import type { Labrinth } from '@modrinth/api-client'
|
||||
import { ServersManagePageIndex } from '@modrinth/ui'
|
||||
|
||||
import { useGeneratedState } from '~/composables/generated'
|
||||
import { products } from '~/generated/state.json'
|
||||
|
||||
definePageMeta({
|
||||
middleware: 'auth',
|
||||
@@ -12,14 +13,13 @@ useHead({
|
||||
})
|
||||
|
||||
const config = useRuntimeConfig()
|
||||
const generatedState = useGeneratedState()
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<ServersManagePageIndex
|
||||
:stripe-publishable-key="config.public.stripePublishableKey"
|
||||
:site-url="config.public.siteUrl"
|
||||
:products="generatedState.products || []"
|
||||
:products="(products ?? []) as Labrinth.Billing.Internal.Product[]"
|
||||
class="max-w-[1280px] py-0"
|
||||
/>
|
||||
</template>
|
||||
|
||||
Reference in New Issue
Block a user