Bobakanoosh
Explore posts from serversAarktype
•Created by Bobakanoosh on 11/15/2024 in #questions
Using scope with morphs
I store some data in a json file, so I'm using
string.json.parse
to read that data in and validate it.
Maybe I shouldn't be using scope here and should instead be directly using the windowMeta
type within the Record
?59 replies
Aarktype
•Created by Bobakanoosh on 11/15/2024 in #questions
Passing an exported scope to a function (Type 'string' is not assignable to type 'never')
Hello, I have an exported scope that I'm trying to pass to a generic class to be used.
I see that
.export()
yields type Module
, but I couldn't figure out how to use that either.
Appreciate any help16 replies
Aarktype
•Created by Bobakanoosh on 10/2/2024 in #questions
Customizing Error Messages
I've searched Github & Discord a bit and seen a few mentions of "full error customization", and am finding that I need it, but can't find any examples of it.
I have a type:
When these fields are incorrect, it yields the following error messages:
I want to show these outputs in-line in a form. To do that, I need some more customization like:
- Showing
email
instead of user.email
(I can use css capitalize to capitalize it if necessary)
- Getting rid of (was ___)
Right now my best option is to manually manipulate the string to make these changes, which isn't ideal.5 replies
Aarktype
•Created by Bobakanoosh on 10/2/2024 in #questions
v2 docs
I see the v2 docs mentioned frequently here and in GitHub, but I can’t find a link to them.
Are they deployed?
Even if they’re a WIP, they’d be extremely valuable to have I think
2 replies
i18n language auto detection not working
I have users telling me my site doesn't automatically detect their language.
I tried switching my browser and browser language to spanish, and it doesn't work (on ANY site, even google?).
My Accept-Language header is
es-ES,en-US;q=0.7,en;q=0.3
My navigator.language is es-ES
But no matter what when I delete the i18n_redirected
cookie, it recreates it en "en".
What setting do I need to change on chrome for a site to auto detect my language?5 replies
nuxt-i18n dynamically load translations
I want to make it easier for people helping translate my site by giving them an embedded JSON editor that as they change, updates the site. That way they can visually see where their translations are going.
Any idea how I could accomplish this?
23 replies
useCookie() not working
Maybe this is expected behavior. If not, I'll make a Github issue
I have
{ swr: true }
in a route rule. When on that route, when trying to use useCookie
, the cookie doesn't persist.
Here's a minimal reproduction:
https://stackblitz.com/edit/github-pvvuiv-4zjjl5?file=nuxt.config.ts,app.vue1 replies
swr: true breaks useCookie
Maybe this is expected behavior. If not, I'll make a Github issue
I have
{ swr: true }
in a route rule. When on that route, when trying to use useCookie
, the cookie doesn't persist.
Here's a minimal reproduction:
https://stackblitz.com/edit/github-pvvuiv-4zjjl5?file=nuxt.config.ts,app.vue1 replies
CDCloudflare Developers
•Created by Bobakanoosh on 4/4/2024 in #general-help
Workers & Billing Page Not Aligning
7 replies
Debug dev server warmup speed & build speed
Is there a way to debug the dev server warmup speed & build speed? Both of mine are very slow (80 seconds) but I have no idea whats causing it.
Vite client warmed up in 80606ms 7:03:33 PM
Vite server warmed up in 80820ms 7:03:33 PM
3 replies
CDCloudflare Developers
•Created by Bobakanoosh on 12/8/2023 in #general-help
s2 is not a function on pnpx wrangler deploy
I'm running
pnpx wrangler deploy
with the following wrangler.toml
to deploy a Nuxt 3 application from Windows 11.
Everything was working perfectly fine yesterday. I haven't found anything on google, in this discord, or as a Github issue.
Wrangler.toml:
Error:
3 replies
How to name route file *not* index.get.ts, etc
Is there a way to still use the folder-based api routes, but not name files
index
? I'm really used to navigating projects by just searching the files, not using the file tree.
I see that I could do posts.get.ts
, but having folders like /posts/
is nice too for related helper functions, etc1 replies