JJ
JJ
Explore posts from servers
NNuxt
Created by JJ on 9/18/2024 in #❓・help
Is there an equivalent to unstable_after() in h3?
https://nextjs.org/docs/app/api-reference/functions/unstable_after Im running into an issue with stripe where I need to respond quickly before doing some longer running tasks. Does Nuxt/nitro/h3 have some version of unstable_after() where i can send off a 200 status code then keep doing work in a serverless env?
8 replies
CCConvex Community
Created by JJ on 2/18/2024 in #support-community
Using usePreloadedQuery with nextjs 14 searchParams
Im having some trouble wrapping my head around the usePreloadQuery and search params. Say I want to have a filter that stores the state in the url, sadly nextjs14 seems to force you into using the client side route cache and toggling between the filters will see some data flicker (the route cache has old data). Should all of these actually be placed in layouts to avoid the cache when query params change?
2 replies
CCConvex Community
Created by JJ on 2/16/2024 in #support-community
Migration from postgres
Hello! Wondering if there is any docs or support availble to migrate from supabase -> convex +clerk. We are debating the switch due to simplified realtime + seamless realtime+RSC but fear the migration!
4 replies
NNuxt
Created by JJ on 5/22/2023 in #❓・help
Import .env into app{ head{ script{
Im loading a analytics script inside my nuxt.config.ts and want to dynamically change the key via an env var, but the scope doesnt have acess to process or useRUntimeConig, any thoughts:
app: {
head: {
script: [
{
hid: 'Rudder-JS',
src: 'https://myurl/dataPlane',
defer: true
},
{
hid: 'rudder-js',
innerHTML: `
rudderanalytics = window.rudderanalytics = [];
var methods = [
'load',
'page',
'track',
'identify',
'alias',
'group',
'ready',
'reset',
'getAnonymousId',
'setAnonymousId'
];
for (var i = 0; i < methods.length; i++) {
var method = methods[i];
rudderanalytics[method] = function (methodName) {
return function () {
rudderanalytics.push([methodName].concat(Array.prototype.slice.call(arguments)));
};
}(method);
}
const config = useRuntimeConfig()
console.log(config.rudderstack)
rudderanalytics.load(config.rudderstack,
'https://myurl',
{ configUrl: 'https://myurl' });

//rudderanalytics.page();
`,
type: 'text/javascript',

}
],
},
},
app: {
head: {
script: [
{
hid: 'Rudder-JS',
src: 'https://myurl/dataPlane',
defer: true
},
{
hid: 'rudder-js',
innerHTML: `
rudderanalytics = window.rudderanalytics = [];
var methods = [
'load',
'page',
'track',
'identify',
'alias',
'group',
'ready',
'reset',
'getAnonymousId',
'setAnonymousId'
];
for (var i = 0; i < methods.length; i++) {
var method = methods[i];
rudderanalytics[method] = function (methodName) {
return function () {
rudderanalytics.push([methodName].concat(Array.prototype.slice.call(arguments)));
};
}(method);
}
const config = useRuntimeConfig()
console.log(config.rudderstack)
rudderanalytics.load(config.rudderstack,
'https://myurl',
{ configUrl: 'https://myurl' });

//rudderanalytics.page();
`,
type: 'text/javascript',

}
],
},
},
12 replies