numbani
numbani
NNuxt
Created by billyadelphia on 6/4/2024 in #❓・help
Error 500 on direct domain access (non www or subdomain)
this looks somehow similar to my issue. https://discord.com/channels/473401852243869706/1248695285052473494 do you get an error when you build and preview?
2 replies
NNuxt
Created by Ziko on 4/8/2024 in #❓・help
Getting Nuxt page (URL/Name) in API server request?
do you mean the params?
export default defineEventHandler(async (event) => {
const user =event.context.sessions?event.context.sessions.user.id: event.context.params?.user
const service = event.context.params?.service
if (!user) {
throw new Error("User not found")
}
if (!service) {
throw new Error("Service not found")
}
console.log("user:",user)
console.log("service:",service)
export default defineEventHandler(async (event) => {
const user =event.context.sessions?event.context.sessions.user.id: event.context.params?.user
const service = event.context.params?.service
if (!user) {
throw new Error("User not found")
}
if (!service) {
throw new Error("Service not found")
}
console.log("user:",user)
console.log("service:",service)
15 replies
NNuxt
Created by Coton on 4/7/2024 in #❓・help
Nuxt ui / UTable component : can we set a value to the column ?
i did something like this for my project, in my case i added two buttons in the same row, like the toggle in your pic,
<UTable :columns="columns" :rows="services" class="card rounded-md w-1/2">
<template #actions-data="{ row }">
<UButton color="gray" variant="ghost" icon="i-heroicons-trash-20-solid" />
<UButton
color="gray"
variant="ghost"
icon="i-heroicons-pencil-square-20-solid"
/>
</template>
</UTable>
<UTable :columns="columns" :rows="services" class="card rounded-md w-1/2">
<template #actions-data="{ row }">
<UButton color="gray" variant="ghost" icon="i-heroicons-trash-20-solid" />
<UButton
color="gray"
variant="ghost"
icon="i-heroicons-pencil-square-20-solid"
/>
</template>
</UTable>
2 replies