bnason
bnason
Explore posts from servers
NNuxt
Created by bnason on 6/24/2024 in #❓・help
Import is undefined
I have a very weird problem where only in my production build is a modules imported module undefined. I'm importing samlify and it is importing parts of node-forge, however in the dist chunk, the node-forge object does not have most of the imported code there. I'm really at a loss as to what is going on here.
1 replies
NNuxt
Created by bnason on 6/22/2024 in #❓・help
Environment dependent middleware
Is it possible to create a server middleware that is not deployed in production? Specifically I am deploying to CloudFlare and do not want to use my access log plugin that uses morgan.
3 replies
NNuxt
Created by bnason on 6/21/2024 in #❓・help
Express compatible request object
Is there an Express compatible request object available from a server route? I am trying to integrate samlify and it needs to parse the request but it seems the nitro request object is incompatible.
27 replies
NNuxt
Created by bnason on 6/21/2024 in #❓・help
Create new v4 app
I'd like to play around with whats out there for v4, how can I create a new application immediately using v4?
8 replies
NNuxt
Created by bnason on 6/18/2024 in #❓・help
nuxi upgrade --force not working
When I run npx nuxi@latest upgrade --force it shows what updates are available, but does not apply them to my package.json. The only thing I can think of is that my dependencies are fixed to specific versions in package.json so I don't accidentally upgrade unknowingly. Since the deps aren't specified as a range, does that prohibit nuxi from upgrading correctly?
2 replies
NNuxt
Created by bnason on 9/21/2023 in #❓・help
Server side worker thread
Is it possible/safe to create a server side worker thread for a long running up intensive task? If multiple of these tasks run, it slows down the responsiveness of the web interface. Hopefully moving them to their own threads should resolve that
10 replies
NNuxt
Created by bnason on 7/17/2023 in #❓・help
Unable to load module augmentation
I'm trying to use module augmentation to modify a third party library. I'm importing the file in my application, but I think the nuxt compilation process is stripping it out. Is there a specific place I need to put it and load it from?
1 replies
NNuxt
Created by bnason on 5/24/2023 in #❓・help
Underscore in runtimeConfig not loading env var
My nuxt config has effectively the following runtimeConfig: { foo_bar: '' } which should allow me to set via env vars using NUXT_FOO__BAR="baz" but it is not being loaded.
1 replies
NNuxt
Created by bnason on 5/23/2023 in #❓・help
nuxt build and oracledb binaries being removed
After running nuxt build, the resulting node_modules folder for the oracledb dependency seems to have had a lot of files removed. Specifically, I need to retain some binaries that exist. Does anyone know how to exclude it from whatever is cleaning it out?
1 replies
NNuxt
Created by bnason on 5/23/2023 in #❓・help
useState and redirection losing value
I'm using useState within my auth plugin and during the SSR, it redirects to the login page if they are not authenticated. It's also capturing the current path and saves it in a useState ref, however, when the redirect happens, it's doing an HTTP redirect, which basically creates a new request to the server which seems to re-call the ssr and that re-runs the plugin but this time it doesn't know about the previous requests path. Does anyone have any suggestions?
3 replies
NNuxt
Created by bnason on 5/20/2023 in #❓・help
Types for AppConfig
I've having a hard time with useAppConfig() The only types that come through are for a ui key, nothing else shows up.
3 replies
NNuxt
Created by bnason on 5/18/2023 in #❓・help
Import errors
I'm getting an error trying to use ts-results https://github.com/vultix/ts-results I'm using import { Ok, Err, Result } from 'ts-results' but I get an error on the console Named export 'Err' not found. it looks like it's trying to load it as a CommonJS module even though it has an ESM version available in the package. Is there anyway to get it to load that correctly?
1 replies