diff --git a/200.html b/200.html index 60101a1e..75fee913 100644 --- a/200.html +++ b/200.html @@ -27,4 +27,4 @@
- \ No newline at end of file + \ No newline at end of file diff --git a/404.html b/404.html index 60101a1e..75fee913 100644 --- a/404.html +++ b/404.html @@ -27,4 +27,4 @@
- \ No newline at end of file + \ No newline at end of file diff --git a/_nuxt/builds/latest.json b/_nuxt/builds/latest.json index 8f4a2c22..850ee34c 100644 --- a/_nuxt/builds/latest.json +++ b/_nuxt/builds/latest.json @@ -1 +1 @@ -{"id":"98449180-81c1-48bc-be70-d985db12c8b1","timestamp":1724940800902} \ No newline at end of file +{"id":"6bd4373c-8da9-4ff0-8e91-8e42a1ffcff7","timestamp":1724942466158} \ No newline at end of file diff --git a/_nuxt/builds/meta/6bd4373c-8da9-4ff0-8e91-8e42a1ffcff7.json b/_nuxt/builds/meta/6bd4373c-8da9-4ff0-8e91-8e42a1ffcff7.json new file mode 100644 index 00000000..3a7e219f --- /dev/null +++ b/_nuxt/builds/meta/6bd4373c-8da9-4ff0-8e91-8e42a1ffcff7.json @@ -0,0 +1 @@ +{"id":"6bd4373c-8da9-4ff0-8e91-8e42a1ffcff7","timestamp":1724942466158,"matcher":{"static":{},"wildcard":{},"dynamic":{}},"prerendered":["/","/authentication","/usage/services/serversupabaseclient","/get-started","/demo","/usage/services/serversupabasesession","/usage/services/serversupabaseuser","/usage/composables/usesupabasesession","/usage/composables/usesupabaseuser","/usage/composables/usesupabaseclient","/roadmap","/usage/services/serversupabaseservicerole","/changelog"]} \ No newline at end of file diff --git a/_nuxt/builds/meta/98449180-81c1-48bc-be70-d985db12c8b1.json b/_nuxt/builds/meta/98449180-81c1-48bc-be70-d985db12c8b1.json deleted file mode 100644 index 18a2e5b2..00000000 --- a/_nuxt/builds/meta/98449180-81c1-48bc-be70-d985db12c8b1.json +++ /dev/null @@ -1 +0,0 @@ -{"id":"98449180-81c1-48bc-be70-d985db12c8b1","timestamp":1724940800902,"matcher":{"static":{},"wildcard":{},"dynamic":{}},"prerendered":["/","/get-started","/authentication","/usage/services/serversupabaseclient","/demo","/usage/services/serversupabasesession","/usage/services/serversupabaseuser","/usage/composables/usesupabasesession","/usage/composables/usesupabaseuser","/roadmap","/usage/services/serversupabaseservicerole","/usage/composables/usesupabaseclient","/changelog"]} \ No newline at end of file diff --git a/_payload.json b/_payload.json index 49dfc746..68c5d765 100644 --- a/_payload.json +++ b/_payload.json @@ -1 +1 @@ -[{"data":1,"prerenderedAt":374},["ShallowReactive",2],{"navigation":3,"index":58,"1CZYD6bgNK":110,"q3uGftTUSs":135},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":59,"_dir":60,"_draft":61,"_partial":61,"_locale":60,"title":62,"description":63,"navigation":61,"hero":64,"features":78,"_id":104,"_type":105,"_source":106,"_file":107,"_stem":108,"_extension":109},"/","",false,"Nuxt Supabase - Home","A supa simple wrapper around supabase-js to enable usage and integration within Nuxt.",{"title":65,"description":63,"orientation":66,"links":67,"code":77},"Nuxt [Supabase]{.text-primary}","horizontal",[68,71],{"label":69,"icon":7,"to":6,"size":70},"Get started","lg",{"label":72,"icon":73,"color":74,"to":75,"target":76,"size":70},"Star on github","i-heroicons-star","white","https://github.com/nuxt-modules/supabase","_blank","```ts\n const supabase = useSupabaseClient()\n const email = ref('')\n\n const signInWithOtp = async () => {\n await supabase.auth.signInWithOtp({\n email: email.value,\n })\n }\n```\n",{"title":79,"items":80},"Shipped with many features",[81,85,89,93,97,100],{"title":82,"icon":83,"to":84,"target":76},"Nuxt 3 ready","i-simple-icons-nuxtdotjs","https://nuxt.com",{"title":86,"icon":87,"to":88,"target":76},"Vue 3 composables","i-simple-icons-vuedotjs","https://vuejs.org/guide/reusability/composables.html",{"title":90,"icon":91,"to":92,"target":76},"Supabase-js V2","i-simple-icons-supabase","https://supabase.com",{"title":94,"icon":95,"to":96},"Usage in API server routes","i-heroicons-server","usage/services/serversupabaseclient",{"title":98,"icon":99,"to":10},"Authentication support","i-heroicons-key",{"title":101,"icon":102,"to":103,"target":76},"TypeScript support","i-simple-icons-typescript","https://www.typescriptlang.org","content:index.yml","yaml","content","index.yml","index","yml",{"data":111,"body":113,"excerpt":-1,"toc":132},{"title":60,"description":112},"Nuxt Supabase",{"type":114,"children":115},"root",[116],{"type":117,"tag":118,"props":119,"children":120},"element","p",{},[121,124],{"type":122,"value":123},"text","Nuxt ",{"type":117,"tag":125,"props":126,"children":129},"span",{"className":127},[128],"text-primary",[130],{"type":122,"value":131},"Supabase",{"title":60,"searchDepth":133,"depth":133,"links":134},2,[],{"data":136,"body":137,"excerpt":-1,"toc":372},{"title":60,"description":60},{"type":114,"children":138},[139,366],{"type":117,"tag":140,"props":141,"children":145},"pre",{"className":142,"code":143,"language":144,"meta":60,"style":60},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight"," const supabase = useSupabaseClient()\n const email = ref('')\n\n const signInWithOtp = async () => {\n await supabase.auth.signInWithOtp({\n email: email.value,\n })\n }\n","ts",[146],{"type":117,"tag":147,"props":148,"children":149},"code",{"__ignoreMap":60},[150,184,220,230,267,311,344,357],{"type":117,"tag":125,"props":151,"children":154},{"class":152,"line":153},"line",1,[155,161,167,173,179],{"type":117,"tag":125,"props":156,"children":158},{"style":157},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[159],{"type":122,"value":160}," const",{"type":117,"tag":125,"props":162,"children":164},{"style":163},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[165],{"type":122,"value":166}," supabase ",{"type":117,"tag":125,"props":168,"children":170},{"style":169},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[171],{"type":122,"value":172},"=",{"type":117,"tag":125,"props":174,"children":176},{"style":175},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[177],{"type":122,"value":178}," useSupabaseClient",{"type":117,"tag":125,"props":180,"children":181},{"style":163},[182],{"type":122,"value":183},"()\n",{"type":117,"tag":125,"props":185,"children":186},{"class":152,"line":133},[187,191,196,200,205,210,215],{"type":117,"tag":125,"props":188,"children":189},{"style":157},[190],{"type":122,"value":160},{"type":117,"tag":125,"props":192,"children":193},{"style":163},[194],{"type":122,"value":195}," email ",{"type":117,"tag":125,"props":197,"children":198},{"style":169},[199],{"type":122,"value":172},{"type":117,"tag":125,"props":201,"children":202},{"style":175},[203],{"type":122,"value":204}," ref",{"type":117,"tag":125,"props":206,"children":207},{"style":163},[208],{"type":122,"value":209},"(",{"type":117,"tag":125,"props":211,"children":212},{"style":169},[213],{"type":122,"value":214},"''",{"type":117,"tag":125,"props":216,"children":217},{"style":163},[218],{"type":122,"value":219},")\n",{"type":117,"tag":125,"props":221,"children":223},{"class":152,"line":222},3,[224],{"type":117,"tag":125,"props":225,"children":227},{"emptyLinePlaceholder":226},true,[228],{"type":122,"value":229},"\n",{"type":117,"tag":125,"props":231,"children":233},{"class":152,"line":232},4,[234,238,243,247,252,257,262],{"type":117,"tag":125,"props":235,"children":236},{"style":157},[237],{"type":122,"value":160},{"type":117,"tag":125,"props":239,"children":240},{"style":163},[241],{"type":122,"value":242}," signInWithOtp ",{"type":117,"tag":125,"props":244,"children":245},{"style":169},[246],{"type":122,"value":172},{"type":117,"tag":125,"props":248,"children":249},{"style":157},[250],{"type":122,"value":251}," async",{"type":117,"tag":125,"props":253,"children":254},{"style":169},[255],{"type":122,"value":256}," ()",{"type":117,"tag":125,"props":258,"children":259},{"style":157},[260],{"type":122,"value":261}," =>",{"type":117,"tag":125,"props":263,"children":264},{"style":169},[265],{"type":122,"value":266}," {\n",{"type":117,"tag":125,"props":268,"children":270},{"class":152,"line":269},5,[271,277,282,287,292,296,301,306],{"type":117,"tag":125,"props":272,"children":274},{"style":273},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[275],{"type":122,"value":276}," await",{"type":117,"tag":125,"props":278,"children":279},{"style":163},[280],{"type":122,"value":281}," supabase",{"type":117,"tag":125,"props":283,"children":284},{"style":169},[285],{"type":122,"value":286},".",{"type":117,"tag":125,"props":288,"children":289},{"style":163},[290],{"type":122,"value":291},"auth",{"type":117,"tag":125,"props":293,"children":294},{"style":169},[295],{"type":122,"value":286},{"type":117,"tag":125,"props":297,"children":298},{"style":175},[299],{"type":122,"value":300},"signInWithOtp",{"type":117,"tag":125,"props":302,"children":304},{"style":303},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[305],{"type":122,"value":209},{"type":117,"tag":125,"props":307,"children":308},{"style":169},[309],{"type":122,"value":310},"{\n",{"type":117,"tag":125,"props":312,"children":314},{"class":152,"line":313},6,[315,320,325,330,334,339],{"type":117,"tag":125,"props":316,"children":317},{"style":303},[318],{"type":122,"value":319}," email",{"type":117,"tag":125,"props":321,"children":322},{"style":169},[323],{"type":122,"value":324},":",{"type":117,"tag":125,"props":326,"children":327},{"style":163},[328],{"type":122,"value":329}," email",{"type":117,"tag":125,"props":331,"children":332},{"style":169},[333],{"type":122,"value":286},{"type":117,"tag":125,"props":335,"children":336},{"style":163},[337],{"type":122,"value":338},"value",{"type":117,"tag":125,"props":340,"children":341},{"style":169},[342],{"type":122,"value":343},",\n",{"type":117,"tag":125,"props":345,"children":347},{"class":152,"line":346},7,[348,353],{"type":117,"tag":125,"props":349,"children":350},{"style":169},[351],{"type":122,"value":352}," }",{"type":117,"tag":125,"props":354,"children":355},{"style":303},[356],{"type":122,"value":219},{"type":117,"tag":125,"props":358,"children":360},{"class":152,"line":359},8,[361],{"type":117,"tag":125,"props":362,"children":363},{"style":169},[364],{"type":122,"value":365}," }\n",{"type":117,"tag":367,"props":368,"children":369},"style",{},[370],{"type":122,"value":371},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":60,"searchDepth":133,"depth":133,"links":373},[],1724940857968] \ No newline at end of file +[{"data":1,"prerenderedAt":374},["ShallowReactive",2],{"navigation":3,"index":58,"1CZYD6bgNK":110,"q3uGftTUSs":135},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":59,"_dir":60,"_draft":61,"_partial":61,"_locale":60,"title":62,"description":63,"navigation":61,"hero":64,"features":78,"_id":104,"_type":105,"_source":106,"_file":107,"_stem":108,"_extension":109},"/","",false,"Nuxt Supabase - Home","A supa simple wrapper around supabase-js to enable usage and integration within Nuxt.",{"title":65,"description":63,"orientation":66,"links":67,"code":77},"Nuxt [Supabase]{.text-primary}","horizontal",[68,71],{"label":69,"icon":7,"to":6,"size":70},"Get started","lg",{"label":72,"icon":73,"color":74,"to":75,"target":76,"size":70},"Star on github","i-heroicons-star","white","https://github.com/nuxt-modules/supabase","_blank","```ts\n const supabase = useSupabaseClient()\n const email = ref('')\n\n const signInWithOtp = async () => {\n await supabase.auth.signInWithOtp({\n email: email.value,\n })\n }\n```\n",{"title":79,"items":80},"Shipped with many features",[81,85,89,93,97,100],{"title":82,"icon":83,"to":84,"target":76},"Nuxt 3 ready","i-simple-icons-nuxtdotjs","https://nuxt.com",{"title":86,"icon":87,"to":88,"target":76},"Vue 3 composables","i-simple-icons-vuedotjs","https://vuejs.org/guide/reusability/composables.html",{"title":90,"icon":91,"to":92,"target":76},"Supabase-js V2","i-simple-icons-supabase","https://supabase.com",{"title":94,"icon":95,"to":96},"Usage in API server routes","i-heroicons-server","usage/services/serversupabaseclient",{"title":98,"icon":99,"to":10},"Authentication support","i-heroicons-key",{"title":101,"icon":102,"to":103,"target":76},"TypeScript support","i-simple-icons-typescript","https://www.typescriptlang.org","content:index.yml","yaml","content","index.yml","index","yml",{"data":111,"body":113,"excerpt":-1,"toc":132},{"title":60,"description":112},"Nuxt Supabase",{"type":114,"children":115},"root",[116],{"type":117,"tag":118,"props":119,"children":120},"element","p",{},[121,124],{"type":122,"value":123},"text","Nuxt ",{"type":117,"tag":125,"props":126,"children":129},"span",{"className":127},[128],"text-primary",[130],{"type":122,"value":131},"Supabase",{"title":60,"searchDepth":133,"depth":133,"links":134},2,[],{"data":136,"body":137,"excerpt":-1,"toc":372},{"title":60,"description":60},{"type":114,"children":138},[139,366],{"type":117,"tag":140,"props":141,"children":145},"pre",{"className":142,"code":143,"language":144,"meta":60,"style":60},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight"," const supabase = useSupabaseClient()\n const email = ref('')\n\n const signInWithOtp = async () => {\n await supabase.auth.signInWithOtp({\n email: email.value,\n })\n }\n","ts",[146],{"type":117,"tag":147,"props":148,"children":149},"code",{"__ignoreMap":60},[150,184,220,230,267,311,344,357],{"type":117,"tag":125,"props":151,"children":154},{"class":152,"line":153},"line",1,[155,161,167,173,179],{"type":117,"tag":125,"props":156,"children":158},{"style":157},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[159],{"type":122,"value":160}," const",{"type":117,"tag":125,"props":162,"children":164},{"style":163},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[165],{"type":122,"value":166}," supabase ",{"type":117,"tag":125,"props":168,"children":170},{"style":169},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[171],{"type":122,"value":172},"=",{"type":117,"tag":125,"props":174,"children":176},{"style":175},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[177],{"type":122,"value":178}," useSupabaseClient",{"type":117,"tag":125,"props":180,"children":181},{"style":163},[182],{"type":122,"value":183},"()\n",{"type":117,"tag":125,"props":185,"children":186},{"class":152,"line":133},[187,191,196,200,205,210,215],{"type":117,"tag":125,"props":188,"children":189},{"style":157},[190],{"type":122,"value":160},{"type":117,"tag":125,"props":192,"children":193},{"style":163},[194],{"type":122,"value":195}," email ",{"type":117,"tag":125,"props":197,"children":198},{"style":169},[199],{"type":122,"value":172},{"type":117,"tag":125,"props":201,"children":202},{"style":175},[203],{"type":122,"value":204}," ref",{"type":117,"tag":125,"props":206,"children":207},{"style":163},[208],{"type":122,"value":209},"(",{"type":117,"tag":125,"props":211,"children":212},{"style":169},[213],{"type":122,"value":214},"''",{"type":117,"tag":125,"props":216,"children":217},{"style":163},[218],{"type":122,"value":219},")\n",{"type":117,"tag":125,"props":221,"children":223},{"class":152,"line":222},3,[224],{"type":117,"tag":125,"props":225,"children":227},{"emptyLinePlaceholder":226},true,[228],{"type":122,"value":229},"\n",{"type":117,"tag":125,"props":231,"children":233},{"class":152,"line":232},4,[234,238,243,247,252,257,262],{"type":117,"tag":125,"props":235,"children":236},{"style":157},[237],{"type":122,"value":160},{"type":117,"tag":125,"props":239,"children":240},{"style":163},[241],{"type":122,"value":242}," signInWithOtp ",{"type":117,"tag":125,"props":244,"children":245},{"style":169},[246],{"type":122,"value":172},{"type":117,"tag":125,"props":248,"children":249},{"style":157},[250],{"type":122,"value":251}," async",{"type":117,"tag":125,"props":253,"children":254},{"style":169},[255],{"type":122,"value":256}," ()",{"type":117,"tag":125,"props":258,"children":259},{"style":157},[260],{"type":122,"value":261}," =>",{"type":117,"tag":125,"props":263,"children":264},{"style":169},[265],{"type":122,"value":266}," {\n",{"type":117,"tag":125,"props":268,"children":270},{"class":152,"line":269},5,[271,277,282,287,292,296,301,306],{"type":117,"tag":125,"props":272,"children":274},{"style":273},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[275],{"type":122,"value":276}," await",{"type":117,"tag":125,"props":278,"children":279},{"style":163},[280],{"type":122,"value":281}," supabase",{"type":117,"tag":125,"props":283,"children":284},{"style":169},[285],{"type":122,"value":286},".",{"type":117,"tag":125,"props":288,"children":289},{"style":163},[290],{"type":122,"value":291},"auth",{"type":117,"tag":125,"props":293,"children":294},{"style":169},[295],{"type":122,"value":286},{"type":117,"tag":125,"props":297,"children":298},{"style":175},[299],{"type":122,"value":300},"signInWithOtp",{"type":117,"tag":125,"props":302,"children":304},{"style":303},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[305],{"type":122,"value":209},{"type":117,"tag":125,"props":307,"children":308},{"style":169},[309],{"type":122,"value":310},"{\n",{"type":117,"tag":125,"props":312,"children":314},{"class":152,"line":313},6,[315,320,325,330,334,339],{"type":117,"tag":125,"props":316,"children":317},{"style":303},[318],{"type":122,"value":319}," email",{"type":117,"tag":125,"props":321,"children":322},{"style":169},[323],{"type":122,"value":324},":",{"type":117,"tag":125,"props":326,"children":327},{"style":163},[328],{"type":122,"value":329}," email",{"type":117,"tag":125,"props":331,"children":332},{"style":169},[333],{"type":122,"value":286},{"type":117,"tag":125,"props":335,"children":336},{"style":163},[337],{"type":122,"value":338},"value",{"type":117,"tag":125,"props":340,"children":341},{"style":169},[342],{"type":122,"value":343},",\n",{"type":117,"tag":125,"props":345,"children":347},{"class":152,"line":346},7,[348,353],{"type":117,"tag":125,"props":349,"children":350},{"style":169},[351],{"type":122,"value":352}," }",{"type":117,"tag":125,"props":354,"children":355},{"style":303},[356],{"type":122,"value":219},{"type":117,"tag":125,"props":358,"children":360},{"class":152,"line":359},8,[361],{"type":117,"tag":125,"props":362,"children":363},{"style":169},[364],{"type":122,"value":365}," }\n",{"type":117,"tag":367,"props":368,"children":369},"style",{},[370],{"type":122,"value":371},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":60,"searchDepth":133,"depth":133,"links":373},[],1724942521949] \ No newline at end of file diff --git a/api/_content/cache.1724940796509.json b/api/_content/cache.1724942461696.json similarity index 99% rename from api/_content/cache.1724940796509.json rename to api/_content/cache.1724942461696.json index abcd4c15..88ed2c71 100644 --- a/api/_content/cache.1724940796509.json +++ b/api/_content/cache.1724942461696.json @@ -1 +1 @@ -{"generatedAt":1724940857912,"generateTime":4207,"contents":[{"_path":"/get-started","_dir":"","_draft":false,"_partial":false,"_locale":"","title":"Get Started","description":"@nuxtjs/supabase is a Nuxt module for first class integration with Supabase.","icon":"i-heroicons-rocket-launch","body":{"type":"root","children":[{"type":"element","tag":"p","props":{},"children":[{"type":"element","tag":"a","props":{"href":"https://github.com/nuxt-modules/supabase","rel":["nofollow"]},"children":[{"type":"text","value":"@nuxtjs/supabase"}]},{"type":"text","value":" is a Nuxt module for first class integration with Supabase."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Checkout the "},{"type":"element","tag":"a","props":{"href":"https://v3.nuxtjs.org","rel":["nofollow"]},"children":[{"type":"text","value":"Nuxt 3"}]},{"type":"text","value":" documentation and "},{"type":"element","tag":"a","props":{"href":"https://supabase.com","rel":["nofollow"]},"children":[{"type":"text","value":"Supabase"}]},{"type":"text","value":" to learn more."}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-exclamation-triangle-20-solid","color":"amber"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"For integrating Supabase with Nuxt 2, checkout "},{"type":"element","tag":"a","props":{"href":"https://github.com/supabase-community/nuxt-supabase","rel":["nofollow"]},"children":[{"type":"text","value":"supabase-community/nuxt-supabase"}]},{"type":"text","value":"."}]}]},{"type":"element","tag":"h2","props":{"id":"installation"},"children":[{"type":"text","value":"Installation"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Add "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"@nuxtjs/supabase"}]},{"type":"text","value":" dev dependency to your project:"}]},{"type":"element","tag":"pre","props":{"className":"language-bash shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"npx nuxi@latest module add supabase\n","language":"bash","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":"npx"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" nuxi@latest"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" module"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" add"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" supabase\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Add "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"@nuxtjs/supabase"}]},{"type":"text","value":" to the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"modules"}]},{"type":"text","value":" section of "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"nuxt.config.ts"}]},{"type":"text","value":":"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"export default defineNuxtConfig({\n modules: ['@nuxtjs/supabase'],\n})\n","filename":"nuxt.config.ts","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"export"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" default"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" defineNuxtConfig"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" modules"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" ["}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"@nuxtjs/supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"]"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Add "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"SUPABASE_URL"}]},{"type":"text","value":" and "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"SUPABASE_KEY"}]},{"type":"text","value":" to the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":".env"}]},{"type":"text","value":":"}]},{"type":"element","tag":"pre","props":{"className":"language-bash shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"SUPABASE_URL=\"https://example.supabase.co\"\nSUPABASE_KEY=\"\"\n","filename":"env","language":"bash","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"SUPABASE_URL"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"https://example.supabase.co"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"SUPABASE_KEY"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\"\n"}]}]}]}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-light-bulb"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Alternatively, you can prefix the env variables with "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"NUXT_PUBLIC_"}]},{"type":"text","value":" in order to use runtimeConfig."}]}]},{"type":"element","tag":"h2","props":{"id":"options"},"children":[{"type":"text","value":"Options"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"You can configure the supabase module by using the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"supabase"}]},{"type":"text","value":" key in "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"nuxt.config"}]},{"type":"text","value":":"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"export default defineNuxtConfig({\n // ...\n supabase: {\n // Options\n }\n}\n","filename":"nuxt.config.ts","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"export"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" default"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" defineNuxtConfig"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" // ...\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" // Options\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}\n"}]}]}]}]},{"type":"element","tag":"h3","props":{"id":"url"},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"url"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Default: "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"process.env.SUPABASE_URL"}]},{"type":"text","value":" (ex: "},{"type":"element","tag":"a","props":{"href":"https://example.supabase.co","rel":["nofollow"]},"children":[{"type":"text","value":"https://example.supabase.co"}]},{"type":"text","value":")"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"The unique Supabase URL which is supplied when you create a new project in your project dashboard."}]},{"type":"element","tag":"h3","props":{"id":"key"},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"key"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Default: "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"process.env.SUPABASE_KEY"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Supabase 'anon key', used to bypass the Supabase API gateway and interact with your Supabase database making use of user JWT to apply RLS Policies."}]},{"type":"element","tag":"h3","props":{"id":"servicekey"},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"serviceKey"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Default: "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"process.env.SUPABASE_SERVICE_KEY"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Supabase 'service role key', has super admin rights and can bypass your Row Level Security."}]},{"type":"element","tag":"h3","props":{"id":"redirect"},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"redirect"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Default: "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"true"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Redirect automatically to the configured login page if a non authenticated user is trying to access a guarded. You can disable all redirects by setting this option to false."}]},{"type":"element","tag":"h3","props":{"id":"redirectoptions"},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"redirectOptions"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Default:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":" redirectOptions: {\n login: '/login',\n callback: '/confirm',\n include: undefined,\n exclude: [],\n cookieRedirect: false,\n }\n","filename":"nuxt.config.ts","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" redirectOptions"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" login"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/login"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" callback"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/confirm"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" include"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" undefined,\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" exclude"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" []"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" cookieRedirect"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC"},"children":[{"type":"text","value":" false"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]}]}]},{"type":"element","tag":"ul","props":{},"children":[{"type":"element","tag":"li","props":{},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"login"}]},{"type":"text","value":": User will be redirected to this path if not authenticated or after logout."}]},{"type":"element","tag":"li","props":{},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"callback"}]},{"type":"text","value":": This is the path the user will be redirect to after supabase login redirection. Should match configured "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"redirectTo"}]},{"type":"text","value":" option of your "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/reference/javascript/auth-signinwithoauth","rel":["nofollow"]},"children":[{"type":"text","value":"signIn method"}]},{"type":"text","value":". Should also be configured in your Supabase dashboard under "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"Authentication -> URL Configuration -> Redirect URLs"}]},{"type":"text","value":"."}]},{"type":"element","tag":"li","props":{},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"include"}]},{"type":"text","value":": Routes to include in the redirect. "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"['/admin(/*)?']"}]},{"type":"text","value":" will enable the redirect only for the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"admin"}]},{"type":"text","value":" page and all sub-pages."}]},{"type":"element","tag":"li","props":{},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"exclude"}]},{"type":"text","value":": Routes to exclude from the redirect. "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"['/foo', '/bar/*']"}]},{"type":"text","value":" will exclude the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"foo"}]},{"type":"text","value":" page and all pages in your "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"bar"}]},{"type":"text","value":" folder."}]},{"type":"element","tag":"li","props":{},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"cookieRedirect"}]},{"type":"text","value":": Sets a cookie containing the path an unauthenticated user tried to access. The cookie can then be used on the "},{"type":"element","tag":"a","props":{"href":"https://supabase.nuxtjs.org/authentication#confirm-page-confirm","rel":["nofollow"]},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"/confirm"}]}]},{"type":"text","value":" page to redirect the user to the page they previously tried to visit."}]}]},{"type":"element","tag":"h3","props":{"id":"cookiename"},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"cookieName"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Default: "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"sb"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Cookie name used for storing the redirect path when using the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"redirect"}]},{"type":"text","value":" option, added in front of "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"-redirect-path"}]},{"type":"text","value":" to form the full cookie name e.g. "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"sb-redirect-path"}]}]},{"type":"element","tag":"h3","props":{"id":"cookieoptions"},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"cookieOptions"}]}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":" cookieOptions: {\n maxAge: 60 * 60 * 8,\n sameSite: 'lax',\n secure: true\n }\n","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" cookieOptions"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" maxAge"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C"},"children":[{"type":"text","value":" 60"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" *"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C"},"children":[{"type":"text","value":" 60"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" *"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C"},"children":[{"type":"text","value":" 8"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" sameSite"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"lax"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" secure"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC"},"children":[{"type":"text","value":" true\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Options for cookies used to share tokens between server and client, refer to "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/api/composables/use-cookie#options","rel":["nofollow"]},"children":[{"type":"text","value":"cookieOptions"}]},{"type":"text","value":" for available settings. Please note that the lifetime set here does not determine the Supabase session lifetime."}]},{"type":"element","tag":"h3","props":{"id":"types"},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"types"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Default: "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"./types/database.types.ts"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"The path for the generated Supabase TypeScript definitions. The database definitions will be automatically passed to all clients: "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"useSupabaseClient"}]},{"type":"text","value":", "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"serverSupabaseClient"}]},{"type":"text","value":" and "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"serverSupabaseServiceRole"}]},{"type":"text","value":"."}]},{"type":"element","tag":"pre","props":{"className":"language-bash shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"## Generate types from live database\nsupabase gen types --lang=typescript --project-id YourProjectId > types/database.types.ts\n\n## Generate types when using local environment\nsupabase gen types --lang=typescript --local > types/database.types.ts\n","language":"bash","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"## Generate types from live database\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":"supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" gen"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" types"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" --lang=typescript"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" --project-id"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" YourProjectId"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" >"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" types/database.types.ts\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"## Generate types when using local environment\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":"supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" gen"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" types"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" --lang=typescript"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" --local"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" >"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" types/database.types.ts\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Set to "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"false"}]},{"type":"text","value":" to disable."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Check Supabase "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/reference/javascript/release-notes#typescript-support","rel":["nofollow"]},"children":[{"type":"text","value":"documentation"}]},{"type":"text","value":" for further information."}]},{"type":"element","tag":"h3","props":{"id":"clientoptions"},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"clientOptions"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Default:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":" clientOptions: { }\n","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" clientOptions"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Supabase client options "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/reference/javascript/initializing#parameters","rel":["nofollow"]},"children":[{"type":"text","value":"available here"}]},{"type":"text","value":" merged with default values from "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"@supabase/ssr"}]},{"type":"text","value":":"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":" clientOptions: {\n auth: {\n flowType: 'pkce',\n autoRefreshToken: isBrowser(),\n detectSessionInUrl: isBrowser(),\n persistSession: true,\n },\n }\n","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" clientOptions"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" auth"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" flowType"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"pkce"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" autoRefreshToken"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" isBrowser"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" detectSessionInUrl"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" isBrowser"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" persistSession"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC"},"children":[{"type":"text","value":" true"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" },\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":8},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]}]}]},{"type":"element","tag":"h2","props":{"id":"demo"},"children":[{"type":"text","value":"Demo"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"A live demo is made for see this module in action on "},{"type":"element","tag":"a","props":{"href":"https://n3-supabase.netlify.app","rel":["nofollow"]},"children":[{"type":"text","value":"n3-supabase.netlify.app"}]},{"type":"text","value":", read more in the "},{"type":"element","tag":"a","props":{"href":"/demo"},"children":[{"type":"text","value":"demo section"}]},{"type":"text","value":"."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"element","tag":"a","props":{"href":"https://n3-supabase.netlify.app","rel":["nofollow"]},"children":[{"type":"element","tag":"img","props":{"alt":"Supabase demo with Nuxt 3","src":"https://user-images.githubusercontent.com/904724/160422461-8f87500a-8dec-4413-86b2-ba04e1b2d17b.png"},"children":[]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Also checkout the "},{"type":"element","tag":"a","props":{"href":"https://www.youtube.com/watch?v=jIyiRT6zT8Q","rel":["nofollow"]},"children":[{"type":"text","value":"YouTube video"}]},{"type":"text","value":" about its usage in a live demo."}]},{"type":"element","tag":"style","props":{},"children":[{"type":"text","value":"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}"}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[{"id":"installation","depth":2,"text":"Installation"},{"id":"options","depth":2,"text":"Options","children":[{"id":"url","depth":3,"text":"url"},{"id":"key","depth":3,"text":"key"},{"id":"servicekey","depth":3,"text":"serviceKey"},{"id":"redirect","depth":3,"text":"redirect"},{"id":"redirectoptions","depth":3,"text":"redirectOptions"},{"id":"cookiename","depth":3,"text":"cookieName"},{"id":"cookieoptions","depth":3,"text":"cookieOptions"},{"id":"types","depth":3,"text":"types"},{"id":"clientoptions","depth":3,"text":"clientOptions"}]},{"id":"demo","depth":2,"text":"Demo"}]}},"_type":"markdown","_id":"content:2.get-started.md","_source":"content","_file":"2.get-started.md","_stem":"2.get-started","_extension":"md"},{"_path":"/authentication","_dir":"","_draft":false,"_partial":false,"_locale":"","title":"Authentication","description":"Authenticate your user thanks to the PKCE Oauth protocol that enables secure exchange of refresh and access tokens between an application and the authorization server","icon":"i-heroicons-lock-closed","body":{"type":"root","children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"With the default options, the module requires a log-in page and a confirm page to handle the "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/guides/resources/glossary#pkce","rel":["nofollow"]},"children":[{"type":"text","value":"PKCE authorization code flow"}]},{"type":"text","value":". If you want to understand how it works under the hood, you can read this "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/guides/auth/server-side-rendering#understanding-the-authentication-flow","rel":["nofollow"]},"children":[{"type":"text","value":"section"}]},{"type":"text","value":"."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"All you need to do is to create a "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"login.vue"}]},{"type":"text","value":" and "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"confirm.vue"}]},{"type":"text","value":" page in the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"pages"}]},{"type":"text","value":" folder."}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-light-bulb"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"For advanced users who want to implement the auth behaviour themselves, you can disable or override the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirect"},"children":[{"type":"text","value":"redirect options"}]},{"type":"text","value":"."}]}]},{"type":"element","tag":"h2","props":{"id":"log-in-page-login"},"children":[{"type":"text","value":"Log-in page - "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"/login"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Each time a user is trying to access a page that needs authentication, he will automatically be redirected to the configured log in page. If you want to allow access to \"public\" page, you just need to add them in the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirectoptions"},"children":[{"type":"text","value":"exclude"}]},{"type":"text","value":" redirect option. Alternatively, you can enable the redirect only for certain routes using the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirectoptions"},"children":[{"type":"text","value":"include"}]},{"type":"text","value":" redirect option."}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-exclamation-triangle-20-solid","color":"amber"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Ensure to activate the authentication providers you want in the Supabase Dashboard under "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"Authentication -> Providers"}]},{"type":"text","value":"."}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"The log-in page initiates the log-in method(s) you choose from the "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/reference/javascript/auth-signinwithpassword","rel":["nofollow"]},"children":[{"type":"text","value":"available authorization methods"}]},{"type":"text","value":" provided by Supabase, it could looks like:"}]},{"type":"element","tag":"pre","props":{"className":"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"\n\n","filename":"pages/login.vue","language":"vue","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"script"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" setup"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" lang"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"ts"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" supabase "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseClient"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" email "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" ref"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"''"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" signInWithOtp "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" error"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"auth"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"signInWithOtp"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" email"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" email"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":8},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" options"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":9},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" emailRedirectTo"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"http://localhost:3000/confirm"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":10},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":11},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":12},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" if"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"error"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":") "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"console"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"log"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"error"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":13},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":14},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":15},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"template"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":16},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" <"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"div"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":17},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" <"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"button"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" @"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"click"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"signInWithOtp"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":18},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" Sign In with E-Mail\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":19},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" \n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":20},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" <"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"input\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":21},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" v-model"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"email"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":22},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" type"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"email"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":23},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" />\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":24},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" \n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":25},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Once the authorization flow is triggered using the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"auth"}]},{"type":"text","value":" wrapper of the "},{"type":"element","tag":"a","props":{"href":"/usage/composables/usesupabaseclient"},"children":[{"type":"text","value":"useSupabaseClient"}]},{"type":"text","value":" composable, the session management is handled automatically and the user will be redirected to the page you specify in the redirect option ("},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"/confirm"}]},{"type":"text","value":" by default)."}]},{"type":"element","tag":"h2","props":{"id":"confirm-page-confirm"},"children":[{"type":"text","value":"Confirm page - "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"/confirm"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"The confirmation page receives the supabase callback. From there you can check the user value and redirect to the appropriate page."}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-light-bulb"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"The redirect URL must be configured in your Supabase dashboard under "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"Authentication -> URL Configuration -> Redirect URLs"}]},{"type":"text","value":"."}]}]},{"type":"element","tag":"pre","props":{"className":"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"\n\n\n","filename":"pages/confirm.vue","language":"vue","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"script"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" setup"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" lang"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"ts"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" user "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseUser"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"watch"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"(user"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" if"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"user"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":") "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" // Redirect to protected page\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" navigateTo"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":8},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":9},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"},"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" immediate"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC"},"children":[{"type":"text","value":" true"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":10},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":11},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":12},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"template"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":13},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" <"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"div"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"Waiting for login..."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":14},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]}]}]},{"type":"element","tag":"h3","props":{"id":"redirect-path"},"children":[{"type":"text","value":"Redirect path"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"You can easily handle redirection to the initial requested route after login."}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-light-bulb"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"You must enable the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"cookieRedirect"}]},{"type":"text","value":" option of the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirectoptions"},"children":[{"type":"text","value":"redirectOptions"}]},{"type":"text","value":" to allow cookie storage and take benefit of this feature."}]}]},{"type":"element","tag":"pre","props":{"className":"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"\n\n","filename":"pages/confirm.vue","language":"vue","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"script"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" setup"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" lang"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"ts"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" user "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseUser"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"// Get redirect path from cookies\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" cookieName "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useRuntimeConfig"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"public"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"cookieName\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" redirectPath "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useCookie"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"`${"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"cookieName"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"-redirect-path"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"`"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":8},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"watch"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"(user"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":9},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" if"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"user"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":") "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":10},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" // Clear cookie\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":11},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useCookie"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"`${"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"cookieName"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"-redirect-path"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"`"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" null\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":12},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" // Redirect to path\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":13},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" navigateTo"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"redirectPath"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ||"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":";"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" \n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":14},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":15},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"},"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" immediate"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC"},"children":[{"type":"text","value":" true"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":16},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":17},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"template"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":18},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" <"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"div"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"Waiting for login..."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":19},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]}]}]},{"type":"element","tag":"style","props":{},"children":[{"type":"text","value":"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}"}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[{"id":"log-in-page-login","depth":2,"text":"Log-in page - /login"},{"id":"confirm-page-confirm","depth":2,"text":"Confirm page - /confirm","children":[{"id":"redirect-path","depth":3,"text":"Redirect path"}]}]}},"_type":"markdown","_id":"content:3.authentication.md","_source":"content","_file":"3.authentication.md","_stem":"3.authentication","_extension":"md"},{"_path":"/usage/_dir","_dir":"usage","_draft":false,"_partial":true,"_locale":"","title":"Usage","icon":"heroicons:book-open","_id":"content:4.usage:_dir.yml","_type":"yaml","_source":"content","_file":"4.usage/_dir.yml","_stem":"4.usage/_dir","_extension":"yml"},{"_path":"/usage/composables/_dir","_dir":"composables","_draft":false,"_partial":true,"_locale":"","title":"Vue composables","_id":"content:4.usage:composables:_dir.yml","_type":"yaml","_source":"content","_file":"4.usage/composables/_dir.yml","_stem":"4.usage/composables/_dir","_extension":"yml"},{"_path":"/usage/composables/usesupabaseclient","_dir":"composables","_draft":false,"_partial":false,"_locale":"","title":"useSupabaseClient","description":"Make requests to the Supabase API with the useSupabaseClient composable","body":{"type":"root","children":[{"type":"element","tag":"p","props":{},"children":[{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/composables","rel":["nofollow"]},"children":[{"type":"text","value":"Auto-import"}]},{"type":"text","value":" your client inside your vue files."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"This composable is using "},{"type":"element","tag":"a","props":{"href":"https://github.com/supabase/supabase-js/","rel":["nofollow"]},"children":[{"type":"text","value":"supabase-js"}]},{"type":"text","value":" under the hood, it gives access to the "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/reference/javascript/initializing","rel":["nofollow"]},"children":[{"type":"text","value":"Supabase client"}]},{"type":"text","value":"."}]},{"type":"element","tag":"blockquote","props":{},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"The client is initialized with the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"SUPABASE_KEY"}]},{"type":"text","value":" you must have in your "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":".env"}]},{"type":"text","value":" file. It establishes the connection with the database and make use of user JWT to apply "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/learn/auth-deep-dive/auth-row-level-security","rel":["nofollow"]},"children":[{"type":"text","value":"RLS Policies"}]},{"type":"text","value":" implemented in Supabase. If you want to bypass policies, you can use the "},{"type":"element","tag":"a","props":{"href":"/usage/services/serversupabaseservicerole"},"children":[{"type":"text","value":"serverSupabaseServiceRole"}]},{"type":"text","value":"."}]}]},{"type":"element","tag":"h2","props":{"id":"authentication"},"children":[{"type":"text","value":"Authentication"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"The useSupabaseClient composable is providing all methods to manage authorization under "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"useSupabaseClient().auth"}]},{"type":"text","value":". For more details please see the "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/reference/javascript/auth-api","rel":["nofollow"]},"children":[{"type":"text","value":"supabase-js auth documentation"}]},{"type":"text","value":". Here is an example for signing in and out:"}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-light-bulb"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"If you want a full explanation on how to handle the authentication process, please read this "},{"type":"element","tag":"a","props":{"href":"/get-started#handle-authentication"},"children":[{"type":"text","value":"section"}]},{"type":"text","value":"."}]}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"\n","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"script setup lang"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"ts"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" supabase "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseClient"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" signInWithOAuth "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" error"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"auth"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"signInWithOAuth"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" provider"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"github"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" options"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":8},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" redirectTo"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"http://localhost:3000/confirm"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":9},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" },\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":10},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":11},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" if"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"error"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":") "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"console"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"log"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"error"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":12},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":13},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":14},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" signOut "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":15},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" error"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"auth"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"signOut"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":16},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" if"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"error"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":") "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"console"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"log"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"error"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":17},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":18},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Please also take a look at "},{"type":"element","tag":"a","props":{"href":"/get-started"},"children":[{"type":"text","value":"Get Started"}]},{"type":"text","value":" for the authorization flow."}]},{"type":"element","tag":"h2","props":{"id":"database-request"},"children":[{"type":"text","value":"Database Request"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Please check "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/reference/javascript/select","rel":["nofollow"]},"children":[{"type":"text","value":"Supabase"}]},{"type":"text","value":" documentation to fully use the power of Supabase client."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Here is an example of a fetch using the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"select"}]},{"type":"text","value":" method with Nuxt 3 "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/getting-started/data-fetching#useasyncdata","rel":["nofollow"]},"children":[{"type":"text","value":"useAsyncData"}]},{"type":"text","value":" composable."}]},{"type":"element","tag":"pre","props":{"className":"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"\n","language":"vue","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"script"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" setup"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" lang"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"ts"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseClient"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" data"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" restaurant "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useAsyncData"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"restaurant"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"restaurants"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"select"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"name, location"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"eq"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"name"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"My Restaurant Name"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"single"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":8},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":9},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]}]}]},{"type":"element","tag":"h2","props":{"id":"realtime"},"children":[{"type":"text","value":"Realtime"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Based on "},{"type":"element","tag":"a","props":{"href":"https://github.com/supabase/realtime","rel":["nofollow"]},"children":[{"type":"text","value":"Supabase Realtime"}]},{"type":"text","value":", listen to changes in your PostgreSQL Database and broadcasts them over WebSockets."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"To enable it, make sure you have turned on the "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/guides/api#realtime-api","rel":["nofollow"]},"children":[{"type":"text","value":"Realtime API"}]},{"type":"text","value":" for your table."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Then, listen to changes directly in your vue page / component:"}]},{"type":"element","tag":"pre","props":{"className":"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"\n","language":"vue","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"script"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" setup"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" lang"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"ts"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"import"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" type"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" RealtimeChannel"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"@supabase/supabase-js"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseClient"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"let"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" realtimeChannel"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" RealtimeChannel\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":8},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"// Fetch collaborators and get the refresh method provided by useAsyncData\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":9},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" data"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" collaborators"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" refresh"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" refreshCollaborators "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useAsyncData"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"collaborators"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":10},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"collaborators"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"select"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"name"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":11},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":12},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":13},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":14},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"// Once page is mounted, listen to changes on the `collaborators` table and refresh collaborators when receiving event\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":15},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"onMounted"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":16},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" // Real time listener for new workouts\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":17},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" realtimeChannel"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"channel"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"public:collaborators"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"on"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"(\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":18},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"postgres_changes"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":19},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" event"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"*"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" schema"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"public"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" table"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"collaborators"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" },\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":20},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" refreshCollaborators"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":21},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" )\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":22},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":23},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" realtimeChannel"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"subscribe"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":24},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":25},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":26},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" // Don't forget to unsubscribe when user left the page\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":27},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"onUnmounted"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":28},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"removeChannel"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"realtimeChannel"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":29},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":30},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]}]}]},{"type":"element","tag":"h2","props":{"id":"typescript"},"children":[{"type":"text","value":"Typescript"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Database typings are passed to the client out of the box if the database generated types are found at "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"./types/database.types.ts"}]},{"type":"text","value":" or "},{"type":"element","tag":"a","props":{"href":"/get-started#types"},"children":[{"type":"text","value":"your configured types path"}]},{"type":"text","value":". Check Supabase "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/reference/javascript/release-notes#typescript-support","rel":["nofollow"]},"children":[{"type":"text","value":"documentation"}]},{"type":"text","value":" for further information."}]},{"type":"element","tag":"pre","props":{"className":"language-shell shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"## Generate types from live database\nsupabase gen types typescript --project-id YourProjectId > types/database.types.ts\n\n## Generate types when using local environment\nsupabase gen types typescript --local > types/database.types.ts\n","language":"shell","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"## Generate types from live database\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":"supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" gen"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" types"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" typescript"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" --project-id"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" YourProjectId"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" >"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" types/database.types.ts\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"## Generate types when using local environment\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":"supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" gen"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" types"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" typescript"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" --local"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" >"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" types/database.types.ts\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"You can also pass Database typings to the client manually:"}]},{"type":"element","tag":"pre","props":{"className":"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"\n","language":"vue","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"script"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" setup"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" lang"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"ts"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"import"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" type"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" Database"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"~/types"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseClient"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":"Database"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]}]}]},{"type":"element","tag":"style","props":{},"children":[{"type":"text","value":"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}"}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[{"id":"authentication","depth":2,"text":"Authentication"},{"id":"database-request","depth":2,"text":"Database Request"},{"id":"realtime","depth":2,"text":"Realtime"},{"id":"typescript","depth":2,"text":"Typescript"}]}},"_type":"markdown","_id":"content:4.usage:composables:useSupabaseClient.md","_source":"content","_file":"4.usage/composables/useSupabaseClient.md","_stem":"4.usage/composables/useSupabaseClient","_extension":"md"},{"_path":"/usage/composables/usesupabasesession","_dir":"composables","_draft":false,"_partial":false,"_locale":"","title":"useSupabaseSession","description":"Auto import and use your Supabase user's session with the useSupabaseSession composable","body":{"type":"root","children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Once logged in, you can "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/composables","rel":["nofollow"]},"children":[{"type":"text","value":"auto-import"}]},{"type":"text","value":" your user's session everywhere inside your vue files."}]},{"type":"element","tag":"pre","props":{"className":"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"\n","language":"vue","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"script"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" setup"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" session "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseSession"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]}]}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-light-bulb"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"If you just need the User's information you can use "},{"type":"element","tag":"a","props":{"href":"/usage/composables/usesupabaseuser"},"children":[{"type":"text","value":"useSupabaseUser"}]},{"type":"text","value":" which returns just the User information of the session."}]}]},{"type":"element","tag":"h2","props":{"id":"auth-middleware"},"children":[{"type":"text","value":"Auth middleware"}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-light-bulb"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"By default, the module is implementing a redirect middleware. All pages of your application are automatically redirected to the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirectoptions"},"children":[{"type":"text","value":"login"}]},{"type":"text","value":" page. However, you can allow redirection to \"public\" pages by setting the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirectoptions"},"children":[{"type":"text","value":"exclude"}]},{"type":"text","value":" redirect option. Alternatively, you can enable the redirect only for certain routes using the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirectoptions"},"children":[{"type":"text","value":"include"}]},{"type":"text","value":" redirect option."}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"If the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirect"},"children":[{"type":"text","value":"redirect"}]},{"type":"text","value":" option is disabled, you can protect your authenticated routes by creating a custom middleware in your project, here is an example:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"export default defineNuxtRouteMiddleware((to, _from) => {\n const session = useSupabaseSession()\n\n if (!session.value) {\n return navigateTo('/login')\n }\n})\n","filename":"middleware/auth.ts","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"export"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" default"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" defineNuxtRouteMiddleware"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"to"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" _from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" session"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseSession"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" if"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"!"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"session"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":") "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" navigateTo"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/login"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Then you can reference your middleware in your page with:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"definePageMeta({\n middleware: 'auth'\n})\n","filename":"pages/dashboard.vue","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"definePageMeta"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" middleware"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"auth"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Learn more about "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/middleware","rel":["nofollow"]},"children":[{"type":"text","value":"Nuxt middleware"}]},{"type":"text","value":" and "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/pages#page-metadata","rel":["nofollow"]},"children":[{"type":"text","value":"definePageMeta"}]},{"type":"text","value":"."}]},{"type":"element","tag":"style","props":{},"children":[{"type":"text","value":"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}"}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[{"id":"auth-middleware","depth":2,"text":"Auth middleware"}]}},"_type":"markdown","_id":"content:4.usage:composables:useSupabaseSession.md","_source":"content","_file":"4.usage/composables/useSupabaseSession.md","_stem":"4.usage/composables/useSupabaseSession","_extension":"md"},{"_path":"/usage/composables/usesupabaseuser","_dir":"composables","_draft":false,"_partial":false,"_locale":"","title":"useSupabaseUser","description":"Auto import and use your Supabase user with the useSupabaseUser composable","body":{"type":"root","children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Once logged in, you can "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/composables","rel":["nofollow"]},"children":[{"type":"text","value":"auto-import"}]},{"type":"text","value":" your user everywhere inside your vue files."}]},{"type":"element","tag":"pre","props":{"className":"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"\n","language":"vue","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"script"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" setup"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" user "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseUser"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]}]}]},{"type":"element","tag":"h2","props":{"id":"auth-middleware"},"children":[{"type":"text","value":"Auth middleware"}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-light-bulb"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"By default, the module is implementing a redirect middleware. All pages of your application are automatically redirected to the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirectoptions"},"children":[{"type":"text","value":"login"}]},{"type":"text","value":" page. However, you can allow redirection to \"public\" pages by setting the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirectoptions"},"children":[{"type":"text","value":"exclude"}]},{"type":"text","value":" redirect option. Alternatively, you can enable the redirect only for certain routes using the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirectoptions"},"children":[{"type":"text","value":"include"}]},{"type":"text","value":" redirect option."}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"If the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirect"},"children":[{"type":"text","value":"redirect"}]},{"type":"text","value":" option is disabled, you can protect your authenticated routes by creating a custom middleware in your project, here is an example:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"export default defineNuxtRouteMiddleware((to, _from) => {\n const user = useSupabaseUser()\n\n if (!user.value) {\n return navigateTo('/login')\n }\n})\n","filename":"middleware/auth.ts","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"export"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" default"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" defineNuxtRouteMiddleware"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"to"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" _from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" user"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseUser"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" if"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"!"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"user"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":") "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" navigateTo"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/login"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Then you can reference your middleware in your page with:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"definePageMeta({\n middleware: 'auth'\n})\n","filename":"pages/dashboard.vue","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"definePageMeta"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" middleware"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"auth"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Learn more about "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/middleware","rel":["nofollow"]},"children":[{"type":"text","value":"Nuxt middleware"}]},{"type":"text","value":" and "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/pages#page-metadata","rel":["nofollow"]},"children":[{"type":"text","value":"definePageMeta"}]},{"type":"text","value":"."}]},{"type":"element","tag":"style","props":{},"children":[{"type":"text","value":"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}"}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[{"id":"auth-middleware","depth":2,"text":"Auth middleware"}]}},"_type":"markdown","_id":"content:4.usage:composables:useSupabaseUser.md","_source":"content","_file":"4.usage/composables/useSupabaseUser.md","_stem":"4.usage/composables/useSupabaseUser","_extension":"md"},{"_path":"/usage/services/_dir","_dir":"services","_draft":false,"_partial":true,"_locale":"","title":"Server services","_id":"content:4.usage:services:_dir.yml","_type":"yaml","_source":"content","_file":"4.usage/services/_dir.yml","_stem":"4.usage/services/_dir","_extension":"yml"},{"_path":"/usage/services/serversupabaseclient","_dir":"services","_draft":false,"_partial":false,"_locale":"","title":"serverSupabaseClient","description":"Make requests to the Supabase API on server side with the serverSupabaseClient service","body":{"type":"root","children":[{"type":"element","tag":"callout","props":{"color":"amber","icon":"i-heroicons-exclamation-triangle-20-solid"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"This section assumes you're familiar with "},{"type":"element","tag":"a","props":{"href":"https://v3.nuxtjs.org/guide/concepts/server-engine","rel":["nofollow"]},"children":[{"type":"text","value":"Nitro"}]},{"type":"text","value":", the server engine powered by Nuxt."}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"This function is working similary as the "},{"type":"element","tag":"a","props":{"href":"/usage/composables/usesupabaseclient"},"children":[{"type":"text","value":"useSupabaseClient"}]},{"type":"text","value":" composable but is designed to be used in "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/server#server-routes","rel":["nofollow"]},"children":[{"type":"text","value":"server routes"}]},{"type":"text","value":"."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Define your server route and just import the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"serverSupabaseClient"}]},{"type":"text","value":" from "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"#supabase/server"}]},{"type":"text","value":". Be careful, "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"serverSupabaseClient"}]},{"type":"text","value":" is returning a promise."}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"import { serverSupabaseClient } from '#supabase/server'\n\nexport default eventHandler(async (event) => {\n const client = await serverSupabaseClient(event)\n\n const { data } = await client.from('libraries').select('*')\n\n return { libraries: data }\n})\n","filename":"server/api/libraries.ts","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"import"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" serverSupabaseClient"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"#supabase/server"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"export"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" default"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" eventHandler"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"event"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" serverSupabaseClient"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"event"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"libraries"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"select"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"*"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":8},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" libraries"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":9},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Then call your API route from any vue file:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"const fetchLibrary = async () => {\n const { libraries } = await $fetch('/api/libraries')\n}\n","filename":"pages/index.vue","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" fetchLibrary "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" libraries"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" $fetch"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/api/libraries"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Be careful, if you want to call this route on SSR, please read this "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/getting-started/data-fetching#isomorphic-fetch-and-fetch","rel":["nofollow"]},"children":[{"type":"text","value":"section"}]},{"type":"text","value":", you must send your browser cookies including your supabase token."}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"const { data: { libraries }} = await useFetch('/api/libraries', {\n headers: useRequestHeaders(['cookie'])\n})\n","filename":"pages/index.vue","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" data"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" libraries "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useFetch"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/api/libraries"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" headers"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useRequestHeaders"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"(["}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"cookie"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"])\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"style","props":{},"children":[{"type":"text","value":"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}"}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[]}},"_type":"markdown","_id":"content:4.usage:services:1.serverSupabaseClient.md","_source":"content","_file":"4.usage/services/1.serverSupabaseClient.md","_stem":"4.usage/services/1.serverSupabaseClient","_extension":"md"},{"_path":"/usage/services/serversupabaseservicerole","_dir":"services","_draft":false,"_partial":false,"_locale":"","title":"serverServiceRole","description":"Make requests with super admin rights to the Supabase API with the serverSupabaseServiceRole service","navigation":{"title":"serverSupabaseServiceRole"},"body":{"type":"root","children":[{"type":"element","tag":"callout","props":{"color":"amber","icon":"i-heroicons-exclamation-triangle-20-solid"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"This section assumes you're familiar with "},{"type":"element","tag":"a","props":{"href":"https://v3.nuxtjs.org/guide/concepts/server-engine","rel":["nofollow"]},"children":[{"type":"text","value":"Nitro"}]},{"type":"text","value":", the server engine powered by Nuxt."}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"This function is designed to work only in "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/server#server-routes","rel":["nofollow"]},"children":[{"type":"text","value":"server routes"}]},{"type":"text","value":", there is no vue composable equivalent."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"It works similary as the "},{"type":"element","tag":"a","props":{"href":"/usage/services/serversupabaseclient"},"children":[{"type":"text","value":"serverSupabaseClient"}]},{"type":"text","value":" but it provides a client with super admin rights that can bypass your "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/guides/auth/row-level-security","rel":["nofollow"]},"children":[{"type":"text","value":"Row Level Security"}]},{"type":"text","value":"."}]},{"type":"element","tag":"blockquote","props":{},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"The client is initialized with the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"SUPABASE_SERVICE_KEY"}]},{"type":"text","value":" you must have in your "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":".env"}]},{"type":"text","value":" file. Checkout the doc if you want to know more about "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/learn/auth-deep-dive/auth-deep-dive-jwts#jwts-in-supabase","rel":["nofollow"]},"children":[{"type":"text","value":"Supabase keys"}]},{"type":"text","value":"."}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Define your server route and just import the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"serverSupabaseServiceRole"}]},{"type":"text","value":" from "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"#supabase/server"}]},{"type":"text","value":"."}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"import { serverSupabaseServiceRole } from '#supabase/server'\n\nexport default eventHandler(async (event) => {\n const client = serverSupabaseServiceRole(event)\n\n const { data } = await client.from('rls-protected-table').select()\n\n return { sensitiveData: data }\n})\n","filename":"server/api/bypass-rls.ts","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"import"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" serverSupabaseServiceRole"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"#supabase/server"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"export"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" default"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" eventHandler"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"event"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" serverSupabaseServiceRole"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"event"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"rls-protected-table"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"select"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":8},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" sensitiveData"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":9},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Then call your API route from any vue file:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"const fetchSensitiveData = async () => {\n const { sensitiveData } = await useFetch('/api/bypass-rls')\n}\n","filename":"pages/index.vue","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" fetchSensitiveData "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" sensitiveData"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useFetch"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/api/bypass-rls"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}\n"}]}]}]}]},{"type":"element","tag":"style","props":{},"children":[{"type":"text","value":"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}"}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[]}},"_type":"markdown","_id":"content:4.usage:services:2.serverSupabaseServiceRole.md","_source":"content","_file":"4.usage/services/2.serverSupabaseServiceRole.md","_stem":"4.usage/services/2.serverSupabaseServiceRole","_extension":"md"},{"_path":"/usage/services/serversupabasesession","_dir":"services","_draft":false,"_partial":false,"_locale":"","title":"serverSupabaseSession","description":"Get your Supabase user's session from serverside with the serverSupabaseUser service","body":{"type":"root","children":[{"type":"element","tag":"callout","props":{"color":"amber","icon":"i-heroicons-exclamation-triangle-20-solid"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"This section assumes you're familiar with "},{"type":"element","tag":"a","props":{"href":"https://v3.nuxtjs.org/guide/concepts/server-engine","rel":["nofollow"]},"children":[{"type":"text","value":"Nitro"}]},{"type":"text","value":", the server engine powered by Nuxt."}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"This function is similar to the "},{"type":"element","tag":"a","props":{"href":"/usage/composables/usesupabasesession"},"children":[{"type":"text","value":"useSupabaseSession"}]},{"type":"text","value":" composable but is used in "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/server#server-routes","rel":["nofollow"]},"children":[{"type":"text","value":"server routes"}]},{"type":"text","value":"."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Define your server route and import the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"serverSupabaseSession"}]},{"type":"text","value":" from "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"#supabase/server"}]},{"type":"text","value":"."}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"import { serverSupabaseSession } from '#supabase/server'\n\nexport default defineEventHandler(async (event) => {\n return await serverSupabaseSession(event)\n})\n","filename":"server/api/session.ts","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"import"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" serverSupabaseSession"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"#supabase/server"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"export"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" default"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" defineEventHandler"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"event"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" serverSupabaseSession"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"event"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Then call your api route from any vue file:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"const session = ref(null)\n\nconst fetchSession = async () => {\n session.value = await $fetch('/api/session')\n}\n","filename":"pages/index.vue","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" session "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" ref"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"null"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" fetchSession "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" session"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" $fetch"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/api/session"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Be careful, if you want to call this route on SSR, please read this "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/getting-started/data-fetching#isomorphic-fetch-and-fetch","rel":["nofollow"]},"children":[{"type":"text","value":"section"}]},{"type":"text","value":", you must send your browser cookies including your supabase token."}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"const session = ref(null)\n\nconst { data } = await useFetch('/api/session', {\n headers: useRequestHeaders(['cookie'])\n})\n\nsession.value = data\n","filename":"pages/index.vue","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" session "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" ref"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"null"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useFetch"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/api/session"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" headers"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useRequestHeaders"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"(["}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"cookie"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"])\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"session"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data\n"}]}]}]}]},{"type":"element","tag":"style","props":{},"children":[{"type":"text","value":"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}"}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[]}},"_type":"markdown","_id":"content:4.usage:services:3.serverSupabaseSession.md","_source":"content","_file":"4.usage/services/3.serverSupabaseSession.md","_stem":"4.usage/services/3.serverSupabaseSession","_extension":"md"},{"_path":"/usage/services/serversupabaseuser","_dir":"services","_draft":false,"_partial":false,"_locale":"","title":"serverSupabaseUser","description":"Get your Supabase user from serverside with the serverSupabaseUser service","body":{"type":"root","children":[{"type":"element","tag":"callout","props":{"color":"amber","icon":"i-heroicons-exclamation-triangle-20-solid"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"This section assumes you're familiar with "},{"type":"element","tag":"a","props":{"href":"https://v3.nuxtjs.org/guide/concepts/server-engine","rel":["nofollow"]},"children":[{"type":"text","value":"Nitro"}]},{"type":"text","value":", the server engine powered by Nuxt."}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"This function is similar to the "},{"type":"element","tag":"a","props":{"href":"/usage/composables/usesupabaseuser"},"children":[{"type":"text","value":"useSupabaseUser"}]},{"type":"text","value":" composable but is used in "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/server#server-routes","rel":["nofollow"]},"children":[{"type":"text","value":"server routes"}]},{"type":"text","value":"."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Define your server route and import the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"serverSupabaseUser"}]},{"type":"text","value":" from "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"#supabase/server"}]},{"type":"text","value":"."}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"import { serverSupabaseUser } from '#supabase/server'\n\nexport default defineEventHandler(async (event) => {\n return await serverSupabaseUser(event)\n})\n","filename":"server/api/me.ts","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"import"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" serverSupabaseUser"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"#supabase/server"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"export"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" default"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" defineEventHandler"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"event"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" serverSupabaseUser"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"event"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Then call your api route from any vue file:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"const user = ref(null)\n\nconst fetchMe = async () => {\n user.value = await $fetch('/api/me')\n}\n","filename":"pages/index.vue","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" user "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" ref"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"null"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" fetchMe "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" user"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" $fetch"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/api/me"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Be careful, if you want to call this route on SSR, please read this "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/getting-started/data-fetching#isomorphic-fetch-and-fetch","rel":["nofollow"]},"children":[{"type":"text","value":"section"}]},{"type":"text","value":", you must send your browser cookies including your supabase token."}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"const user = ref(null)\n\nconst { data } = await useFetch('/api/me', {\n headers: useRequestHeaders(['cookie'])\n})\n\nuser.value = data\n","filename":"pages/index.vue","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" user "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" ref"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"null"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useFetch"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/api/me"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" headers"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useRequestHeaders"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"(["}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"cookie"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"])\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"user"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data\n"}]}]}]}]},{"type":"element","tag":"style","props":{},"children":[{"type":"text","value":"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}"}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[]}},"_type":"markdown","_id":"content:4.usage:services:4.serverSupabaseUser.md","_source":"content","_file":"4.usage/services/4.serverSupabaseUser.md","_stem":"4.usage/services/4.serverSupabaseUser","_extension":"md"},{"_path":"/demo","_dir":"","_draft":false,"_partial":false,"_locale":"","title":"Demo","description":"Demonstration of using Supabase with Nuxt.","icon":"i-heroicons-computer-desktop-20-solid","body":{"type":"root","children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Demonstration of using Supabase with Nuxt."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"element","tag":"a","props":{"href":"https://n3-supabase.netlify.app","rel":["nofollow"]},"children":[{"type":"element","tag":"img","props":{"alt":"Supabase demo with Nuxt 3","src":"https://user-images.githubusercontent.com/904724/160422461-8f87500a-8dec-4413-86b2-ba04e1b2d17b.png"},"children":[]}]}]},{"type":"element","tag":"h2","props":{"id":"live-demo"},"children":[{"type":"text","value":"Live demo"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"You can play with the demo on "},{"type":"element","tag":"a","props":{"href":"https://n3-supabase.netlify.app","rel":["nofollow"]},"children":[{"type":"text","value":"n3-supabase.netlify.app"}]}]},{"type":"element","tag":"h2","props":{"id":"running-locally"},"children":[{"type":"text","value":"Running locally"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Follow the instruction in the "},{"type":"element","tag":"a","props":{"href":"https://github.com/nuxt-community/supabase-module/tree/main/demo","rel":["nofollow"]},"children":[{"type":"text","value":"demo Readme"}]},{"type":"text","value":"."}]},{"type":"element","tag":"h2","props":{"id":"source-code"},"children":[{"type":"text","value":"Source code"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"The source code is available on Github in the "},{"type":"element","tag":"a","props":{"href":"https://github.com/nuxt-community/supabase-module/tree/main/demo","rel":["nofollow"]},"children":[{"type":"text","value":"demo/ directory"}]},{"type":"text","value":"."}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[{"id":"live-demo","depth":2,"text":"Live demo"},{"id":"running-locally","depth":2,"text":"Running locally"},{"id":"source-code","depth":2,"text":"Source code"}]}},"_type":"markdown","_id":"content:5.demo.md","_source":"content","_file":"5.demo.md","_stem":"5.demo","_extension":"md"},{"_path":"/changelog","_dir":"","_draft":false,"_partial":false,"_locale":"","title":"Changelog","description":"Discover the latest updates of the Supabase Module","icon":"i-heroicons-bookmark","body":{"type":"root","children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Discover the lastest updates."}]},{"type":"element","tag":"releases","props":{},"children":[]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[]}},"_type":"markdown","_id":"content:6.changelog.md","_source":"content","_file":"6.changelog.md","_stem":"6.changelog","_extension":"md"},{"_path":"/roadmap","_dir":"","_draft":false,"_partial":false,"_locale":"","title":"Roadmap","description":"Discover our kaban board for the next release of the Supabase module.","icon":"i-heroicons-map","body":{"type":"root","children":[{"type":"element","tag":"volta-board","props":{"token":"eyJzdGF0dXNlcyI6WyJ0cmlhZ2UiLCJiYWNrbG9nIiwidG9kbyIsImluX3Byb2dyZXNzIiwiaW5fcmV2aWV3IiwiZG9uZSIsInJlbGVhc2VkIiwiY2FuY2VsbGVkIl0sImZpbHRlcnMiOnt9LCJvd25lciI6Im51eHQtbW9kdWxlcyIsIm5hbWUiOiJzdXBhYmFzZSJ9"},"children":[]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[]}},"_type":"markdown","_id":"content:7.roadmap.md","_source":"content","_file":"7.roadmap.md","_stem":"7.roadmap","_extension":"md"},{"_path":"/","_dir":"","_draft":false,"_partial":false,"_locale":"","title":"Nuxt Supabase - Home","description":"A supa simple wrapper around supabase-js to enable usage and integration within Nuxt.","navigation":false,"hero":{"title":"Nuxt [Supabase]{.text-primary}","description":"A supa simple wrapper around supabase-js to enable usage and integration within Nuxt.","orientation":"horizontal","links":[{"label":"Get started","icon":"i-heroicons-rocket-launch","to":"/get-started","size":"lg"},{"label":"Star on github","icon":"i-heroicons-star","color":"white","to":"https://github.com/nuxt-modules/supabase","target":"_blank","size":"lg"}],"code":"```ts\n const supabase = useSupabaseClient()\n const email = ref('')\n\n const signInWithOtp = async () => {\n await supabase.auth.signInWithOtp({\n email: email.value,\n })\n }\n```\n"},"features":{"title":"Shipped with many features","items":[{"title":"Nuxt 3 ready","icon":"i-simple-icons-nuxtdotjs","to":"https://nuxt.com","target":"_blank"},{"title":"Vue 3 composables","icon":"i-simple-icons-vuedotjs","to":"https://vuejs.org/guide/reusability/composables.html","target":"_blank"},{"title":"Supabase-js V2","icon":"i-simple-icons-supabase","to":"https://supabase.com","target":"_blank"},{"title":"Usage in API server routes","icon":"i-heroicons-server","to":"usage/services/serversupabaseclient"},{"title":"Authentication support","icon":"i-heroicons-key","to":"/authentication"},{"title":"TypeScript support","icon":"i-simple-icons-typescript","to":"https://www.typescriptlang.org","target":"_blank"}]},"_id":"content:index.yml","_type":"yaml","_source":"content","_file":"index.yml","_stem":"index","_extension":"yml"}],"navigation":[{"title":"Get Started","_path":"/get-started","icon":"i-heroicons-rocket-launch"},{"title":"Authentication","_path":"/authentication","icon":"i-heroicons-lock-closed"},{"title":"Usage","_path":"/usage","children":[{"title":"Vue composables","_path":"/usage/composables","children":[{"title":"useSupabaseClient","_path":"/usage/composables/usesupabaseclient"},{"title":"useSupabaseSession","_path":"/usage/composables/usesupabasesession"},{"title":"useSupabaseUser","_path":"/usage/composables/usesupabaseuser"}]},{"title":"Server services","_path":"/usage/services","children":[{"title":"serverSupabaseClient","_path":"/usage/services/serversupabaseclient"},{"title":"serverSupabaseServiceRole","_path":"/usage/services/serversupabaseservicerole"},{"title":"serverSupabaseSession","_path":"/usage/services/serversupabasesession"},{"title":"serverSupabaseUser","_path":"/usage/services/serversupabaseuser"}]}],"icon":"heroicons:book-open"},{"title":"Demo","_path":"/demo","icon":"i-heroicons-computer-desktop-20-solid"},{"title":"Changelog","_path":"/changelog","icon":"i-heroicons-bookmark"},{"title":"Roadmap","_path":"/roadmap","icon":"i-heroicons-map"}]} \ No newline at end of file +{"generatedAt":1724942521892,"generateTime":4533,"contents":[{"_path":"/get-started","_dir":"","_draft":false,"_partial":false,"_locale":"","title":"Get Started","description":"@nuxtjs/supabase is a Nuxt module for first class integration with Supabase.","icon":"i-heroicons-rocket-launch","body":{"type":"root","children":[{"type":"element","tag":"p","props":{},"children":[{"type":"element","tag":"a","props":{"href":"https://github.com/nuxt-modules/supabase","rel":["nofollow"]},"children":[{"type":"text","value":"@nuxtjs/supabase"}]},{"type":"text","value":" is a Nuxt module for first class integration with Supabase."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Checkout the "},{"type":"element","tag":"a","props":{"href":"https://v3.nuxtjs.org","rel":["nofollow"]},"children":[{"type":"text","value":"Nuxt 3"}]},{"type":"text","value":" documentation and "},{"type":"element","tag":"a","props":{"href":"https://supabase.com","rel":["nofollow"]},"children":[{"type":"text","value":"Supabase"}]},{"type":"text","value":" to learn more."}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-exclamation-triangle-20-solid","color":"amber"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"For integrating Supabase with Nuxt 2, checkout "},{"type":"element","tag":"a","props":{"href":"https://github.com/supabase-community/nuxt-supabase","rel":["nofollow"]},"children":[{"type":"text","value":"supabase-community/nuxt-supabase"}]},{"type":"text","value":"."}]}]},{"type":"element","tag":"h2","props":{"id":"installation"},"children":[{"type":"text","value":"Installation"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Add "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"@nuxtjs/supabase"}]},{"type":"text","value":" dev dependency to your project:"}]},{"type":"element","tag":"pre","props":{"className":"language-bash shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"npx nuxi@latest module add supabase\n","language":"bash","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":"npx"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" nuxi@latest"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" module"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" add"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" supabase\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Add "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"@nuxtjs/supabase"}]},{"type":"text","value":" to the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"modules"}]},{"type":"text","value":" section of "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"nuxt.config.ts"}]},{"type":"text","value":":"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"export default defineNuxtConfig({\n modules: ['@nuxtjs/supabase'],\n})\n","filename":"nuxt.config.ts","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"export"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" default"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" defineNuxtConfig"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" modules"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" ["}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"@nuxtjs/supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"]"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Add "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"SUPABASE_URL"}]},{"type":"text","value":" and "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"SUPABASE_KEY"}]},{"type":"text","value":" to the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":".env"}]},{"type":"text","value":":"}]},{"type":"element","tag":"pre","props":{"className":"language-bash shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"SUPABASE_URL=\"https://example.supabase.co\"\nSUPABASE_KEY=\"\"\n","filename":"env","language":"bash","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"SUPABASE_URL"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"https://example.supabase.co"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"SUPABASE_KEY"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\"\n"}]}]}]}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-light-bulb"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Alternatively, you can prefix the env variables with "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"NUXT_PUBLIC_"}]},{"type":"text","value":" in order to use runtimeConfig."}]}]},{"type":"element","tag":"h2","props":{"id":"options"},"children":[{"type":"text","value":"Options"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"You can configure the supabase module by using the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"supabase"}]},{"type":"text","value":" key in "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"nuxt.config"}]},{"type":"text","value":":"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"export default defineNuxtConfig({\n // ...\n supabase: {\n // Options\n }\n}\n","filename":"nuxt.config.ts","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"export"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" default"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" defineNuxtConfig"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" // ...\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" // Options\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}\n"}]}]}]}]},{"type":"element","tag":"h3","props":{"id":"url"},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"url"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Default: "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"process.env.SUPABASE_URL"}]},{"type":"text","value":" (ex: "},{"type":"element","tag":"a","props":{"href":"https://example.supabase.co","rel":["nofollow"]},"children":[{"type":"text","value":"https://example.supabase.co"}]},{"type":"text","value":")"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"The unique Supabase URL which is supplied when you create a new project in your project dashboard."}]},{"type":"element","tag":"h3","props":{"id":"key"},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"key"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Default: "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"process.env.SUPABASE_KEY"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Supabase 'anon key', used to bypass the Supabase API gateway and interact with your Supabase database making use of user JWT to apply RLS Policies."}]},{"type":"element","tag":"h3","props":{"id":"servicekey"},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"serviceKey"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Default: "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"process.env.SUPABASE_SERVICE_KEY"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Supabase 'service role key', has super admin rights and can bypass your Row Level Security."}]},{"type":"element","tag":"h3","props":{"id":"redirect"},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"redirect"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Default: "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"true"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Redirect automatically to the configured login page if a non authenticated user is trying to access a guarded. You can disable all redirects by setting this option to false."}]},{"type":"element","tag":"h3","props":{"id":"redirectoptions"},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"redirectOptions"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Default:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":" redirectOptions: {\n login: '/login',\n callback: '/confirm',\n include: undefined,\n exclude: [],\n cookieRedirect: false,\n }\n","filename":"nuxt.config.ts","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" redirectOptions"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" login"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/login"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" callback"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/confirm"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" include"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" undefined,\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" exclude"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" []"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" cookieRedirect"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC"},"children":[{"type":"text","value":" false"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]}]}]},{"type":"element","tag":"ul","props":{},"children":[{"type":"element","tag":"li","props":{},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"login"}]},{"type":"text","value":": User will be redirected to this path if not authenticated or after logout."}]},{"type":"element","tag":"li","props":{},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"callback"}]},{"type":"text","value":": This is the path the user will be redirect to after supabase login redirection. Should match configured "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"redirectTo"}]},{"type":"text","value":" option of your "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/reference/javascript/auth-signinwithoauth","rel":["nofollow"]},"children":[{"type":"text","value":"signIn method"}]},{"type":"text","value":". Should also be configured in your Supabase dashboard under "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"Authentication -> URL Configuration -> Redirect URLs"}]},{"type":"text","value":"."}]},{"type":"element","tag":"li","props":{},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"include"}]},{"type":"text","value":": Routes to include in the redirect. "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"['/admin(/*)?']"}]},{"type":"text","value":" will enable the redirect only for the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"admin"}]},{"type":"text","value":" page and all sub-pages."}]},{"type":"element","tag":"li","props":{},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"exclude"}]},{"type":"text","value":": Routes to exclude from the redirect. "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"['/foo', '/bar/*']"}]},{"type":"text","value":" will exclude the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"foo"}]},{"type":"text","value":" page and all pages in your "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"bar"}]},{"type":"text","value":" folder."}]},{"type":"element","tag":"li","props":{},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"cookieRedirect"}]},{"type":"text","value":": Sets a cookie containing the path an unauthenticated user tried to access. The cookie can then be used on the "},{"type":"element","tag":"a","props":{"href":"https://supabase.nuxtjs.org/authentication#confirm-page-confirm","rel":["nofollow"]},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"/confirm"}]}]},{"type":"text","value":" page to redirect the user to the page they previously tried to visit."}]}]},{"type":"element","tag":"h3","props":{"id":"cookiename"},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"cookieName"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Default: "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"sb"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Cookie name used for storing the redirect path when using the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"redirect"}]},{"type":"text","value":" option, added in front of "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"-redirect-path"}]},{"type":"text","value":" to form the full cookie name e.g. "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"sb-redirect-path"}]}]},{"type":"element","tag":"h3","props":{"id":"cookieoptions"},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"cookieOptions"}]}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":" cookieOptions: {\n maxAge: 60 * 60 * 8,\n sameSite: 'lax',\n secure: true\n }\n","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" cookieOptions"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" maxAge"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C"},"children":[{"type":"text","value":" 60"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" *"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C"},"children":[{"type":"text","value":" 60"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" *"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C"},"children":[{"type":"text","value":" 8"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" sameSite"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"lax"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" secure"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC"},"children":[{"type":"text","value":" true\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Options for cookies used to share tokens between server and client, refer to "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/api/composables/use-cookie#options","rel":["nofollow"]},"children":[{"type":"text","value":"cookieOptions"}]},{"type":"text","value":" for available settings. Please note that the lifetime set here does not determine the Supabase session lifetime."}]},{"type":"element","tag":"h3","props":{"id":"types"},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"types"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Default: "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"./types/database.types.ts"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"The path for the generated Supabase TypeScript definitions. The database definitions will be automatically passed to all clients: "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"useSupabaseClient"}]},{"type":"text","value":", "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"serverSupabaseClient"}]},{"type":"text","value":" and "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"serverSupabaseServiceRole"}]},{"type":"text","value":"."}]},{"type":"element","tag":"pre","props":{"className":"language-bash shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"## Generate types from live database\nsupabase gen types --lang=typescript --project-id YourProjectId > types/database.types.ts\n\n## Generate types when using local environment\nsupabase gen types --lang=typescript --local > types/database.types.ts\n","language":"bash","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"## Generate types from live database\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":"supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" gen"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" types"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" --lang=typescript"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" --project-id"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" YourProjectId"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" >"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" types/database.types.ts\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"## Generate types when using local environment\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":"supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" gen"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" types"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" --lang=typescript"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" --local"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" >"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" types/database.types.ts\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Set to "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"false"}]},{"type":"text","value":" to disable."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Check Supabase "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/reference/javascript/release-notes#typescript-support","rel":["nofollow"]},"children":[{"type":"text","value":"documentation"}]},{"type":"text","value":" for further information."}]},{"type":"element","tag":"h3","props":{"id":"clientoptions"},"children":[{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"clientOptions"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Default:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":" clientOptions: { }\n","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" clientOptions"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Supabase client options "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/reference/javascript/initializing#parameters","rel":["nofollow"]},"children":[{"type":"text","value":"available here"}]},{"type":"text","value":" merged with default values from "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"@supabase/ssr"}]},{"type":"text","value":":"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":" clientOptions: {\n auth: {\n flowType: 'pkce',\n autoRefreshToken: isBrowser(),\n detectSessionInUrl: isBrowser(),\n persistSession: true,\n },\n }\n","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" clientOptions"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" auth"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" flowType"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"pkce"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" autoRefreshToken"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" isBrowser"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" detectSessionInUrl"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" isBrowser"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" persistSession"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC"},"children":[{"type":"text","value":" true"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" },\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":8},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]}]}]},{"type":"element","tag":"h2","props":{"id":"demo"},"children":[{"type":"text","value":"Demo"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"A live demo is made for see this module in action on "},{"type":"element","tag":"a","props":{"href":"https://n3-supabase.netlify.app","rel":["nofollow"]},"children":[{"type":"text","value":"n3-supabase.netlify.app"}]},{"type":"text","value":", read more in the "},{"type":"element","tag":"a","props":{"href":"/demo"},"children":[{"type":"text","value":"demo section"}]},{"type":"text","value":"."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"element","tag":"a","props":{"href":"https://n3-supabase.netlify.app","rel":["nofollow"]},"children":[{"type":"element","tag":"img","props":{"alt":"Supabase demo with Nuxt 3","src":"https://user-images.githubusercontent.com/904724/160422461-8f87500a-8dec-4413-86b2-ba04e1b2d17b.png"},"children":[]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Also checkout the "},{"type":"element","tag":"a","props":{"href":"https://www.youtube.com/watch?v=jIyiRT6zT8Q","rel":["nofollow"]},"children":[{"type":"text","value":"YouTube video"}]},{"type":"text","value":" about its usage in a live demo."}]},{"type":"element","tag":"style","props":{},"children":[{"type":"text","value":"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}"}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[{"id":"installation","depth":2,"text":"Installation"},{"id":"options","depth":2,"text":"Options","children":[{"id":"url","depth":3,"text":"url"},{"id":"key","depth":3,"text":"key"},{"id":"servicekey","depth":3,"text":"serviceKey"},{"id":"redirect","depth":3,"text":"redirect"},{"id":"redirectoptions","depth":3,"text":"redirectOptions"},{"id":"cookiename","depth":3,"text":"cookieName"},{"id":"cookieoptions","depth":3,"text":"cookieOptions"},{"id":"types","depth":3,"text":"types"},{"id":"clientoptions","depth":3,"text":"clientOptions"}]},{"id":"demo","depth":2,"text":"Demo"}]}},"_type":"markdown","_id":"content:2.get-started.md","_source":"content","_file":"2.get-started.md","_stem":"2.get-started","_extension":"md"},{"_path":"/authentication","_dir":"","_draft":false,"_partial":false,"_locale":"","title":"Authentication","description":"Authenticate your user thanks to the PKCE Oauth protocol that enables secure exchange of refresh and access tokens between an application and the authorization server","icon":"i-heroicons-lock-closed","body":{"type":"root","children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"With the default options, the module requires a log-in page and a confirm page to handle the "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/guides/resources/glossary#pkce","rel":["nofollow"]},"children":[{"type":"text","value":"PKCE authorization code flow"}]},{"type":"text","value":". If you want to understand how it works under the hood, you can read this "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/guides/auth/server-side-rendering#understanding-the-authentication-flow","rel":["nofollow"]},"children":[{"type":"text","value":"section"}]},{"type":"text","value":"."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"All you need to do is to create a "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"login.vue"}]},{"type":"text","value":" and "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"confirm.vue"}]},{"type":"text","value":" page in the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"pages"}]},{"type":"text","value":" folder."}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-light-bulb"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"For advanced users who want to implement the auth behaviour themselves, you can disable or override the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirect"},"children":[{"type":"text","value":"redirect options"}]},{"type":"text","value":"."}]}]},{"type":"element","tag":"h2","props":{"id":"log-in-page-login"},"children":[{"type":"text","value":"Log-in page - "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"/login"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Each time a user is trying to access a page that needs authentication, he will automatically be redirected to the configured log in page. If you want to allow access to \"public\" page, you just need to add them in the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirectoptions"},"children":[{"type":"text","value":"exclude"}]},{"type":"text","value":" redirect option. Alternatively, you can enable the redirect only for certain routes using the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirectoptions"},"children":[{"type":"text","value":"include"}]},{"type":"text","value":" redirect option."}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-exclamation-triangle-20-solid","color":"amber"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Ensure to activate the authentication providers you want in the Supabase Dashboard under "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"Authentication -> Providers"}]},{"type":"text","value":"."}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"The log-in page initiates the log-in method(s) you choose from the "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/reference/javascript/auth-signinwithpassword","rel":["nofollow"]},"children":[{"type":"text","value":"available authorization methods"}]},{"type":"text","value":" provided by Supabase, it could looks like:"}]},{"type":"element","tag":"pre","props":{"className":"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"\n\n","filename":"pages/login.vue","language":"vue","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"script"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" setup"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" lang"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"ts"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" supabase "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseClient"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" email "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" ref"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"''"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" signInWithOtp "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" error"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"auth"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"signInWithOtp"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" email"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" email"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":8},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" options"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":9},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" emailRedirectTo"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"http://localhost:3000/confirm"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":10},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":11},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":12},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" if"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"error"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":") "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"console"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"log"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"error"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":13},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":14},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":15},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"template"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":16},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" <"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"div"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":17},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" <"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"button"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" @"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"click"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"signInWithOtp"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":18},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" Sign In with E-Mail\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":19},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" \n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":20},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" <"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"input\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":21},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" v-model"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"email"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":22},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" type"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"email"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":23},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" />\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":24},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" \n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":25},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Once the authorization flow is triggered using the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"auth"}]},{"type":"text","value":" wrapper of the "},{"type":"element","tag":"a","props":{"href":"/usage/composables/usesupabaseclient"},"children":[{"type":"text","value":"useSupabaseClient"}]},{"type":"text","value":" composable, the session management is handled automatically and the user will be redirected to the page you specify in the redirect option ("},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"/confirm"}]},{"type":"text","value":" by default)."}]},{"type":"element","tag":"h2","props":{"id":"confirm-page-confirm"},"children":[{"type":"text","value":"Confirm page - "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"/confirm"}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"The confirmation page receives the supabase callback. From there you can check the user value and redirect to the appropriate page."}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-light-bulb"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"The redirect URL must be configured in your Supabase dashboard under "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"Authentication -> URL Configuration -> Redirect URLs"}]},{"type":"text","value":"."}]}]},{"type":"element","tag":"pre","props":{"className":"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"\n\n\n","filename":"pages/confirm.vue","language":"vue","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"script"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" setup"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" lang"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"ts"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" user "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseUser"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"watch"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"(user"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" if"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"user"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":") "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" // Redirect to protected page\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" navigateTo"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":8},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":9},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"},"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" immediate"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC"},"children":[{"type":"text","value":" true"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":10},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":11},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":12},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"template"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":13},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" <"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"div"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"Waiting for login..."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":14},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]}]}]},{"type":"element","tag":"h3","props":{"id":"redirect-path"},"children":[{"type":"text","value":"Redirect path"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"You can easily handle redirection to the initial requested route after login."}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-light-bulb"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"You must enable the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"cookieRedirect"}]},{"type":"text","value":" option of the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirectoptions"},"children":[{"type":"text","value":"redirectOptions"}]},{"type":"text","value":" to allow cookie storage and take benefit of this feature."}]}]},{"type":"element","tag":"pre","props":{"className":"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"\n\n","filename":"pages/confirm.vue","language":"vue","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"script"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" setup"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" lang"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"ts"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" user "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseUser"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"// Get redirect path from cookies\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" cookieName "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useRuntimeConfig"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"public"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"cookieName\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" redirectPath "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useCookie"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"`${"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"cookieName"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"-redirect-path"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"`"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":8},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"watch"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"(user"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":9},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" if"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"user"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":") "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":10},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" // Clear cookie\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":11},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useCookie"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"`${"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"cookieName"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"-redirect-path"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"`"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" null\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":12},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" // Redirect to path\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":13},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" navigateTo"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"redirectPath"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ||"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":";"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" \n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":14},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":15},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"},"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" immediate"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC"},"children":[{"type":"text","value":" true"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":16},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":17},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"template"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":18},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" <"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"div"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"Waiting for login..."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":19},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]}]}]},{"type":"element","tag":"style","props":{},"children":[{"type":"text","value":"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}"}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[{"id":"log-in-page-login","depth":2,"text":"Log-in page - /login"},{"id":"confirm-page-confirm","depth":2,"text":"Confirm page - /confirm","children":[{"id":"redirect-path","depth":3,"text":"Redirect path"}]}]}},"_type":"markdown","_id":"content:3.authentication.md","_source":"content","_file":"3.authentication.md","_stem":"3.authentication","_extension":"md"},{"_path":"/usage/_dir","_dir":"usage","_draft":false,"_partial":true,"_locale":"","title":"Usage","icon":"heroicons:book-open","_id":"content:4.usage:_dir.yml","_type":"yaml","_source":"content","_file":"4.usage/_dir.yml","_stem":"4.usage/_dir","_extension":"yml"},{"_path":"/usage/composables/_dir","_dir":"composables","_draft":false,"_partial":true,"_locale":"","title":"Vue composables","_id":"content:4.usage:composables:_dir.yml","_type":"yaml","_source":"content","_file":"4.usage/composables/_dir.yml","_stem":"4.usage/composables/_dir","_extension":"yml"},{"_path":"/usage/composables/usesupabaseclient","_dir":"composables","_draft":false,"_partial":false,"_locale":"","title":"useSupabaseClient","description":"Make requests to the Supabase API with the useSupabaseClient composable","body":{"type":"root","children":[{"type":"element","tag":"p","props":{},"children":[{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/composables","rel":["nofollow"]},"children":[{"type":"text","value":"Auto-import"}]},{"type":"text","value":" your client inside your vue files."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"This composable is using "},{"type":"element","tag":"a","props":{"href":"https://github.com/supabase/supabase-js/","rel":["nofollow"]},"children":[{"type":"text","value":"supabase-js"}]},{"type":"text","value":" under the hood, it gives access to the "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/reference/javascript/initializing","rel":["nofollow"]},"children":[{"type":"text","value":"Supabase client"}]},{"type":"text","value":"."}]},{"type":"element","tag":"blockquote","props":{},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"The client is initialized with the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"SUPABASE_KEY"}]},{"type":"text","value":" you must have in your "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":".env"}]},{"type":"text","value":" file. It establishes the connection with the database and make use of user JWT to apply "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/learn/auth-deep-dive/auth-row-level-security","rel":["nofollow"]},"children":[{"type":"text","value":"RLS Policies"}]},{"type":"text","value":" implemented in Supabase. If you want to bypass policies, you can use the "},{"type":"element","tag":"a","props":{"href":"/usage/services/serversupabaseservicerole"},"children":[{"type":"text","value":"serverSupabaseServiceRole"}]},{"type":"text","value":"."}]}]},{"type":"element","tag":"h2","props":{"id":"authentication"},"children":[{"type":"text","value":"Authentication"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"The useSupabaseClient composable is providing all methods to manage authorization under "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"useSupabaseClient().auth"}]},{"type":"text","value":". For more details please see the "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/reference/javascript/auth-api","rel":["nofollow"]},"children":[{"type":"text","value":"supabase-js auth documentation"}]},{"type":"text","value":". Here is an example for signing in and out:"}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-light-bulb"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"If you want a full explanation on how to handle the authentication process, please read this "},{"type":"element","tag":"a","props":{"href":"/get-started#handle-authentication"},"children":[{"type":"text","value":"section"}]},{"type":"text","value":"."}]}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"\n","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"script setup lang"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"ts"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" supabase "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseClient"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" signInWithOAuth "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" error"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"auth"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"signInWithOAuth"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" provider"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"github"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" options"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":8},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" redirectTo"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"http://localhost:3000/confirm"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":9},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" },\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":10},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":11},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" if"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"error"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":") "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"console"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"log"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"error"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":12},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":13},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":14},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" signOut "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":15},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" error"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"auth"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"signOut"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":16},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" if"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"error"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":") "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"console"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"log"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"error"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":17},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":18},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Please also take a look at "},{"type":"element","tag":"a","props":{"href":"/get-started"},"children":[{"type":"text","value":"Get Started"}]},{"type":"text","value":" for the authorization flow."}]},{"type":"element","tag":"h2","props":{"id":"database-request"},"children":[{"type":"text","value":"Database Request"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Please check "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/reference/javascript/select","rel":["nofollow"]},"children":[{"type":"text","value":"Supabase"}]},{"type":"text","value":" documentation to fully use the power of Supabase client."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Here is an example of a fetch using the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"select"}]},{"type":"text","value":" method with Nuxt 3 "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/getting-started/data-fetching#useasyncdata","rel":["nofollow"]},"children":[{"type":"text","value":"useAsyncData"}]},{"type":"text","value":" composable."}]},{"type":"element","tag":"pre","props":{"className":"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"\n","language":"vue","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"script"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" setup"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" lang"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"ts"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseClient"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" data"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" restaurant "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useAsyncData"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"restaurant"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"restaurants"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"select"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"name, location"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"eq"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"name"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"My Restaurant Name"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"single"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":8},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":9},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]}]}]},{"type":"element","tag":"h2","props":{"id":"realtime"},"children":[{"type":"text","value":"Realtime"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Based on "},{"type":"element","tag":"a","props":{"href":"https://github.com/supabase/realtime","rel":["nofollow"]},"children":[{"type":"text","value":"Supabase Realtime"}]},{"type":"text","value":", listen to changes in your PostgreSQL Database and broadcasts them over WebSockets."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"To enable it, make sure you have turned on the "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/guides/api#realtime-api","rel":["nofollow"]},"children":[{"type":"text","value":"Realtime API"}]},{"type":"text","value":" for your table."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Then, listen to changes directly in your vue page / component:"}]},{"type":"element","tag":"pre","props":{"className":"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"\n","language":"vue","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"script"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" setup"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" lang"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"ts"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"import"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" type"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" RealtimeChannel"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"@supabase/supabase-js"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseClient"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"let"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" realtimeChannel"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":" RealtimeChannel\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":8},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"// Fetch collaborators and get the refresh method provided by useAsyncData\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":9},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" data"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" collaborators"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" refresh"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" refreshCollaborators "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useAsyncData"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"collaborators"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":10},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"collaborators"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"select"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"name"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":11},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":12},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":13},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":14},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"// Once page is mounted, listen to changes on the `collaborators` table and refresh collaborators when receiving event\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":15},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"onMounted"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":16},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" // Real time listener for new workouts\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":17},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" realtimeChannel"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"channel"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"public:collaborators"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"on"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"(\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":18},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"postgres_changes"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":",\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":19},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" event"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"*"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" schema"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"public"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" table"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"collaborators"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" },\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":20},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" refreshCollaborators"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":21},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" )\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":22},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":23},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" realtimeChannel"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"subscribe"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":24},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":25},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":26},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" // Don't forget to unsubscribe when user left the page\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":27},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"onUnmounted"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":28},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"removeChannel"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"realtimeChannel"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":29},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":30},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]}]}]},{"type":"element","tag":"h2","props":{"id":"typescript"},"children":[{"type":"text","value":"Typescript"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Database typings are passed to the client out of the box if the database generated types are found at "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"./types/database.types.ts"}]},{"type":"text","value":" or "},{"type":"element","tag":"a","props":{"href":"/get-started#types"},"children":[{"type":"text","value":"your configured types path"}]},{"type":"text","value":". Check Supabase "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/reference/javascript/release-notes#typescript-support","rel":["nofollow"]},"children":[{"type":"text","value":"documentation"}]},{"type":"text","value":" for further information."}]},{"type":"element","tag":"pre","props":{"className":"language-shell shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"## Generate types from live database\nsupabase gen types typescript --project-id YourProjectId > types/database.types.ts\n\n## Generate types when using local environment\nsupabase gen types typescript --local > types/database.types.ts\n","language":"shell","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"## Generate types from live database\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":"supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" gen"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" types"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" typescript"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" --project-id"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" YourProjectId"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" >"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" types/database.types.ts\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"## Generate types when using local environment\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":"supabase"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" gen"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" types"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" typescript"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" --local"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" >"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":" types/database.types.ts\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"You can also pass Database typings to the client manually:"}]},{"type":"element","tag":"pre","props":{"className":"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"\n","language":"vue","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"script"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" setup"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" lang"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"ts"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\""}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"import"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" type"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" Database"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"~/types"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseClient"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B"},"children":[{"type":"text","value":"Database"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]}]}]},{"type":"element","tag":"style","props":{},"children":[{"type":"text","value":"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}"}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[{"id":"authentication","depth":2,"text":"Authentication"},{"id":"database-request","depth":2,"text":"Database Request"},{"id":"realtime","depth":2,"text":"Realtime"},{"id":"typescript","depth":2,"text":"Typescript"}]}},"_type":"markdown","_id":"content:4.usage:composables:useSupabaseClient.md","_source":"content","_file":"4.usage/composables/useSupabaseClient.md","_stem":"4.usage/composables/useSupabaseClient","_extension":"md"},{"_path":"/usage/composables/usesupabasesession","_dir":"composables","_draft":false,"_partial":false,"_locale":"","title":"useSupabaseSession","description":"Auto import and use your Supabase user's session with the useSupabaseSession composable","body":{"type":"root","children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Once logged in, you can "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/composables","rel":["nofollow"]},"children":[{"type":"text","value":"auto-import"}]},{"type":"text","value":" your user's session everywhere inside your vue files."}]},{"type":"element","tag":"pre","props":{"className":"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"\n","language":"vue","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"script"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" setup"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" session "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseSession"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]}]}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-light-bulb"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"If you just need the User's information you can use "},{"type":"element","tag":"a","props":{"href":"/usage/composables/usesupabaseuser"},"children":[{"type":"text","value":"useSupabaseUser"}]},{"type":"text","value":" which returns just the User information of the session."}]}]},{"type":"element","tag":"h2","props":{"id":"auth-middleware"},"children":[{"type":"text","value":"Auth middleware"}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-light-bulb"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"By default, the module is implementing a redirect middleware. All pages of your application are automatically redirected to the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirectoptions"},"children":[{"type":"text","value":"login"}]},{"type":"text","value":" page. However, you can allow redirection to \"public\" pages by setting the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirectoptions"},"children":[{"type":"text","value":"exclude"}]},{"type":"text","value":" redirect option. Alternatively, you can enable the redirect only for certain routes using the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirectoptions"},"children":[{"type":"text","value":"include"}]},{"type":"text","value":" redirect option."}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"If the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirect"},"children":[{"type":"text","value":"redirect"}]},{"type":"text","value":" option is disabled, you can protect your authenticated routes by creating a custom middleware in your project, here is an example:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"export default defineNuxtRouteMiddleware((to, _from) => {\n const session = useSupabaseSession()\n\n if (!session.value) {\n return navigateTo('/login')\n }\n})\n","filename":"middleware/auth.ts","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"export"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" default"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" defineNuxtRouteMiddleware"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"to"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" _from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" session"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseSession"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" if"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"!"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"session"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":") "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" navigateTo"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/login"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Then you can reference your middleware in your page with:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"definePageMeta({\n middleware: 'auth'\n})\n","filename":"pages/dashboard.vue","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"definePageMeta"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" middleware"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"auth"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Learn more about "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/middleware","rel":["nofollow"]},"children":[{"type":"text","value":"Nuxt middleware"}]},{"type":"text","value":" and "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/pages#page-metadata","rel":["nofollow"]},"children":[{"type":"text","value":"definePageMeta"}]},{"type":"text","value":"."}]},{"type":"element","tag":"style","props":{},"children":[{"type":"text","value":"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}"}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[{"id":"auth-middleware","depth":2,"text":"Auth middleware"}]}},"_type":"markdown","_id":"content:4.usage:composables:useSupabaseSession.md","_source":"content","_file":"4.usage/composables/useSupabaseSession.md","_stem":"4.usage/composables/useSupabaseSession","_extension":"md"},{"_path":"/usage/composables/usesupabaseuser","_dir":"composables","_draft":false,"_partial":false,"_locale":"","title":"useSupabaseUser","description":"Auto import and use your Supabase user with the useSupabaseUser composable","body":{"type":"root","children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Once logged in, you can "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/composables","rel":["nofollow"]},"children":[{"type":"text","value":"auto-import"}]},{"type":"text","value":" your user everywhere inside your vue files."}]},{"type":"element","tag":"pre","props":{"className":"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"\n","language":"vue","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"<"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"script"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" setup"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":">\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" user "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseUser"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"\n"}]}]}]}]},{"type":"element","tag":"h2","props":{"id":"auth-middleware"},"children":[{"type":"text","value":"Auth middleware"}]},{"type":"element","tag":"callout","props":{"icon":"i-heroicons-light-bulb"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"By default, the module is implementing a redirect middleware. All pages of your application are automatically redirected to the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirectoptions"},"children":[{"type":"text","value":"login"}]},{"type":"text","value":" page. However, you can allow redirection to \"public\" pages by setting the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirectoptions"},"children":[{"type":"text","value":"exclude"}]},{"type":"text","value":" redirect option. Alternatively, you can enable the redirect only for certain routes using the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirectoptions"},"children":[{"type":"text","value":"include"}]},{"type":"text","value":" redirect option."}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"If the "},{"type":"element","tag":"a","props":{"href":"/get-started#redirect"},"children":[{"type":"text","value":"redirect"}]},{"type":"text","value":" option is disabled, you can protect your authenticated routes by creating a custom middleware in your project, here is an example:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"export default defineNuxtRouteMiddleware((to, _from) => {\n const user = useSupabaseUser()\n\n if (!user.value) {\n return navigateTo('/login')\n }\n})\n","filename":"middleware/auth.ts","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"export"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" default"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" defineNuxtRouteMiddleware"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"to"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" _from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" user"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useSupabaseUser"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" if"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"!"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"user"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":") "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" navigateTo"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/login"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Then you can reference your middleware in your page with:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"definePageMeta({\n middleware: 'auth'\n})\n","filename":"pages/dashboard.vue","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"definePageMeta"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"{\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" middleware"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"auth"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Learn more about "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/middleware","rel":["nofollow"]},"children":[{"type":"text","value":"Nuxt middleware"}]},{"type":"text","value":" and "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/pages#page-metadata","rel":["nofollow"]},"children":[{"type":"text","value":"definePageMeta"}]},{"type":"text","value":"."}]},{"type":"element","tag":"style","props":{},"children":[{"type":"text","value":"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}"}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[{"id":"auth-middleware","depth":2,"text":"Auth middleware"}]}},"_type":"markdown","_id":"content:4.usage:composables:useSupabaseUser.md","_source":"content","_file":"4.usage/composables/useSupabaseUser.md","_stem":"4.usage/composables/useSupabaseUser","_extension":"md"},{"_path":"/usage/services/_dir","_dir":"services","_draft":false,"_partial":true,"_locale":"","title":"Server services","_id":"content:4.usage:services:_dir.yml","_type":"yaml","_source":"content","_file":"4.usage/services/_dir.yml","_stem":"4.usage/services/_dir","_extension":"yml"},{"_path":"/usage/services/serversupabaseclient","_dir":"services","_draft":false,"_partial":false,"_locale":"","title":"serverSupabaseClient","description":"Make requests to the Supabase API on server side with the serverSupabaseClient service","body":{"type":"root","children":[{"type":"element","tag":"callout","props":{"color":"amber","icon":"i-heroicons-exclamation-triangle-20-solid"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"This section assumes you're familiar with "},{"type":"element","tag":"a","props":{"href":"https://v3.nuxtjs.org/guide/concepts/server-engine","rel":["nofollow"]},"children":[{"type":"text","value":"Nitro"}]},{"type":"text","value":", the server engine powered by Nuxt."}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"This function is working similary as the "},{"type":"element","tag":"a","props":{"href":"/usage/composables/usesupabaseclient"},"children":[{"type":"text","value":"useSupabaseClient"}]},{"type":"text","value":" composable but is designed to be used in "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/server#server-routes","rel":["nofollow"]},"children":[{"type":"text","value":"server routes"}]},{"type":"text","value":"."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Define your server route and just import the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"serverSupabaseClient"}]},{"type":"text","value":" from "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"#supabase/server"}]},{"type":"text","value":". Be careful, "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"serverSupabaseClient"}]},{"type":"text","value":" is returning a promise."}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"import { serverSupabaseClient } from '#supabase/server'\n\nexport default eventHandler(async (event) => {\n const client = await serverSupabaseClient(event)\n\n const { data } = await client.from('libraries').select('*')\n\n return { libraries: data }\n})\n","filename":"server/api/libraries.ts","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"import"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" serverSupabaseClient"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"#supabase/server"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"export"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" default"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" eventHandler"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"event"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" serverSupabaseClient"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"event"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"libraries"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"select"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"*"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":8},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" libraries"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":9},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Then call your API route from any vue file:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"const fetchLibrary = async () => {\n const { libraries } = await $fetch('/api/libraries')\n}\n","filename":"pages/index.vue","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" fetchLibrary "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" libraries"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" $fetch"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/api/libraries"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Be careful, if you want to call this route on SSR, please read this "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/getting-started/data-fetching#isomorphic-fetch-and-fetch","rel":["nofollow"]},"children":[{"type":"text","value":"section"}]},{"type":"text","value":", you must send your browser cookies including your supabase token."}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"const { data: { libraries }} = await useFetch('/api/libraries', {\n headers: useRequestHeaders(['cookie'])\n})\n","filename":"pages/index.vue","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" data"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" libraries "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useFetch"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/api/libraries"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" headers"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useRequestHeaders"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"(["}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"cookie"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"])\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"style","props":{},"children":[{"type":"text","value":"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}"}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[]}},"_type":"markdown","_id":"content:4.usage:services:1.serverSupabaseClient.md","_source":"content","_file":"4.usage/services/1.serverSupabaseClient.md","_stem":"4.usage/services/1.serverSupabaseClient","_extension":"md"},{"_path":"/usage/services/serversupabaseservicerole","_dir":"services","_draft":false,"_partial":false,"_locale":"","title":"serverServiceRole","description":"Make requests with super admin rights to the Supabase API with the serverSupabaseServiceRole service","navigation":{"title":"serverSupabaseServiceRole"},"body":{"type":"root","children":[{"type":"element","tag":"callout","props":{"color":"amber","icon":"i-heroicons-exclamation-triangle-20-solid"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"This section assumes you're familiar with "},{"type":"element","tag":"a","props":{"href":"https://v3.nuxtjs.org/guide/concepts/server-engine","rel":["nofollow"]},"children":[{"type":"text","value":"Nitro"}]},{"type":"text","value":", the server engine powered by Nuxt."}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"This function is designed to work only in "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/server#server-routes","rel":["nofollow"]},"children":[{"type":"text","value":"server routes"}]},{"type":"text","value":", there is no vue composable equivalent."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"It works similary as the "},{"type":"element","tag":"a","props":{"href":"/usage/services/serversupabaseclient"},"children":[{"type":"text","value":"serverSupabaseClient"}]},{"type":"text","value":" but it provides a client with super admin rights that can bypass your "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/guides/auth/row-level-security","rel":["nofollow"]},"children":[{"type":"text","value":"Row Level Security"}]},{"type":"text","value":"."}]},{"type":"element","tag":"blockquote","props":{},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"The client is initialized with the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"SUPABASE_SERVICE_KEY"}]},{"type":"text","value":" you must have in your "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":".env"}]},{"type":"text","value":" file. Checkout the doc if you want to know more about "},{"type":"element","tag":"a","props":{"href":"https://supabase.com/docs/learn/auth-deep-dive/auth-deep-dive-jwts#jwts-in-supabase","rel":["nofollow"]},"children":[{"type":"text","value":"Supabase keys"}]},{"type":"text","value":"."}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Define your server route and just import the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"serverSupabaseServiceRole"}]},{"type":"text","value":" from "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"#supabase/server"}]},{"type":"text","value":"."}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"import { serverSupabaseServiceRole } from '#supabase/server'\n\nexport default eventHandler(async (event) => {\n const client = serverSupabaseServiceRole(event)\n\n const { data } = await client.from('rls-protected-table').select()\n\n return { sensitiveData: data }\n})\n","filename":"server/api/bypass-rls.ts","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"import"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" serverSupabaseServiceRole"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"#supabase/server"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"export"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" default"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" eventHandler"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"event"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" serverSupabaseServiceRole"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"event"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" client"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"rls-protected-table"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":"select"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"()\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":8},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" sensitiveData"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":9},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Then call your API route from any vue file:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"const fetchSensitiveData = async () => {\n const { sensitiveData } = await useFetch('/api/bypass-rls')\n}\n","filename":"pages/index.vue","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" fetchSensitiveData "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" sensitiveData"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useFetch"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/api/bypass-rls"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}\n"}]}]}]}]},{"type":"element","tag":"style","props":{},"children":[{"type":"text","value":"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}"}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[]}},"_type":"markdown","_id":"content:4.usage:services:2.serverSupabaseServiceRole.md","_source":"content","_file":"4.usage/services/2.serverSupabaseServiceRole.md","_stem":"4.usage/services/2.serverSupabaseServiceRole","_extension":"md"},{"_path":"/usage/services/serversupabasesession","_dir":"services","_draft":false,"_partial":false,"_locale":"","title":"serverSupabaseSession","description":"Get your Supabase user's session from serverside with the serverSupabaseUser service","body":{"type":"root","children":[{"type":"element","tag":"callout","props":{"color":"amber","icon":"i-heroicons-exclamation-triangle-20-solid"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"This section assumes you're familiar with "},{"type":"element","tag":"a","props":{"href":"https://v3.nuxtjs.org/guide/concepts/server-engine","rel":["nofollow"]},"children":[{"type":"text","value":"Nitro"}]},{"type":"text","value":", the server engine powered by Nuxt."}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"This function is similar to the "},{"type":"element","tag":"a","props":{"href":"/usage/composables/usesupabasesession"},"children":[{"type":"text","value":"useSupabaseSession"}]},{"type":"text","value":" composable but is used in "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/server#server-routes","rel":["nofollow"]},"children":[{"type":"text","value":"server routes"}]},{"type":"text","value":"."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Define your server route and import the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"serverSupabaseSession"}]},{"type":"text","value":" from "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"#supabase/server"}]},{"type":"text","value":"."}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"import { serverSupabaseSession } from '#supabase/server'\n\nexport default defineEventHandler(async (event) => {\n return await serverSupabaseSession(event)\n})\n","filename":"server/api/session.ts","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"import"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" serverSupabaseSession"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"#supabase/server"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"export"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" default"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" defineEventHandler"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"event"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" serverSupabaseSession"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"event"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Then call your api route from any vue file:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"const session = ref(null)\n\nconst fetchSession = async () => {\n session.value = await $fetch('/api/session')\n}\n","filename":"pages/index.vue","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" session "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" ref"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"null"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" fetchSession "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" session"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" $fetch"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/api/session"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Be careful, if you want to call this route on SSR, please read this "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/getting-started/data-fetching#isomorphic-fetch-and-fetch","rel":["nofollow"]},"children":[{"type":"text","value":"section"}]},{"type":"text","value":", you must send your browser cookies including your supabase token."}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"const session = ref(null)\n\nconst { data } = await useFetch('/api/session', {\n headers: useRequestHeaders(['cookie'])\n})\n\nsession.value = data\n","filename":"pages/index.vue","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" session "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" ref"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"null"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useFetch"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/api/session"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" headers"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useRequestHeaders"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"(["}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"cookie"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"])\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"session"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data\n"}]}]}]}]},{"type":"element","tag":"style","props":{},"children":[{"type":"text","value":"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}"}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[]}},"_type":"markdown","_id":"content:4.usage:services:3.serverSupabaseSession.md","_source":"content","_file":"4.usage/services/3.serverSupabaseSession.md","_stem":"4.usage/services/3.serverSupabaseSession","_extension":"md"},{"_path":"/usage/services/serversupabaseuser","_dir":"services","_draft":false,"_partial":false,"_locale":"","title":"serverSupabaseUser","description":"Get your Supabase user from serverside with the serverSupabaseUser service","body":{"type":"root","children":[{"type":"element","tag":"callout","props":{"color":"amber","icon":"i-heroicons-exclamation-triangle-20-solid"},"children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"This section assumes you're familiar with "},{"type":"element","tag":"a","props":{"href":"https://v3.nuxtjs.org/guide/concepts/server-engine","rel":["nofollow"]},"children":[{"type":"text","value":"Nitro"}]},{"type":"text","value":", the server engine powered by Nuxt."}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"This function is similar to the "},{"type":"element","tag":"a","props":{"href":"/usage/composables/usesupabaseuser"},"children":[{"type":"text","value":"useSupabaseUser"}]},{"type":"text","value":" composable but is used in "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/guide/directory-structure/server#server-routes","rel":["nofollow"]},"children":[{"type":"text","value":"server routes"}]},{"type":"text","value":"."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Define your server route and import the "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"serverSupabaseUser"}]},{"type":"text","value":" from "},{"type":"element","tag":"code","props":{"className":[]},"children":[{"type":"text","value":"#supabase/server"}]},{"type":"text","value":"."}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"import { serverSupabaseUser } from '#supabase/server'\n\nexport default defineEventHandler(async (event) => {\n return await serverSupabaseUser(event)\n})\n","filename":"server/api/me.ts","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"import"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" serverSupabaseUser"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" }"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" from"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" '"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"#supabase/server"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"export"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" default"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" defineEventHandler"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":"event"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":")"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" return"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" serverSupabaseUser"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"event"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Then call your api route from any vue file:"}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"const user = ref(null)\n\nconst fetchMe = async () => {\n user.value = await $fetch('/api/me')\n}\n","filename":"pages/index.vue","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" user "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" ref"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"null"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" fetchMe "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" async"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ()"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":" =>"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" user"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" $fetch"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/api/me"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}\n"}]}]}]}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Be careful, if you want to call this route on SSR, please read this "},{"type":"element","tag":"a","props":{"href":"https://nuxt.com/docs/getting-started/data-fetching#isomorphic-fetch-and-fetch","rel":["nofollow"]},"children":[{"type":"text","value":"section"}]},{"type":"text","value":", you must send your browser cookies including your supabase token."}]},{"type":"element","tag":"pre","props":{"className":"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","code":"const user = ref(null)\n\nconst { data } = await useFetch('/api/me', {\n headers: useRequestHeaders(['cookie'])\n})\n\nuser.value = data\n","filename":"pages/index.vue","language":"ts","meta":"","style":""},"children":[{"type":"element","tag":"code","props":{"__ignoreMap":""},"children":[{"type":"element","tag":"span","props":{"class":"line","line":1},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" user "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" ref"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"null"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":2},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":3},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA"},"children":[{"type":"text","value":"const"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" ="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic"},"children":[{"type":"text","value":" await"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useFetch"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"("}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"/api/me"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":","}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":" {\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":4},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178"},"children":[{"type":"text","value":" headers"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":":"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF"},"children":[{"type":"text","value":" useRequestHeaders"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"(["}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D"},"children":[{"type":"text","value":"cookie"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"'"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"])\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":5},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"}"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":")\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":6},"children":[{"type":"element","tag":"span","props":{"emptyLinePlaceholder":true},"children":[{"type":"text","value":"\n"}]}]},{"type":"element","tag":"span","props":{"class":"line","line":7},"children":[{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"user"}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"."}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":"value "}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF"},"children":[{"type":"text","value":"="}]},{"type":"element","tag":"span","props":{"style":"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8"},"children":[{"type":"text","value":" data\n"}]}]}]}]},{"type":"element","tag":"style","props":{},"children":[{"type":"text","value":"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}"}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[]}},"_type":"markdown","_id":"content:4.usage:services:4.serverSupabaseUser.md","_source":"content","_file":"4.usage/services/4.serverSupabaseUser.md","_stem":"4.usage/services/4.serverSupabaseUser","_extension":"md"},{"_path":"/demo","_dir":"","_draft":false,"_partial":false,"_locale":"","title":"Demo","description":"Demonstration of using Supabase with Nuxt.","icon":"i-heroicons-computer-desktop-20-solid","body":{"type":"root","children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Demonstration of using Supabase with Nuxt."}]},{"type":"element","tag":"p","props":{},"children":[{"type":"element","tag":"a","props":{"href":"https://n3-supabase.netlify.app","rel":["nofollow"]},"children":[{"type":"element","tag":"img","props":{"alt":"Supabase demo with Nuxt 3","src":"https://user-images.githubusercontent.com/904724/160422461-8f87500a-8dec-4413-86b2-ba04e1b2d17b.png"},"children":[]}]}]},{"type":"element","tag":"h2","props":{"id":"live-demo"},"children":[{"type":"text","value":"Live demo"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"You can play with the demo on "},{"type":"element","tag":"a","props":{"href":"https://n3-supabase.netlify.app","rel":["nofollow"]},"children":[{"type":"text","value":"n3-supabase.netlify.app"}]}]},{"type":"element","tag":"h2","props":{"id":"running-locally"},"children":[{"type":"text","value":"Running locally"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Follow the instruction in the "},{"type":"element","tag":"a","props":{"href":"https://github.com/nuxt-community/supabase-module/tree/main/demo","rel":["nofollow"]},"children":[{"type":"text","value":"demo Readme"}]},{"type":"text","value":"."}]},{"type":"element","tag":"h2","props":{"id":"source-code"},"children":[{"type":"text","value":"Source code"}]},{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"The source code is available on Github in the "},{"type":"element","tag":"a","props":{"href":"https://github.com/nuxt-community/supabase-module/tree/main/demo","rel":["nofollow"]},"children":[{"type":"text","value":"demo/ directory"}]},{"type":"text","value":"."}]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[{"id":"live-demo","depth":2,"text":"Live demo"},{"id":"running-locally","depth":2,"text":"Running locally"},{"id":"source-code","depth":2,"text":"Source code"}]}},"_type":"markdown","_id":"content:5.demo.md","_source":"content","_file":"5.demo.md","_stem":"5.demo","_extension":"md"},{"_path":"/changelog","_dir":"","_draft":false,"_partial":false,"_locale":"","title":"Changelog","description":"Discover the latest updates of the Supabase Module","icon":"i-heroicons-bookmark","body":{"type":"root","children":[{"type":"element","tag":"p","props":{},"children":[{"type":"text","value":"Discover the lastest updates."}]},{"type":"element","tag":"releases","props":{},"children":[]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[]}},"_type":"markdown","_id":"content:6.changelog.md","_source":"content","_file":"6.changelog.md","_stem":"6.changelog","_extension":"md"},{"_path":"/roadmap","_dir":"","_draft":false,"_partial":false,"_locale":"","title":"Roadmap","description":"Discover our kaban board for the next release of the Supabase module.","icon":"i-heroicons-map","body":{"type":"root","children":[{"type":"element","tag":"volta-board","props":{"token":"eyJzdGF0dXNlcyI6WyJ0cmlhZ2UiLCJiYWNrbG9nIiwidG9kbyIsImluX3Byb2dyZXNzIiwiaW5fcmV2aWV3IiwiZG9uZSIsInJlbGVhc2VkIiwiY2FuY2VsbGVkIl0sImZpbHRlcnMiOnt9LCJvd25lciI6Im51eHQtbW9kdWxlcyIsIm5hbWUiOiJzdXBhYmFzZSJ9"},"children":[]}],"toc":{"title":"","searchDepth":2,"depth":2,"links":[]}},"_type":"markdown","_id":"content:7.roadmap.md","_source":"content","_file":"7.roadmap.md","_stem":"7.roadmap","_extension":"md"},{"_path":"/","_dir":"","_draft":false,"_partial":false,"_locale":"","title":"Nuxt Supabase - Home","description":"A supa simple wrapper around supabase-js to enable usage and integration within Nuxt.","navigation":false,"hero":{"title":"Nuxt [Supabase]{.text-primary}","description":"A supa simple wrapper around supabase-js to enable usage and integration within Nuxt.","orientation":"horizontal","links":[{"label":"Get started","icon":"i-heroicons-rocket-launch","to":"/get-started","size":"lg"},{"label":"Star on github","icon":"i-heroicons-star","color":"white","to":"https://github.com/nuxt-modules/supabase","target":"_blank","size":"lg"}],"code":"```ts\n const supabase = useSupabaseClient()\n const email = ref('')\n\n const signInWithOtp = async () => {\n await supabase.auth.signInWithOtp({\n email: email.value,\n })\n }\n```\n"},"features":{"title":"Shipped with many features","items":[{"title":"Nuxt 3 ready","icon":"i-simple-icons-nuxtdotjs","to":"https://nuxt.com","target":"_blank"},{"title":"Vue 3 composables","icon":"i-simple-icons-vuedotjs","to":"https://vuejs.org/guide/reusability/composables.html","target":"_blank"},{"title":"Supabase-js V2","icon":"i-simple-icons-supabase","to":"https://supabase.com","target":"_blank"},{"title":"Usage in API server routes","icon":"i-heroicons-server","to":"usage/services/serversupabaseclient"},{"title":"Authentication support","icon":"i-heroicons-key","to":"/authentication"},{"title":"TypeScript support","icon":"i-simple-icons-typescript","to":"https://www.typescriptlang.org","target":"_blank"}]},"_id":"content:index.yml","_type":"yaml","_source":"content","_file":"index.yml","_stem":"index","_extension":"yml"}],"navigation":[{"title":"Get Started","_path":"/get-started","icon":"i-heroicons-rocket-launch"},{"title":"Authentication","_path":"/authentication","icon":"i-heroicons-lock-closed"},{"title":"Usage","_path":"/usage","children":[{"title":"Vue composables","_path":"/usage/composables","children":[{"title":"useSupabaseClient","_path":"/usage/composables/usesupabaseclient"},{"title":"useSupabaseSession","_path":"/usage/composables/usesupabasesession"},{"title":"useSupabaseUser","_path":"/usage/composables/usesupabaseuser"}]},{"title":"Server services","_path":"/usage/services","children":[{"title":"serverSupabaseClient","_path":"/usage/services/serversupabaseclient"},{"title":"serverSupabaseServiceRole","_path":"/usage/services/serversupabaseservicerole"},{"title":"serverSupabaseSession","_path":"/usage/services/serversupabasesession"},{"title":"serverSupabaseUser","_path":"/usage/services/serversupabaseuser"}]}],"icon":"heroicons:book-open"},{"title":"Demo","_path":"/demo","icon":"i-heroicons-computer-desktop-20-solid"},{"title":"Changelog","_path":"/changelog","icon":"i-heroicons-bookmark"},{"title":"Roadmap","_path":"/roadmap","icon":"i-heroicons-map"}]} \ No newline at end of file diff --git a/api/_content/navigation/i5pZc4XEtQ.1724940796509.json b/api/_content/navigation/i5pZc4XEtQ.1724942461696.json similarity index 100% rename from api/_content/navigation/i5pZc4XEtQ.1724940796509.json rename to api/_content/navigation/i5pZc4XEtQ.1724942461696.json diff --git a/api/_content/query/0CgxMh2nDn.1724940796509.json b/api/_content/query/0CgxMh2nDn.1724942461696.json similarity index 100% rename from api/_content/query/0CgxMh2nDn.1724940796509.json rename to api/_content/query/0CgxMh2nDn.1724942461696.json diff --git a/api/_content/query/0z8C0XHO1T.1724940796509.json b/api/_content/query/0z8C0XHO1T.1724942461696.json similarity index 100% rename from api/_content/query/0z8C0XHO1T.1724940796509.json rename to api/_content/query/0z8C0XHO1T.1724942461696.json diff --git a/api/_content/query/45OFyaq6jH.1724940796509.json b/api/_content/query/45OFyaq6jH.1724942461696.json similarity index 100% rename from api/_content/query/45OFyaq6jH.1724940796509.json rename to api/_content/query/45OFyaq6jH.1724942461696.json diff --git a/api/_content/query/4SGzzquaGr.1724940796509.json b/api/_content/query/4SGzzquaGr.1724942461696.json similarity index 100% rename from api/_content/query/4SGzzquaGr.1724940796509.json rename to api/_content/query/4SGzzquaGr.1724942461696.json diff --git a/api/_content/query/5439goEiFh.1724940796509.json b/api/_content/query/5439goEiFh.1724942461696.json similarity index 100% rename from api/_content/query/5439goEiFh.1724940796509.json rename to api/_content/query/5439goEiFh.1724942461696.json diff --git a/api/_content/query/7akagRHES3.1724940796509.json b/api/_content/query/7akagRHES3.1724942461696.json similarity index 100% rename from api/_content/query/7akagRHES3.1724940796509.json rename to api/_content/query/7akagRHES3.1724942461696.json diff --git a/api/_content/query/80r9Q1yB5X.1724940796509.json b/api/_content/query/80r9Q1yB5X.1724942461696.json similarity index 100% rename from api/_content/query/80r9Q1yB5X.1724940796509.json rename to api/_content/query/80r9Q1yB5X.1724942461696.json diff --git a/api/_content/query/Gxz9GZ4NK0.1724940796509.json b/api/_content/query/Gxz9GZ4NK0.1724942461696.json similarity index 100% rename from api/_content/query/Gxz9GZ4NK0.1724940796509.json rename to api/_content/query/Gxz9GZ4NK0.1724942461696.json diff --git a/api/_content/query/JJ9Joz4sQk.1724940796509.json b/api/_content/query/JJ9Joz4sQk.1724942461696.json similarity index 100% rename from api/_content/query/JJ9Joz4sQk.1724940796509.json rename to api/_content/query/JJ9Joz4sQk.1724942461696.json diff --git a/api/_content/query/MZBly8ycYV.1724940796509.json b/api/_content/query/MZBly8ycYV.1724942461696.json similarity index 100% rename from api/_content/query/MZBly8ycYV.1724940796509.json rename to api/_content/query/MZBly8ycYV.1724942461696.json diff --git a/api/_content/query/NX6rA77pmQ.1724940796509.json b/api/_content/query/NX6rA77pmQ.1724942461696.json similarity index 100% rename from api/_content/query/NX6rA77pmQ.1724940796509.json rename to api/_content/query/NX6rA77pmQ.1724942461696.json diff --git a/api/_content/query/NmhWrRnmKx.1724940796509.json b/api/_content/query/NmhWrRnmKx.1724942461696.json similarity index 100% rename from api/_content/query/NmhWrRnmKx.1724940796509.json rename to api/_content/query/NmhWrRnmKx.1724942461696.json diff --git a/api/_content/query/PKwnxE4Dvh.1724940796509.json b/api/_content/query/PKwnxE4Dvh.1724942461696.json similarity index 100% rename from api/_content/query/PKwnxE4Dvh.1724940796509.json rename to api/_content/query/PKwnxE4Dvh.1724942461696.json diff --git a/api/_content/query/Ue1UBSoyPa.1724940796509.json b/api/_content/query/Ue1UBSoyPa.1724942461696.json similarity index 100% rename from api/_content/query/Ue1UBSoyPa.1724940796509.json rename to api/_content/query/Ue1UBSoyPa.1724942461696.json diff --git a/api/_content/query/Xxnd0ydUti.1724940796509.json b/api/_content/query/Xxnd0ydUti.1724942461696.json similarity index 100% rename from api/_content/query/Xxnd0ydUti.1724940796509.json rename to api/_content/query/Xxnd0ydUti.1724942461696.json diff --git a/api/_content/query/Z0Gn1CUVQt.1724940796509.json b/api/_content/query/Z0Gn1CUVQt.1724942461696.json similarity index 100% rename from api/_content/query/Z0Gn1CUVQt.1724940796509.json rename to api/_content/query/Z0Gn1CUVQt.1724942461696.json diff --git a/api/_content/query/fAcRU6Tr0q.1724940796509.json b/api/_content/query/fAcRU6Tr0q.1724942461696.json similarity index 100% rename from api/_content/query/fAcRU6Tr0q.1724940796509.json rename to api/_content/query/fAcRU6Tr0q.1724942461696.json diff --git a/api/_content/query/hJ9QUBFRaO.1724940796509.json b/api/_content/query/hJ9QUBFRaO.1724942461696.json similarity index 100% rename from api/_content/query/hJ9QUBFRaO.1724940796509.json rename to api/_content/query/hJ9QUBFRaO.1724942461696.json diff --git a/api/_content/query/hTR0awNBk6.1724940796509.json b/api/_content/query/hTR0awNBk6.1724942461696.json similarity index 100% rename from api/_content/query/hTR0awNBk6.1724940796509.json rename to api/_content/query/hTR0awNBk6.1724942461696.json diff --git a/api/_content/query/kTW5TvkZlR.1724940796509.json b/api/_content/query/kTW5TvkZlR.1724942461696.json similarity index 100% rename from api/_content/query/kTW5TvkZlR.1724940796509.json rename to api/_content/query/kTW5TvkZlR.1724942461696.json diff --git a/api/_content/query/lNIwYbwZIk.1724940796509.json b/api/_content/query/lNIwYbwZIk.1724942461696.json similarity index 100% rename from api/_content/query/lNIwYbwZIk.1724940796509.json rename to api/_content/query/lNIwYbwZIk.1724942461696.json diff --git a/api/_content/query/qkxNYcIfXu.1724940796509.json b/api/_content/query/qkxNYcIfXu.1724942461696.json similarity index 100% rename from api/_content/query/qkxNYcIfXu.1724940796509.json rename to api/_content/query/qkxNYcIfXu.1724942461696.json diff --git a/api/_content/query/qrL652uheB.1724940796509.json b/api/_content/query/qrL652uheB.1724942461696.json similarity index 100% rename from api/_content/query/qrL652uheB.1724940796509.json rename to api/_content/query/qrL652uheB.1724942461696.json diff --git a/api/_content/query/w5fRUDFpBK.1724940796509.json b/api/_content/query/w5fRUDFpBK.1724942461696.json similarity index 100% rename from api/_content/query/w5fRUDFpBK.1724940796509.json rename to api/_content/query/w5fRUDFpBK.1724942461696.json diff --git a/api/_content/query/y8Nv5yEpsm.1724940796509.json b/api/_content/query/y8Nv5yEpsm.1724942461696.json similarity index 100% rename from api/_content/query/y8Nv5yEpsm.1724940796509.json rename to api/_content/query/y8Nv5yEpsm.1724942461696.json diff --git a/authentication/_payload.json b/authentication/_payload.json index 9b64692e..14715bed 100644 --- a/authentication/_payload.json +++ b/authentication/_payload.json @@ -1 +1 @@ -[{"data":1,"prerenderedAt":1771},["ShallowReactive",2],{"navigation":3,"/authentication":58,"/authentication-surround":1766},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":10,"_dir":59,"_draft":60,"_partial":60,"_locale":59,"title":9,"description":61,"icon":11,"body":62,"_type":1760,"_id":1761,"_source":1762,"_file":1763,"_stem":1764,"_extension":1765},"",false,"Authenticate your user thanks to the PKCE Oauth protocol that enables secure exchange of refresh and access tokens between an application and the authorization server",{"type":63,"children":64,"toc":1752},"root",[65,93,123,140,153,173,190,204,842,868,879,884,899,1211,1218,1223,1246,1746],{"type":66,"tag":67,"props":68,"children":69},"element","p",{},[70,73,82,84,91],{"type":71,"value":72},"text","With the default options, the module requires a log-in page and a confirm page to handle the ",{"type":66,"tag":74,"props":75,"children":79},"a",{"href":76,"rel":77},"https://supabase.com/docs/guides/resources/glossary#pkce",[78],"nofollow",[80],{"type":71,"value":81},"PKCE authorization code flow",{"type":71,"value":83},". If you want to understand how it works under the hood, you can read this ",{"type":66,"tag":74,"props":85,"children":88},{"href":86,"rel":87},"https://supabase.com/docs/guides/auth/server-side-rendering#understanding-the-authentication-flow",[78],[89],{"type":71,"value":90},"section",{"type":71,"value":92},".",{"type":66,"tag":67,"props":94,"children":95},{},[96,98,105,107,113,115,121],{"type":71,"value":97},"All you need to do is to create a ",{"type":66,"tag":99,"props":100,"children":102},"code",{"className":101},[],[103],{"type":71,"value":104},"login.vue",{"type":71,"value":106}," and ",{"type":66,"tag":99,"props":108,"children":110},{"className":109},[],[111],{"type":71,"value":112},"confirm.vue",{"type":71,"value":114}," page in the ",{"type":66,"tag":99,"props":116,"children":118},{"className":117},[],[119],{"type":71,"value":120},"pages",{"type":71,"value":122}," folder.",{"type":66,"tag":124,"props":125,"children":127},"callout",{"icon":126},"i-heroicons-light-bulb",[128],{"type":66,"tag":67,"props":129,"children":130},{},[131,133,139],{"type":71,"value":132},"For advanced users who want to implement the auth behaviour themselves, you can disable or override the ",{"type":66,"tag":74,"props":134,"children":136},{"href":135},"/get-started#redirect",[137],{"type":71,"value":138},"redirect options",{"type":71,"value":92},{"type":66,"tag":141,"props":142,"children":144},"h2",{"id":143},"log-in-page-login",[145,147],{"type":71,"value":146},"Log-in page - ",{"type":66,"tag":99,"props":148,"children":150},{"className":149},[],[151],{"type":71,"value":152},"/login",{"type":66,"tag":67,"props":154,"children":155},{},[156,158,164,166,171],{"type":71,"value":157},"Each time a user is trying to access a page that needs authentication, he will automatically be redirected to the configured log in page. If you want to allow access to \"public\" page, you just need to add them in the ",{"type":66,"tag":74,"props":159,"children":161},{"href":160},"/get-started#redirectoptions",[162],{"type":71,"value":163},"exclude",{"type":71,"value":165}," redirect option. Alternatively, you can enable the redirect only for certain routes using the ",{"type":66,"tag":74,"props":167,"children":168},{"href":160},[169],{"type":71,"value":170},"include",{"type":71,"value":172}," redirect option.",{"type":66,"tag":124,"props":174,"children":177},{"icon":175,"color":176},"i-heroicons-exclamation-triangle-20-solid","amber",[178],{"type":66,"tag":67,"props":179,"children":180},{},[181,183,189],{"type":71,"value":182},"Ensure to activate the authentication providers you want in the Supabase Dashboard under ",{"type":66,"tag":99,"props":184,"children":186},{"className":185},[],[187],{"type":71,"value":188},"Authentication -> Providers",{"type":71,"value":92},{"type":66,"tag":67,"props":191,"children":192},{},[193,195,202],{"type":71,"value":194},"The log-in page initiates the log-in method(s) you choose from the ",{"type":66,"tag":74,"props":196,"children":199},{"href":197,"rel":198},"https://supabase.com/docs/reference/javascript/auth-signinwithpassword",[78],[200],{"type":71,"value":201},"available authorization methods",{"type":71,"value":203}," provided by Supabase, it could looks like:",{"type":66,"tag":205,"props":206,"children":211},"pre",{"className":207,"code":208,"filename":209,"language":210,"meta":59,"style":59},"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","\u003Cscript setup lang=\"ts\">\nconst supabase = useSupabaseClient()\nconst email = ref('')\n\nconst signInWithOtp = async () => {\n const { error } = await supabase.auth.signInWithOtp({\n email: email.value,\n options: {\n emailRedirectTo: 'http://localhost:3000/confirm',\n }\n })\n if (error) console.log(error)\n}\n\u003C/script>\n\u003Ctemplate>\n \u003Cdiv>\n \u003Cbutton @click=\"signInWithOtp\">\n Sign In with E-Mail\n \u003C/button>\n \u003Cinput\n v-model=\"email\"\n type=\"email\"\n />\n \u003C/div>\n\u003C/template>\n","pages/login.vue","vue",[212],{"type":66,"tag":99,"props":213,"children":214},{"__ignoreMap":59},[215,269,299,336,346,383,450,483,500,532,541,554,604,613,630,647,665,709,718,735,748,775,800,809,826],{"type":66,"tag":216,"props":217,"children":220},"span",{"class":218,"line":219},"line",1,[221,227,233,239,244,249,254,260,264],{"type":66,"tag":216,"props":222,"children":224},{"style":223},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[225],{"type":71,"value":226},"\u003C",{"type":66,"tag":216,"props":228,"children":230},{"style":229},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[231],{"type":71,"value":232},"script",{"type":66,"tag":216,"props":234,"children":236},{"style":235},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[237],{"type":71,"value":238}," setup",{"type":66,"tag":216,"props":240,"children":241},{"style":235},[242],{"type":71,"value":243}," lang",{"type":66,"tag":216,"props":245,"children":246},{"style":223},[247],{"type":71,"value":248},"=",{"type":66,"tag":216,"props":250,"children":251},{"style":223},[252],{"type":71,"value":253},"\"",{"type":66,"tag":216,"props":255,"children":257},{"style":256},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[258],{"type":71,"value":259},"ts",{"type":66,"tag":216,"props":261,"children":262},{"style":223},[263],{"type":71,"value":253},{"type":66,"tag":216,"props":265,"children":266},{"style":223},[267],{"type":71,"value":268},">\n",{"type":66,"tag":216,"props":270,"children":272},{"class":218,"line":271},2,[273,278,284,288,294],{"type":66,"tag":216,"props":274,"children":275},{"style":235},[276],{"type":71,"value":277},"const",{"type":66,"tag":216,"props":279,"children":281},{"style":280},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[282],{"type":71,"value":283}," supabase ",{"type":66,"tag":216,"props":285,"children":286},{"style":223},[287],{"type":71,"value":248},{"type":66,"tag":216,"props":289,"children":291},{"style":290},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[292],{"type":71,"value":293}," useSupabaseClient",{"type":66,"tag":216,"props":295,"children":296},{"style":280},[297],{"type":71,"value":298},"()\n",{"type":66,"tag":216,"props":300,"children":302},{"class":218,"line":301},3,[303,307,312,316,321,326,331],{"type":66,"tag":216,"props":304,"children":305},{"style":235},[306],{"type":71,"value":277},{"type":66,"tag":216,"props":308,"children":309},{"style":280},[310],{"type":71,"value":311}," email ",{"type":66,"tag":216,"props":313,"children":314},{"style":223},[315],{"type":71,"value":248},{"type":66,"tag":216,"props":317,"children":318},{"style":290},[319],{"type":71,"value":320}," ref",{"type":66,"tag":216,"props":322,"children":323},{"style":280},[324],{"type":71,"value":325},"(",{"type":66,"tag":216,"props":327,"children":328},{"style":223},[329],{"type":71,"value":330},"''",{"type":66,"tag":216,"props":332,"children":333},{"style":280},[334],{"type":71,"value":335},")\n",{"type":66,"tag":216,"props":337,"children":339},{"class":218,"line":338},4,[340],{"type":66,"tag":216,"props":341,"children":343},{"emptyLinePlaceholder":342},true,[344],{"type":71,"value":345},"\n",{"type":66,"tag":216,"props":347,"children":349},{"class":218,"line":348},5,[350,354,359,363,368,373,378],{"type":66,"tag":216,"props":351,"children":352},{"style":235},[353],{"type":71,"value":277},{"type":66,"tag":216,"props":355,"children":356},{"style":280},[357],{"type":71,"value":358}," signInWithOtp ",{"type":66,"tag":216,"props":360,"children":361},{"style":223},[362],{"type":71,"value":248},{"type":66,"tag":216,"props":364,"children":365},{"style":235},[366],{"type":71,"value":367}," async",{"type":66,"tag":216,"props":369,"children":370},{"style":223},[371],{"type":71,"value":372}," ()",{"type":66,"tag":216,"props":374,"children":375},{"style":235},[376],{"type":71,"value":377}," =>",{"type":66,"tag":216,"props":379,"children":380},{"style":223},[381],{"type":71,"value":382}," {\n",{"type":66,"tag":216,"props":384,"children":386},{"class":218,"line":385},6,[387,392,397,402,407,412,418,423,427,432,436,441,445],{"type":66,"tag":216,"props":388,"children":389},{"style":235},[390],{"type":71,"value":391}," const",{"type":66,"tag":216,"props":393,"children":394},{"style":223},[395],{"type":71,"value":396}," {",{"type":66,"tag":216,"props":398,"children":399},{"style":280},[400],{"type":71,"value":401}," error",{"type":66,"tag":216,"props":403,"children":404},{"style":223},[405],{"type":71,"value":406}," }",{"type":66,"tag":216,"props":408,"children":409},{"style":223},[410],{"type":71,"value":411}," =",{"type":66,"tag":216,"props":413,"children":415},{"style":414},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[416],{"type":71,"value":417}," await",{"type":66,"tag":216,"props":419,"children":420},{"style":280},[421],{"type":71,"value":422}," supabase",{"type":66,"tag":216,"props":424,"children":425},{"style":223},[426],{"type":71,"value":92},{"type":66,"tag":216,"props":428,"children":429},{"style":280},[430],{"type":71,"value":431},"auth",{"type":66,"tag":216,"props":433,"children":434},{"style":223},[435],{"type":71,"value":92},{"type":66,"tag":216,"props":437,"children":438},{"style":290},[439],{"type":71,"value":440},"signInWithOtp",{"type":66,"tag":216,"props":442,"children":443},{"style":229},[444],{"type":71,"value":325},{"type":66,"tag":216,"props":446,"children":447},{"style":223},[448],{"type":71,"value":449},"{\n",{"type":66,"tag":216,"props":451,"children":453},{"class":218,"line":452},7,[454,459,464,469,473,478],{"type":66,"tag":216,"props":455,"children":456},{"style":229},[457],{"type":71,"value":458}," email",{"type":66,"tag":216,"props":460,"children":461},{"style":223},[462],{"type":71,"value":463},":",{"type":66,"tag":216,"props":465,"children":466},{"style":280},[467],{"type":71,"value":468}," email",{"type":66,"tag":216,"props":470,"children":471},{"style":223},[472],{"type":71,"value":92},{"type":66,"tag":216,"props":474,"children":475},{"style":280},[476],{"type":71,"value":477},"value",{"type":66,"tag":216,"props":479,"children":480},{"style":223},[481],{"type":71,"value":482},",\n",{"type":66,"tag":216,"props":484,"children":486},{"class":218,"line":485},8,[487,492,496],{"type":66,"tag":216,"props":488,"children":489},{"style":229},[490],{"type":71,"value":491}," options",{"type":66,"tag":216,"props":493,"children":494},{"style":223},[495],{"type":71,"value":463},{"type":66,"tag":216,"props":497,"children":498},{"style":223},[499],{"type":71,"value":382},{"type":66,"tag":216,"props":501,"children":503},{"class":218,"line":502},9,[504,509,513,518,523,528],{"type":66,"tag":216,"props":505,"children":506},{"style":229},[507],{"type":71,"value":508}," emailRedirectTo",{"type":66,"tag":216,"props":510,"children":511},{"style":223},[512],{"type":71,"value":463},{"type":66,"tag":216,"props":514,"children":515},{"style":223},[516],{"type":71,"value":517}," '",{"type":66,"tag":216,"props":519,"children":520},{"style":256},[521],{"type":71,"value":522},"http://localhost:3000/confirm",{"type":66,"tag":216,"props":524,"children":525},{"style":223},[526],{"type":71,"value":527},"'",{"type":66,"tag":216,"props":529,"children":530},{"style":223},[531],{"type":71,"value":482},{"type":66,"tag":216,"props":533,"children":535},{"class":218,"line":534},10,[536],{"type":66,"tag":216,"props":537,"children":538},{"style":223},[539],{"type":71,"value":540}," }\n",{"type":66,"tag":216,"props":542,"children":544},{"class":218,"line":543},11,[545,550],{"type":66,"tag":216,"props":546,"children":547},{"style":223},[548],{"type":71,"value":549}," }",{"type":66,"tag":216,"props":551,"children":552},{"style":229},[553],{"type":71,"value":335},{"type":66,"tag":216,"props":555,"children":557},{"class":218,"line":556},12,[558,563,568,573,578,583,587,592,596,600],{"type":66,"tag":216,"props":559,"children":560},{"style":414},[561],{"type":71,"value":562}," if",{"type":66,"tag":216,"props":564,"children":565},{"style":229},[566],{"type":71,"value":567}," (",{"type":66,"tag":216,"props":569,"children":570},{"style":280},[571],{"type":71,"value":572},"error",{"type":66,"tag":216,"props":574,"children":575},{"style":229},[576],{"type":71,"value":577},") ",{"type":66,"tag":216,"props":579,"children":580},{"style":280},[581],{"type":71,"value":582},"console",{"type":66,"tag":216,"props":584,"children":585},{"style":223},[586],{"type":71,"value":92},{"type":66,"tag":216,"props":588,"children":589},{"style":290},[590],{"type":71,"value":591},"log",{"type":66,"tag":216,"props":593,"children":594},{"style":229},[595],{"type":71,"value":325},{"type":66,"tag":216,"props":597,"children":598},{"style":280},[599],{"type":71,"value":572},{"type":66,"tag":216,"props":601,"children":602},{"style":229},[603],{"type":71,"value":335},{"type":66,"tag":216,"props":605,"children":607},{"class":218,"line":606},13,[608],{"type":66,"tag":216,"props":609,"children":610},{"style":223},[611],{"type":71,"value":612},"}\n",{"type":66,"tag":216,"props":614,"children":616},{"class":218,"line":615},14,[617,622,626],{"type":66,"tag":216,"props":618,"children":619},{"style":223},[620],{"type":71,"value":621},"\u003C/",{"type":66,"tag":216,"props":623,"children":624},{"style":229},[625],{"type":71,"value":232},{"type":66,"tag":216,"props":627,"children":628},{"style":223},[629],{"type":71,"value":268},{"type":66,"tag":216,"props":631,"children":633},{"class":218,"line":632},15,[634,638,643],{"type":66,"tag":216,"props":635,"children":636},{"style":223},[637],{"type":71,"value":226},{"type":66,"tag":216,"props":639,"children":640},{"style":229},[641],{"type":71,"value":642},"template",{"type":66,"tag":216,"props":644,"children":645},{"style":223},[646],{"type":71,"value":268},{"type":66,"tag":216,"props":648,"children":650},{"class":218,"line":649},16,[651,656,661],{"type":66,"tag":216,"props":652,"children":653},{"style":223},[654],{"type":71,"value":655}," \u003C",{"type":66,"tag":216,"props":657,"children":658},{"style":229},[659],{"type":71,"value":660},"div",{"type":66,"tag":216,"props":662,"children":663},{"style":223},[664],{"type":71,"value":268},{"type":66,"tag":216,"props":666,"children":668},{"class":218,"line":667},17,[669,674,679,684,689,693,697,701,705],{"type":66,"tag":216,"props":670,"children":671},{"style":223},[672],{"type":71,"value":673}," \u003C",{"type":66,"tag":216,"props":675,"children":676},{"style":229},[677],{"type":71,"value":678},"button",{"type":66,"tag":216,"props":680,"children":681},{"style":223},[682],{"type":71,"value":683}," @",{"type":66,"tag":216,"props":685,"children":686},{"style":235},[687],{"type":71,"value":688},"click",{"type":66,"tag":216,"props":690,"children":691},{"style":223},[692],{"type":71,"value":248},{"type":66,"tag":216,"props":694,"children":695},{"style":223},[696],{"type":71,"value":253},{"type":66,"tag":216,"props":698,"children":699},{"style":280},[700],{"type":71,"value":440},{"type":66,"tag":216,"props":702,"children":703},{"style":223},[704],{"type":71,"value":253},{"type":66,"tag":216,"props":706,"children":707},{"style":223},[708],{"type":71,"value":268},{"type":66,"tag":216,"props":710,"children":712},{"class":218,"line":711},18,[713],{"type":66,"tag":216,"props":714,"children":715},{"style":280},[716],{"type":71,"value":717}," Sign In with E-Mail\n",{"type":66,"tag":216,"props":719,"children":721},{"class":218,"line":720},19,[722,727,731],{"type":66,"tag":216,"props":723,"children":724},{"style":223},[725],{"type":71,"value":726}," \u003C/",{"type":66,"tag":216,"props":728,"children":729},{"style":229},[730],{"type":71,"value":678},{"type":66,"tag":216,"props":732,"children":733},{"style":223},[734],{"type":71,"value":268},{"type":66,"tag":216,"props":736,"children":738},{"class":218,"line":737},20,[739,743],{"type":66,"tag":216,"props":740,"children":741},{"style":223},[742],{"type":71,"value":673},{"type":66,"tag":216,"props":744,"children":745},{"style":229},[746],{"type":71,"value":747},"input\n",{"type":66,"tag":216,"props":749,"children":751},{"class":218,"line":750},21,[752,757,761,765,770],{"type":66,"tag":216,"props":753,"children":754},{"style":235},[755],{"type":71,"value":756}," v-model",{"type":66,"tag":216,"props":758,"children":759},{"style":223},[760],{"type":71,"value":248},{"type":66,"tag":216,"props":762,"children":763},{"style":223},[764],{"type":71,"value":253},{"type":66,"tag":216,"props":766,"children":767},{"style":280},[768],{"type":71,"value":769},"email",{"type":66,"tag":216,"props":771,"children":772},{"style":223},[773],{"type":71,"value":774},"\"\n",{"type":66,"tag":216,"props":776,"children":778},{"class":218,"line":777},22,[779,784,788,792,796],{"type":66,"tag":216,"props":780,"children":781},{"style":235},[782],{"type":71,"value":783}," type",{"type":66,"tag":216,"props":785,"children":786},{"style":223},[787],{"type":71,"value":248},{"type":66,"tag":216,"props":789,"children":790},{"style":223},[791],{"type":71,"value":253},{"type":66,"tag":216,"props":793,"children":794},{"style":256},[795],{"type":71,"value":769},{"type":66,"tag":216,"props":797,"children":798},{"style":223},[799],{"type":71,"value":774},{"type":66,"tag":216,"props":801,"children":803},{"class":218,"line":802},23,[804],{"type":66,"tag":216,"props":805,"children":806},{"style":223},[807],{"type":71,"value":808}," />\n",{"type":66,"tag":216,"props":810,"children":812},{"class":218,"line":811},24,[813,818,822],{"type":66,"tag":216,"props":814,"children":815},{"style":223},[816],{"type":71,"value":817}," \u003C/",{"type":66,"tag":216,"props":819,"children":820},{"style":229},[821],{"type":71,"value":660},{"type":66,"tag":216,"props":823,"children":824},{"style":223},[825],{"type":71,"value":268},{"type":66,"tag":216,"props":827,"children":829},{"class":218,"line":828},25,[830,834,838],{"type":66,"tag":216,"props":831,"children":832},{"style":223},[833],{"type":71,"value":621},{"type":66,"tag":216,"props":835,"children":836},{"style":229},[837],{"type":71,"value":642},{"type":66,"tag":216,"props":839,"children":840},{"style":223},[841],{"type":71,"value":268},{"type":66,"tag":67,"props":843,"children":844},{},[845,847,852,854,858,860,866],{"type":71,"value":846},"Once the authorization flow is triggered using the ",{"type":66,"tag":99,"props":848,"children":850},{"className":849},[],[851],{"type":71,"value":431},{"type":71,"value":853}," wrapper of the ",{"type":66,"tag":74,"props":855,"children":856},{"href":22},[857],{"type":71,"value":21},{"type":71,"value":859}," composable, the session management is handled automatically and the user will be redirected to the page you specify in the redirect option (",{"type":66,"tag":99,"props":861,"children":863},{"className":862},[],[864],{"type":71,"value":865},"/confirm",{"type":71,"value":867}," by default).",{"type":66,"tag":141,"props":869,"children":871},{"id":870},"confirm-page-confirm",[872,874],{"type":71,"value":873},"Confirm page - ",{"type":66,"tag":99,"props":875,"children":877},{"className":876},[],[878],{"type":71,"value":865},{"type":66,"tag":67,"props":880,"children":881},{},[882],{"type":71,"value":883},"The confirmation page receives the supabase callback. From there you can check the user value and redirect to the appropriate page.",{"type":66,"tag":124,"props":885,"children":886},{"icon":126},[887],{"type":66,"tag":67,"props":888,"children":889},{},[890,892,898],{"type":71,"value":891},"The redirect URL must be configured in your Supabase dashboard under ",{"type":66,"tag":99,"props":893,"children":895},{"className":894},[],[896],{"type":71,"value":897},"Authentication -> URL Configuration -> Redirect URLs",{"type":71,"value":92},{"type":66,"tag":205,"props":900,"children":903},{"className":207,"code":901,"filename":902,"language":210,"meta":59,"style":59},"\u003Cscript setup lang=\"ts\">\nconst user = useSupabaseUser()\n\nwatch(user, () => {\n if (user.value) {\n // Redirect to protected page\n return navigateTo('/')\n }\n}, { immediate: true })\n\u003C/script>\n\n\u003Ctemplate>\n \u003Cdiv>Waiting for login...\u003C/div>\n\u003C/template>\n","pages/confirm.vue",[904],{"type":66,"tag":99,"props":905,"children":906},{"__ignoreMap":59},[907,946,971,978,1008,1040,1049,1083,1091,1126,1141,1148,1163,1196],{"type":66,"tag":216,"props":908,"children":909},{"class":218,"line":219},[910,914,918,922,926,930,934,938,942],{"type":66,"tag":216,"props":911,"children":912},{"style":223},[913],{"type":71,"value":226},{"type":66,"tag":216,"props":915,"children":916},{"style":229},[917],{"type":71,"value":232},{"type":66,"tag":216,"props":919,"children":920},{"style":235},[921],{"type":71,"value":238},{"type":66,"tag":216,"props":923,"children":924},{"style":235},[925],{"type":71,"value":243},{"type":66,"tag":216,"props":927,"children":928},{"style":223},[929],{"type":71,"value":248},{"type":66,"tag":216,"props":931,"children":932},{"style":223},[933],{"type":71,"value":253},{"type":66,"tag":216,"props":935,"children":936},{"style":256},[937],{"type":71,"value":259},{"type":66,"tag":216,"props":939,"children":940},{"style":223},[941],{"type":71,"value":253},{"type":66,"tag":216,"props":943,"children":944},{"style":223},[945],{"type":71,"value":268},{"type":66,"tag":216,"props":947,"children":948},{"class":218,"line":271},[949,953,958,962,967],{"type":66,"tag":216,"props":950,"children":951},{"style":235},[952],{"type":71,"value":277},{"type":66,"tag":216,"props":954,"children":955},{"style":280},[956],{"type":71,"value":957}," user ",{"type":66,"tag":216,"props":959,"children":960},{"style":223},[961],{"type":71,"value":248},{"type":66,"tag":216,"props":963,"children":964},{"style":290},[965],{"type":71,"value":966}," useSupabaseUser",{"type":66,"tag":216,"props":968,"children":969},{"style":280},[970],{"type":71,"value":298},{"type":66,"tag":216,"props":972,"children":973},{"class":218,"line":301},[974],{"type":66,"tag":216,"props":975,"children":976},{"emptyLinePlaceholder":342},[977],{"type":71,"value":345},{"type":66,"tag":216,"props":979,"children":980},{"class":218,"line":338},[981,986,991,996,1000,1004],{"type":66,"tag":216,"props":982,"children":983},{"style":290},[984],{"type":71,"value":985},"watch",{"type":66,"tag":216,"props":987,"children":988},{"style":280},[989],{"type":71,"value":990},"(user",{"type":66,"tag":216,"props":992,"children":993},{"style":223},[994],{"type":71,"value":995},",",{"type":66,"tag":216,"props":997,"children":998},{"style":223},[999],{"type":71,"value":372},{"type":66,"tag":216,"props":1001,"children":1002},{"style":235},[1003],{"type":71,"value":377},{"type":66,"tag":216,"props":1005,"children":1006},{"style":223},[1007],{"type":71,"value":382},{"type":66,"tag":216,"props":1009,"children":1010},{"class":218,"line":348},[1011,1015,1019,1024,1028,1032,1036],{"type":66,"tag":216,"props":1012,"children":1013},{"style":414},[1014],{"type":71,"value":562},{"type":66,"tag":216,"props":1016,"children":1017},{"style":229},[1018],{"type":71,"value":567},{"type":66,"tag":216,"props":1020,"children":1021},{"style":280},[1022],{"type":71,"value":1023},"user",{"type":66,"tag":216,"props":1025,"children":1026},{"style":223},[1027],{"type":71,"value":92},{"type":66,"tag":216,"props":1029,"children":1030},{"style":280},[1031],{"type":71,"value":477},{"type":66,"tag":216,"props":1033,"children":1034},{"style":229},[1035],{"type":71,"value":577},{"type":66,"tag":216,"props":1037,"children":1038},{"style":223},[1039],{"type":71,"value":449},{"type":66,"tag":216,"props":1041,"children":1042},{"class":218,"line":385},[1043],{"type":66,"tag":216,"props":1044,"children":1046},{"style":1045},"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[1047],{"type":71,"value":1048}," // Redirect to protected page\n",{"type":66,"tag":216,"props":1050,"children":1051},{"class":218,"line":452},[1052,1057,1062,1066,1070,1075,1079],{"type":66,"tag":216,"props":1053,"children":1054},{"style":414},[1055],{"type":71,"value":1056}," return",{"type":66,"tag":216,"props":1058,"children":1059},{"style":290},[1060],{"type":71,"value":1061}," navigateTo",{"type":66,"tag":216,"props":1063,"children":1064},{"style":229},[1065],{"type":71,"value":325},{"type":66,"tag":216,"props":1067,"children":1068},{"style":223},[1069],{"type":71,"value":527},{"type":66,"tag":216,"props":1071,"children":1072},{"style":256},[1073],{"type":71,"value":1074},"/",{"type":66,"tag":216,"props":1076,"children":1077},{"style":223},[1078],{"type":71,"value":527},{"type":66,"tag":216,"props":1080,"children":1081},{"style":229},[1082],{"type":71,"value":335},{"type":66,"tag":216,"props":1084,"children":1085},{"class":218,"line":485},[1086],{"type":66,"tag":216,"props":1087,"children":1088},{"style":223},[1089],{"type":71,"value":1090}," }\n",{"type":66,"tag":216,"props":1092,"children":1093},{"class":218,"line":502},[1094,1099,1103,1108,1112,1118,1122],{"type":66,"tag":216,"props":1095,"children":1096},{"style":223},[1097],{"type":71,"value":1098},"},",{"type":66,"tag":216,"props":1100,"children":1101},{"style":223},[1102],{"type":71,"value":396},{"type":66,"tag":216,"props":1104,"children":1105},{"style":229},[1106],{"type":71,"value":1107}," immediate",{"type":66,"tag":216,"props":1109,"children":1110},{"style":223},[1111],{"type":71,"value":463},{"type":66,"tag":216,"props":1113,"children":1115},{"style":1114},"--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC",[1116],{"type":71,"value":1117}," true",{"type":66,"tag":216,"props":1119,"children":1120},{"style":223},[1121],{"type":71,"value":406},{"type":66,"tag":216,"props":1123,"children":1124},{"style":280},[1125],{"type":71,"value":335},{"type":66,"tag":216,"props":1127,"children":1128},{"class":218,"line":534},[1129,1133,1137],{"type":66,"tag":216,"props":1130,"children":1131},{"style":223},[1132],{"type":71,"value":621},{"type":66,"tag":216,"props":1134,"children":1135},{"style":229},[1136],{"type":71,"value":232},{"type":66,"tag":216,"props":1138,"children":1139},{"style":223},[1140],{"type":71,"value":268},{"type":66,"tag":216,"props":1142,"children":1143},{"class":218,"line":543},[1144],{"type":66,"tag":216,"props":1145,"children":1146},{"emptyLinePlaceholder":342},[1147],{"type":71,"value":345},{"type":66,"tag":216,"props":1149,"children":1150},{"class":218,"line":556},[1151,1155,1159],{"type":66,"tag":216,"props":1152,"children":1153},{"style":223},[1154],{"type":71,"value":226},{"type":66,"tag":216,"props":1156,"children":1157},{"style":229},[1158],{"type":71,"value":642},{"type":66,"tag":216,"props":1160,"children":1161},{"style":223},[1162],{"type":71,"value":268},{"type":66,"tag":216,"props":1164,"children":1165},{"class":218,"line":606},[1166,1170,1174,1179,1184,1188,1192],{"type":66,"tag":216,"props":1167,"children":1168},{"style":223},[1169],{"type":71,"value":655},{"type":66,"tag":216,"props":1171,"children":1172},{"style":229},[1173],{"type":71,"value":660},{"type":66,"tag":216,"props":1175,"children":1176},{"style":223},[1177],{"type":71,"value":1178},">",{"type":66,"tag":216,"props":1180,"children":1181},{"style":280},[1182],{"type":71,"value":1183},"Waiting for login...",{"type":66,"tag":216,"props":1185,"children":1186},{"style":223},[1187],{"type":71,"value":621},{"type":66,"tag":216,"props":1189,"children":1190},{"style":229},[1191],{"type":71,"value":660},{"type":66,"tag":216,"props":1193,"children":1194},{"style":223},[1195],{"type":71,"value":268},{"type":66,"tag":216,"props":1197,"children":1198},{"class":218,"line":615},[1199,1203,1207],{"type":66,"tag":216,"props":1200,"children":1201},{"style":223},[1202],{"type":71,"value":621},{"type":66,"tag":216,"props":1204,"children":1205},{"style":229},[1206],{"type":71,"value":642},{"type":66,"tag":216,"props":1208,"children":1209},{"style":223},[1210],{"type":71,"value":268},{"type":66,"tag":1212,"props":1213,"children":1215},"h3",{"id":1214},"redirect-path",[1216],{"type":71,"value":1217},"Redirect path",{"type":66,"tag":67,"props":1219,"children":1220},{},[1221],{"type":71,"value":1222},"You can easily handle redirection to the initial requested route after login.",{"type":66,"tag":124,"props":1224,"children":1225},{"icon":126},[1226],{"type":66,"tag":67,"props":1227,"children":1228},{},[1229,1231,1237,1239,1244],{"type":71,"value":1230},"You must enable the ",{"type":66,"tag":99,"props":1232,"children":1234},{"className":1233},[],[1235],{"type":71,"value":1236},"cookieRedirect",{"type":71,"value":1238}," option of the ",{"type":66,"tag":74,"props":1240,"children":1241},{"href":160},[1242],{"type":71,"value":1243},"redirectOptions",{"type":71,"value":1245}," to allow cookie storage and take benefit of this feature.",{"type":66,"tag":205,"props":1247,"children":1249},{"className":207,"code":1248,"filename":902,"language":210,"meta":59,"style":59},"\u003Cscript setup lang=\"ts\">\nconst user = useSupabaseUser()\n\n// Get redirect path from cookies\nconst cookieName = useRuntimeConfig().public.supabase.cookieName\nconst redirectPath = useCookie(`${cookieName}-redirect-path`).value\n\nwatch(user, () => {\n if (user.value) {\n // Clear cookie\n useCookie(`${cookieName}-redirect-path`).value = null\n // Redirect to path\n return navigateTo(redirectPath || '/'); \n }\n}, { immediate: true })\n\u003C/script>\n\u003Ctemplate>\n \u003Cdiv>Waiting for login...\u003C/div>\n\u003C/template>\n",[1250],{"type":66,"tag":99,"props":1251,"children":1252},{"__ignoreMap":59},[1253,1292,1315,1322,1330,1383,1447,1454,1481,1512,1520,1573,1581,1632,1639,1670,1685,1700,1731],{"type":66,"tag":216,"props":1254,"children":1255},{"class":218,"line":219},[1256,1260,1264,1268,1272,1276,1280,1284,1288],{"type":66,"tag":216,"props":1257,"children":1258},{"style":223},[1259],{"type":71,"value":226},{"type":66,"tag":216,"props":1261,"children":1262},{"style":229},[1263],{"type":71,"value":232},{"type":66,"tag":216,"props":1265,"children":1266},{"style":235},[1267],{"type":71,"value":238},{"type":66,"tag":216,"props":1269,"children":1270},{"style":235},[1271],{"type":71,"value":243},{"type":66,"tag":216,"props":1273,"children":1274},{"style":223},[1275],{"type":71,"value":248},{"type":66,"tag":216,"props":1277,"children":1278},{"style":223},[1279],{"type":71,"value":253},{"type":66,"tag":216,"props":1281,"children":1282},{"style":256},[1283],{"type":71,"value":259},{"type":66,"tag":216,"props":1285,"children":1286},{"style":223},[1287],{"type":71,"value":253},{"type":66,"tag":216,"props":1289,"children":1290},{"style":223},[1291],{"type":71,"value":268},{"type":66,"tag":216,"props":1293,"children":1294},{"class":218,"line":271},[1295,1299,1303,1307,1311],{"type":66,"tag":216,"props":1296,"children":1297},{"style":235},[1298],{"type":71,"value":277},{"type":66,"tag":216,"props":1300,"children":1301},{"style":280},[1302],{"type":71,"value":957},{"type":66,"tag":216,"props":1304,"children":1305},{"style":223},[1306],{"type":71,"value":248},{"type":66,"tag":216,"props":1308,"children":1309},{"style":290},[1310],{"type":71,"value":966},{"type":66,"tag":216,"props":1312,"children":1313},{"style":280},[1314],{"type":71,"value":298},{"type":66,"tag":216,"props":1316,"children":1317},{"class":218,"line":301},[1318],{"type":66,"tag":216,"props":1319,"children":1320},{"emptyLinePlaceholder":342},[1321],{"type":71,"value":345},{"type":66,"tag":216,"props":1323,"children":1324},{"class":218,"line":338},[1325],{"type":66,"tag":216,"props":1326,"children":1327},{"style":1045},[1328],{"type":71,"value":1329},"// Get redirect path from cookies\n",{"type":66,"tag":216,"props":1331,"children":1332},{"class":218,"line":348},[1333,1337,1342,1346,1351,1356,1360,1365,1369,1374,1378],{"type":66,"tag":216,"props":1334,"children":1335},{"style":235},[1336],{"type":71,"value":277},{"type":66,"tag":216,"props":1338,"children":1339},{"style":280},[1340],{"type":71,"value":1341}," cookieName ",{"type":66,"tag":216,"props":1343,"children":1344},{"style":223},[1345],{"type":71,"value":248},{"type":66,"tag":216,"props":1347,"children":1348},{"style":290},[1349],{"type":71,"value":1350}," useRuntimeConfig",{"type":66,"tag":216,"props":1352,"children":1353},{"style":280},[1354],{"type":71,"value":1355},"()",{"type":66,"tag":216,"props":1357,"children":1358},{"style":223},[1359],{"type":71,"value":92},{"type":66,"tag":216,"props":1361,"children":1362},{"style":280},[1363],{"type":71,"value":1364},"public",{"type":66,"tag":216,"props":1366,"children":1367},{"style":223},[1368],{"type":71,"value":92},{"type":66,"tag":216,"props":1370,"children":1371},{"style":280},[1372],{"type":71,"value":1373},"supabase",{"type":66,"tag":216,"props":1375,"children":1376},{"style":223},[1377],{"type":71,"value":92},{"type":66,"tag":216,"props":1379,"children":1380},{"style":280},[1381],{"type":71,"value":1382},"cookieName\n",{"type":66,"tag":216,"props":1384,"children":1385},{"class":218,"line":385},[1386,1390,1395,1399,1404,1408,1413,1418,1423,1428,1433,1438,1442],{"type":66,"tag":216,"props":1387,"children":1388},{"style":235},[1389],{"type":71,"value":277},{"type":66,"tag":216,"props":1391,"children":1392},{"style":280},[1393],{"type":71,"value":1394}," redirectPath ",{"type":66,"tag":216,"props":1396,"children":1397},{"style":223},[1398],{"type":71,"value":248},{"type":66,"tag":216,"props":1400,"children":1401},{"style":290},[1402],{"type":71,"value":1403}," useCookie",{"type":66,"tag":216,"props":1405,"children":1406},{"style":280},[1407],{"type":71,"value":325},{"type":66,"tag":216,"props":1409,"children":1410},{"style":223},[1411],{"type":71,"value":1412},"`${",{"type":66,"tag":216,"props":1414,"children":1415},{"style":280},[1416],{"type":71,"value":1417},"cookieName",{"type":66,"tag":216,"props":1419,"children":1420},{"style":223},[1421],{"type":71,"value":1422},"}",{"type":66,"tag":216,"props":1424,"children":1425},{"style":256},[1426],{"type":71,"value":1427},"-redirect-path",{"type":66,"tag":216,"props":1429,"children":1430},{"style":223},[1431],{"type":71,"value":1432},"`",{"type":66,"tag":216,"props":1434,"children":1435},{"style":280},[1436],{"type":71,"value":1437},")",{"type":66,"tag":216,"props":1439,"children":1440},{"style":223},[1441],{"type":71,"value":92},{"type":66,"tag":216,"props":1443,"children":1444},{"style":280},[1445],{"type":71,"value":1446},"value\n",{"type":66,"tag":216,"props":1448,"children":1449},{"class":218,"line":452},[1450],{"type":66,"tag":216,"props":1451,"children":1452},{"emptyLinePlaceholder":342},[1453],{"type":71,"value":345},{"type":66,"tag":216,"props":1455,"children":1456},{"class":218,"line":485},[1457,1461,1465,1469,1473,1477],{"type":66,"tag":216,"props":1458,"children":1459},{"style":290},[1460],{"type":71,"value":985},{"type":66,"tag":216,"props":1462,"children":1463},{"style":280},[1464],{"type":71,"value":990},{"type":66,"tag":216,"props":1466,"children":1467},{"style":223},[1468],{"type":71,"value":995},{"type":66,"tag":216,"props":1470,"children":1471},{"style":223},[1472],{"type":71,"value":372},{"type":66,"tag":216,"props":1474,"children":1475},{"style":235},[1476],{"type":71,"value":377},{"type":66,"tag":216,"props":1478,"children":1479},{"style":223},[1480],{"type":71,"value":382},{"type":66,"tag":216,"props":1482,"children":1483},{"class":218,"line":502},[1484,1488,1492,1496,1500,1504,1508],{"type":66,"tag":216,"props":1485,"children":1486},{"style":414},[1487],{"type":71,"value":562},{"type":66,"tag":216,"props":1489,"children":1490},{"style":229},[1491],{"type":71,"value":567},{"type":66,"tag":216,"props":1493,"children":1494},{"style":280},[1495],{"type":71,"value":1023},{"type":66,"tag":216,"props":1497,"children":1498},{"style":223},[1499],{"type":71,"value":92},{"type":66,"tag":216,"props":1501,"children":1502},{"style":280},[1503],{"type":71,"value":477},{"type":66,"tag":216,"props":1505,"children":1506},{"style":229},[1507],{"type":71,"value":577},{"type":66,"tag":216,"props":1509,"children":1510},{"style":223},[1511],{"type":71,"value":449},{"type":66,"tag":216,"props":1513,"children":1514},{"class":218,"line":534},[1515],{"type":66,"tag":216,"props":1516,"children":1517},{"style":1045},[1518],{"type":71,"value":1519}," // Clear cookie\n",{"type":66,"tag":216,"props":1521,"children":1522},{"class":218,"line":543},[1523,1528,1532,1536,1540,1544,1548,1552,1556,1560,1564,1568],{"type":66,"tag":216,"props":1524,"children":1525},{"style":290},[1526],{"type":71,"value":1527}," useCookie",{"type":66,"tag":216,"props":1529,"children":1530},{"style":229},[1531],{"type":71,"value":325},{"type":66,"tag":216,"props":1533,"children":1534},{"style":223},[1535],{"type":71,"value":1412},{"type":66,"tag":216,"props":1537,"children":1538},{"style":280},[1539],{"type":71,"value":1417},{"type":66,"tag":216,"props":1541,"children":1542},{"style":223},[1543],{"type":71,"value":1422},{"type":66,"tag":216,"props":1545,"children":1546},{"style":256},[1547],{"type":71,"value":1427},{"type":66,"tag":216,"props":1549,"children":1550},{"style":223},[1551],{"type":71,"value":1432},{"type":66,"tag":216,"props":1553,"children":1554},{"style":229},[1555],{"type":71,"value":1437},{"type":66,"tag":216,"props":1557,"children":1558},{"style":223},[1559],{"type":71,"value":92},{"type":66,"tag":216,"props":1561,"children":1562},{"style":280},[1563],{"type":71,"value":477},{"type":66,"tag":216,"props":1565,"children":1566},{"style":223},[1567],{"type":71,"value":411},{"type":66,"tag":216,"props":1569,"children":1570},{"style":223},[1571],{"type":71,"value":1572}," null\n",{"type":66,"tag":216,"props":1574,"children":1575},{"class":218,"line":556},[1576],{"type":66,"tag":216,"props":1577,"children":1578},{"style":1045},[1579],{"type":71,"value":1580}," // Redirect to path\n",{"type":66,"tag":216,"props":1582,"children":1583},{"class":218,"line":606},[1584,1588,1592,1596,1601,1606,1610,1614,1618,1622,1627],{"type":66,"tag":216,"props":1585,"children":1586},{"style":414},[1587],{"type":71,"value":1056},{"type":66,"tag":216,"props":1589,"children":1590},{"style":290},[1591],{"type":71,"value":1061},{"type":66,"tag":216,"props":1593,"children":1594},{"style":229},[1595],{"type":71,"value":325},{"type":66,"tag":216,"props":1597,"children":1598},{"style":280},[1599],{"type":71,"value":1600},"redirectPath",{"type":66,"tag":216,"props":1602,"children":1603},{"style":223},[1604],{"type":71,"value":1605}," ||",{"type":66,"tag":216,"props":1607,"children":1608},{"style":223},[1609],{"type":71,"value":517},{"type":66,"tag":216,"props":1611,"children":1612},{"style":256},[1613],{"type":71,"value":1074},{"type":66,"tag":216,"props":1615,"children":1616},{"style":223},[1617],{"type":71,"value":527},{"type":66,"tag":216,"props":1619,"children":1620},{"style":229},[1621],{"type":71,"value":1437},{"type":66,"tag":216,"props":1623,"children":1624},{"style":223},[1625],{"type":71,"value":1626},";",{"type":66,"tag":216,"props":1628,"children":1629},{"style":229},[1630],{"type":71,"value":1631}," \n",{"type":66,"tag":216,"props":1633,"children":1634},{"class":218,"line":615},[1635],{"type":66,"tag":216,"props":1636,"children":1637},{"style":223},[1638],{"type":71,"value":1090},{"type":66,"tag":216,"props":1640,"children":1641},{"class":218,"line":632},[1642,1646,1650,1654,1658,1662,1666],{"type":66,"tag":216,"props":1643,"children":1644},{"style":223},[1645],{"type":71,"value":1098},{"type":66,"tag":216,"props":1647,"children":1648},{"style":223},[1649],{"type":71,"value":396},{"type":66,"tag":216,"props":1651,"children":1652},{"style":229},[1653],{"type":71,"value":1107},{"type":66,"tag":216,"props":1655,"children":1656},{"style":223},[1657],{"type":71,"value":463},{"type":66,"tag":216,"props":1659,"children":1660},{"style":1114},[1661],{"type":71,"value":1117},{"type":66,"tag":216,"props":1663,"children":1664},{"style":223},[1665],{"type":71,"value":406},{"type":66,"tag":216,"props":1667,"children":1668},{"style":280},[1669],{"type":71,"value":335},{"type":66,"tag":216,"props":1671,"children":1672},{"class":218,"line":649},[1673,1677,1681],{"type":66,"tag":216,"props":1674,"children":1675},{"style":223},[1676],{"type":71,"value":621},{"type":66,"tag":216,"props":1678,"children":1679},{"style":229},[1680],{"type":71,"value":232},{"type":66,"tag":216,"props":1682,"children":1683},{"style":223},[1684],{"type":71,"value":268},{"type":66,"tag":216,"props":1686,"children":1687},{"class":218,"line":667},[1688,1692,1696],{"type":66,"tag":216,"props":1689,"children":1690},{"style":223},[1691],{"type":71,"value":226},{"type":66,"tag":216,"props":1693,"children":1694},{"style":229},[1695],{"type":71,"value":642},{"type":66,"tag":216,"props":1697,"children":1698},{"style":223},[1699],{"type":71,"value":268},{"type":66,"tag":216,"props":1701,"children":1702},{"class":218,"line":711},[1703,1707,1711,1715,1719,1723,1727],{"type":66,"tag":216,"props":1704,"children":1705},{"style":223},[1706],{"type":71,"value":655},{"type":66,"tag":216,"props":1708,"children":1709},{"style":229},[1710],{"type":71,"value":660},{"type":66,"tag":216,"props":1712,"children":1713},{"style":223},[1714],{"type":71,"value":1178},{"type":66,"tag":216,"props":1716,"children":1717},{"style":280},[1718],{"type":71,"value":1183},{"type":66,"tag":216,"props":1720,"children":1721},{"style":223},[1722],{"type":71,"value":621},{"type":66,"tag":216,"props":1724,"children":1725},{"style":229},[1726],{"type":71,"value":660},{"type":66,"tag":216,"props":1728,"children":1729},{"style":223},[1730],{"type":71,"value":268},{"type":66,"tag":216,"props":1732,"children":1733},{"class":218,"line":720},[1734,1738,1742],{"type":66,"tag":216,"props":1735,"children":1736},{"style":223},[1737],{"type":71,"value":621},{"type":66,"tag":216,"props":1739,"children":1740},{"style":229},[1741],{"type":71,"value":642},{"type":66,"tag":216,"props":1743,"children":1744},{"style":223},[1745],{"type":71,"value":268},{"type":66,"tag":1747,"props":1748,"children":1749},"style",{},[1750],{"type":71,"value":1751},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":59,"searchDepth":271,"depth":271,"links":1753},[1754,1756],{"id":143,"depth":271,"text":1755},"Log-in page - /login",{"id":870,"depth":271,"text":1757,"children":1758},"Confirm page - /confirm",[1759],{"id":1214,"depth":301,"text":1217},"markdown","content:3.authentication.md","content","3.authentication.md","3.authentication","md",[1767,1769],{"_path":6,"title":5,"description":1768},"@nuxtjs/supabase is a Nuxt module for first class integration with Supabase.",{"_path":22,"title":21,"description":1770},"Make requests to the Supabase API with the useSupabaseClient composable",1724940862200] \ No newline at end of file +[{"data":1,"prerenderedAt":1771},["ShallowReactive",2],{"navigation":3,"/authentication":58,"/authentication-surround":1766},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":10,"_dir":59,"_draft":60,"_partial":60,"_locale":59,"title":9,"description":61,"icon":11,"body":62,"_type":1760,"_id":1761,"_source":1762,"_file":1763,"_stem":1764,"_extension":1765},"",false,"Authenticate your user thanks to the PKCE Oauth protocol that enables secure exchange of refresh and access tokens between an application and the authorization server",{"type":63,"children":64,"toc":1752},"root",[65,93,123,140,153,173,190,204,842,868,879,884,899,1211,1218,1223,1246,1746],{"type":66,"tag":67,"props":68,"children":69},"element","p",{},[70,73,82,84,91],{"type":71,"value":72},"text","With the default options, the module requires a log-in page and a confirm page to handle the ",{"type":66,"tag":74,"props":75,"children":79},"a",{"href":76,"rel":77},"https://supabase.com/docs/guides/resources/glossary#pkce",[78],"nofollow",[80],{"type":71,"value":81},"PKCE authorization code flow",{"type":71,"value":83},". If you want to understand how it works under the hood, you can read this ",{"type":66,"tag":74,"props":85,"children":88},{"href":86,"rel":87},"https://supabase.com/docs/guides/auth/server-side-rendering#understanding-the-authentication-flow",[78],[89],{"type":71,"value":90},"section",{"type":71,"value":92},".",{"type":66,"tag":67,"props":94,"children":95},{},[96,98,105,107,113,115,121],{"type":71,"value":97},"All you need to do is to create a ",{"type":66,"tag":99,"props":100,"children":102},"code",{"className":101},[],[103],{"type":71,"value":104},"login.vue",{"type":71,"value":106}," and ",{"type":66,"tag":99,"props":108,"children":110},{"className":109},[],[111],{"type":71,"value":112},"confirm.vue",{"type":71,"value":114}," page in the ",{"type":66,"tag":99,"props":116,"children":118},{"className":117},[],[119],{"type":71,"value":120},"pages",{"type":71,"value":122}," folder.",{"type":66,"tag":124,"props":125,"children":127},"callout",{"icon":126},"i-heroicons-light-bulb",[128],{"type":66,"tag":67,"props":129,"children":130},{},[131,133,139],{"type":71,"value":132},"For advanced users who want to implement the auth behaviour themselves, you can disable or override the ",{"type":66,"tag":74,"props":134,"children":136},{"href":135},"/get-started#redirect",[137],{"type":71,"value":138},"redirect options",{"type":71,"value":92},{"type":66,"tag":141,"props":142,"children":144},"h2",{"id":143},"log-in-page-login",[145,147],{"type":71,"value":146},"Log-in page - ",{"type":66,"tag":99,"props":148,"children":150},{"className":149},[],[151],{"type":71,"value":152},"/login",{"type":66,"tag":67,"props":154,"children":155},{},[156,158,164,166,171],{"type":71,"value":157},"Each time a user is trying to access a page that needs authentication, he will automatically be redirected to the configured log in page. If you want to allow access to \"public\" page, you just need to add them in the ",{"type":66,"tag":74,"props":159,"children":161},{"href":160},"/get-started#redirectoptions",[162],{"type":71,"value":163},"exclude",{"type":71,"value":165}," redirect option. Alternatively, you can enable the redirect only for certain routes using the ",{"type":66,"tag":74,"props":167,"children":168},{"href":160},[169],{"type":71,"value":170},"include",{"type":71,"value":172}," redirect option.",{"type":66,"tag":124,"props":174,"children":177},{"icon":175,"color":176},"i-heroicons-exclamation-triangle-20-solid","amber",[178],{"type":66,"tag":67,"props":179,"children":180},{},[181,183,189],{"type":71,"value":182},"Ensure to activate the authentication providers you want in the Supabase Dashboard under ",{"type":66,"tag":99,"props":184,"children":186},{"className":185},[],[187],{"type":71,"value":188},"Authentication -> Providers",{"type":71,"value":92},{"type":66,"tag":67,"props":191,"children":192},{},[193,195,202],{"type":71,"value":194},"The log-in page initiates the log-in method(s) you choose from the ",{"type":66,"tag":74,"props":196,"children":199},{"href":197,"rel":198},"https://supabase.com/docs/reference/javascript/auth-signinwithpassword",[78],[200],{"type":71,"value":201},"available authorization methods",{"type":71,"value":203}," provided by Supabase, it could looks like:",{"type":66,"tag":205,"props":206,"children":211},"pre",{"className":207,"code":208,"filename":209,"language":210,"meta":59,"style":59},"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","\u003Cscript setup lang=\"ts\">\nconst supabase = useSupabaseClient()\nconst email = ref('')\n\nconst signInWithOtp = async () => {\n const { error } = await supabase.auth.signInWithOtp({\n email: email.value,\n options: {\n emailRedirectTo: 'http://localhost:3000/confirm',\n }\n })\n if (error) console.log(error)\n}\n\u003C/script>\n\u003Ctemplate>\n \u003Cdiv>\n \u003Cbutton @click=\"signInWithOtp\">\n Sign In with E-Mail\n \u003C/button>\n \u003Cinput\n v-model=\"email\"\n type=\"email\"\n />\n \u003C/div>\n\u003C/template>\n","pages/login.vue","vue",[212],{"type":66,"tag":99,"props":213,"children":214},{"__ignoreMap":59},[215,269,299,336,346,383,450,483,500,532,541,554,604,613,630,647,665,709,718,735,748,775,800,809,826],{"type":66,"tag":216,"props":217,"children":220},"span",{"class":218,"line":219},"line",1,[221,227,233,239,244,249,254,260,264],{"type":66,"tag":216,"props":222,"children":224},{"style":223},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[225],{"type":71,"value":226},"\u003C",{"type":66,"tag":216,"props":228,"children":230},{"style":229},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[231],{"type":71,"value":232},"script",{"type":66,"tag":216,"props":234,"children":236},{"style":235},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[237],{"type":71,"value":238}," setup",{"type":66,"tag":216,"props":240,"children":241},{"style":235},[242],{"type":71,"value":243}," lang",{"type":66,"tag":216,"props":245,"children":246},{"style":223},[247],{"type":71,"value":248},"=",{"type":66,"tag":216,"props":250,"children":251},{"style":223},[252],{"type":71,"value":253},"\"",{"type":66,"tag":216,"props":255,"children":257},{"style":256},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[258],{"type":71,"value":259},"ts",{"type":66,"tag":216,"props":261,"children":262},{"style":223},[263],{"type":71,"value":253},{"type":66,"tag":216,"props":265,"children":266},{"style":223},[267],{"type":71,"value":268},">\n",{"type":66,"tag":216,"props":270,"children":272},{"class":218,"line":271},2,[273,278,284,288,294],{"type":66,"tag":216,"props":274,"children":275},{"style":235},[276],{"type":71,"value":277},"const",{"type":66,"tag":216,"props":279,"children":281},{"style":280},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[282],{"type":71,"value":283}," supabase ",{"type":66,"tag":216,"props":285,"children":286},{"style":223},[287],{"type":71,"value":248},{"type":66,"tag":216,"props":289,"children":291},{"style":290},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[292],{"type":71,"value":293}," useSupabaseClient",{"type":66,"tag":216,"props":295,"children":296},{"style":280},[297],{"type":71,"value":298},"()\n",{"type":66,"tag":216,"props":300,"children":302},{"class":218,"line":301},3,[303,307,312,316,321,326,331],{"type":66,"tag":216,"props":304,"children":305},{"style":235},[306],{"type":71,"value":277},{"type":66,"tag":216,"props":308,"children":309},{"style":280},[310],{"type":71,"value":311}," email ",{"type":66,"tag":216,"props":313,"children":314},{"style":223},[315],{"type":71,"value":248},{"type":66,"tag":216,"props":317,"children":318},{"style":290},[319],{"type":71,"value":320}," ref",{"type":66,"tag":216,"props":322,"children":323},{"style":280},[324],{"type":71,"value":325},"(",{"type":66,"tag":216,"props":327,"children":328},{"style":223},[329],{"type":71,"value":330},"''",{"type":66,"tag":216,"props":332,"children":333},{"style":280},[334],{"type":71,"value":335},")\n",{"type":66,"tag":216,"props":337,"children":339},{"class":218,"line":338},4,[340],{"type":66,"tag":216,"props":341,"children":343},{"emptyLinePlaceholder":342},true,[344],{"type":71,"value":345},"\n",{"type":66,"tag":216,"props":347,"children":349},{"class":218,"line":348},5,[350,354,359,363,368,373,378],{"type":66,"tag":216,"props":351,"children":352},{"style":235},[353],{"type":71,"value":277},{"type":66,"tag":216,"props":355,"children":356},{"style":280},[357],{"type":71,"value":358}," signInWithOtp ",{"type":66,"tag":216,"props":360,"children":361},{"style":223},[362],{"type":71,"value":248},{"type":66,"tag":216,"props":364,"children":365},{"style":235},[366],{"type":71,"value":367}," async",{"type":66,"tag":216,"props":369,"children":370},{"style":223},[371],{"type":71,"value":372}," ()",{"type":66,"tag":216,"props":374,"children":375},{"style":235},[376],{"type":71,"value":377}," =>",{"type":66,"tag":216,"props":379,"children":380},{"style":223},[381],{"type":71,"value":382}," {\n",{"type":66,"tag":216,"props":384,"children":386},{"class":218,"line":385},6,[387,392,397,402,407,412,418,423,427,432,436,441,445],{"type":66,"tag":216,"props":388,"children":389},{"style":235},[390],{"type":71,"value":391}," const",{"type":66,"tag":216,"props":393,"children":394},{"style":223},[395],{"type":71,"value":396}," {",{"type":66,"tag":216,"props":398,"children":399},{"style":280},[400],{"type":71,"value":401}," error",{"type":66,"tag":216,"props":403,"children":404},{"style":223},[405],{"type":71,"value":406}," }",{"type":66,"tag":216,"props":408,"children":409},{"style":223},[410],{"type":71,"value":411}," =",{"type":66,"tag":216,"props":413,"children":415},{"style":414},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[416],{"type":71,"value":417}," await",{"type":66,"tag":216,"props":419,"children":420},{"style":280},[421],{"type":71,"value":422}," supabase",{"type":66,"tag":216,"props":424,"children":425},{"style":223},[426],{"type":71,"value":92},{"type":66,"tag":216,"props":428,"children":429},{"style":280},[430],{"type":71,"value":431},"auth",{"type":66,"tag":216,"props":433,"children":434},{"style":223},[435],{"type":71,"value":92},{"type":66,"tag":216,"props":437,"children":438},{"style":290},[439],{"type":71,"value":440},"signInWithOtp",{"type":66,"tag":216,"props":442,"children":443},{"style":229},[444],{"type":71,"value":325},{"type":66,"tag":216,"props":446,"children":447},{"style":223},[448],{"type":71,"value":449},"{\n",{"type":66,"tag":216,"props":451,"children":453},{"class":218,"line":452},7,[454,459,464,469,473,478],{"type":66,"tag":216,"props":455,"children":456},{"style":229},[457],{"type":71,"value":458}," email",{"type":66,"tag":216,"props":460,"children":461},{"style":223},[462],{"type":71,"value":463},":",{"type":66,"tag":216,"props":465,"children":466},{"style":280},[467],{"type":71,"value":468}," email",{"type":66,"tag":216,"props":470,"children":471},{"style":223},[472],{"type":71,"value":92},{"type":66,"tag":216,"props":474,"children":475},{"style":280},[476],{"type":71,"value":477},"value",{"type":66,"tag":216,"props":479,"children":480},{"style":223},[481],{"type":71,"value":482},",\n",{"type":66,"tag":216,"props":484,"children":486},{"class":218,"line":485},8,[487,492,496],{"type":66,"tag":216,"props":488,"children":489},{"style":229},[490],{"type":71,"value":491}," options",{"type":66,"tag":216,"props":493,"children":494},{"style":223},[495],{"type":71,"value":463},{"type":66,"tag":216,"props":497,"children":498},{"style":223},[499],{"type":71,"value":382},{"type":66,"tag":216,"props":501,"children":503},{"class":218,"line":502},9,[504,509,513,518,523,528],{"type":66,"tag":216,"props":505,"children":506},{"style":229},[507],{"type":71,"value":508}," emailRedirectTo",{"type":66,"tag":216,"props":510,"children":511},{"style":223},[512],{"type":71,"value":463},{"type":66,"tag":216,"props":514,"children":515},{"style":223},[516],{"type":71,"value":517}," '",{"type":66,"tag":216,"props":519,"children":520},{"style":256},[521],{"type":71,"value":522},"http://localhost:3000/confirm",{"type":66,"tag":216,"props":524,"children":525},{"style":223},[526],{"type":71,"value":527},"'",{"type":66,"tag":216,"props":529,"children":530},{"style":223},[531],{"type":71,"value":482},{"type":66,"tag":216,"props":533,"children":535},{"class":218,"line":534},10,[536],{"type":66,"tag":216,"props":537,"children":538},{"style":223},[539],{"type":71,"value":540}," }\n",{"type":66,"tag":216,"props":542,"children":544},{"class":218,"line":543},11,[545,550],{"type":66,"tag":216,"props":546,"children":547},{"style":223},[548],{"type":71,"value":549}," }",{"type":66,"tag":216,"props":551,"children":552},{"style":229},[553],{"type":71,"value":335},{"type":66,"tag":216,"props":555,"children":557},{"class":218,"line":556},12,[558,563,568,573,578,583,587,592,596,600],{"type":66,"tag":216,"props":559,"children":560},{"style":414},[561],{"type":71,"value":562}," if",{"type":66,"tag":216,"props":564,"children":565},{"style":229},[566],{"type":71,"value":567}," (",{"type":66,"tag":216,"props":569,"children":570},{"style":280},[571],{"type":71,"value":572},"error",{"type":66,"tag":216,"props":574,"children":575},{"style":229},[576],{"type":71,"value":577},") ",{"type":66,"tag":216,"props":579,"children":580},{"style":280},[581],{"type":71,"value":582},"console",{"type":66,"tag":216,"props":584,"children":585},{"style":223},[586],{"type":71,"value":92},{"type":66,"tag":216,"props":588,"children":589},{"style":290},[590],{"type":71,"value":591},"log",{"type":66,"tag":216,"props":593,"children":594},{"style":229},[595],{"type":71,"value":325},{"type":66,"tag":216,"props":597,"children":598},{"style":280},[599],{"type":71,"value":572},{"type":66,"tag":216,"props":601,"children":602},{"style":229},[603],{"type":71,"value":335},{"type":66,"tag":216,"props":605,"children":607},{"class":218,"line":606},13,[608],{"type":66,"tag":216,"props":609,"children":610},{"style":223},[611],{"type":71,"value":612},"}\n",{"type":66,"tag":216,"props":614,"children":616},{"class":218,"line":615},14,[617,622,626],{"type":66,"tag":216,"props":618,"children":619},{"style":223},[620],{"type":71,"value":621},"\u003C/",{"type":66,"tag":216,"props":623,"children":624},{"style":229},[625],{"type":71,"value":232},{"type":66,"tag":216,"props":627,"children":628},{"style":223},[629],{"type":71,"value":268},{"type":66,"tag":216,"props":631,"children":633},{"class":218,"line":632},15,[634,638,643],{"type":66,"tag":216,"props":635,"children":636},{"style":223},[637],{"type":71,"value":226},{"type":66,"tag":216,"props":639,"children":640},{"style":229},[641],{"type":71,"value":642},"template",{"type":66,"tag":216,"props":644,"children":645},{"style":223},[646],{"type":71,"value":268},{"type":66,"tag":216,"props":648,"children":650},{"class":218,"line":649},16,[651,656,661],{"type":66,"tag":216,"props":652,"children":653},{"style":223},[654],{"type":71,"value":655}," \u003C",{"type":66,"tag":216,"props":657,"children":658},{"style":229},[659],{"type":71,"value":660},"div",{"type":66,"tag":216,"props":662,"children":663},{"style":223},[664],{"type":71,"value":268},{"type":66,"tag":216,"props":666,"children":668},{"class":218,"line":667},17,[669,674,679,684,689,693,697,701,705],{"type":66,"tag":216,"props":670,"children":671},{"style":223},[672],{"type":71,"value":673}," \u003C",{"type":66,"tag":216,"props":675,"children":676},{"style":229},[677],{"type":71,"value":678},"button",{"type":66,"tag":216,"props":680,"children":681},{"style":223},[682],{"type":71,"value":683}," @",{"type":66,"tag":216,"props":685,"children":686},{"style":235},[687],{"type":71,"value":688},"click",{"type":66,"tag":216,"props":690,"children":691},{"style":223},[692],{"type":71,"value":248},{"type":66,"tag":216,"props":694,"children":695},{"style":223},[696],{"type":71,"value":253},{"type":66,"tag":216,"props":698,"children":699},{"style":280},[700],{"type":71,"value":440},{"type":66,"tag":216,"props":702,"children":703},{"style":223},[704],{"type":71,"value":253},{"type":66,"tag":216,"props":706,"children":707},{"style":223},[708],{"type":71,"value":268},{"type":66,"tag":216,"props":710,"children":712},{"class":218,"line":711},18,[713],{"type":66,"tag":216,"props":714,"children":715},{"style":280},[716],{"type":71,"value":717}," Sign In with E-Mail\n",{"type":66,"tag":216,"props":719,"children":721},{"class":218,"line":720},19,[722,727,731],{"type":66,"tag":216,"props":723,"children":724},{"style":223},[725],{"type":71,"value":726}," \u003C/",{"type":66,"tag":216,"props":728,"children":729},{"style":229},[730],{"type":71,"value":678},{"type":66,"tag":216,"props":732,"children":733},{"style":223},[734],{"type":71,"value":268},{"type":66,"tag":216,"props":736,"children":738},{"class":218,"line":737},20,[739,743],{"type":66,"tag":216,"props":740,"children":741},{"style":223},[742],{"type":71,"value":673},{"type":66,"tag":216,"props":744,"children":745},{"style":229},[746],{"type":71,"value":747},"input\n",{"type":66,"tag":216,"props":749,"children":751},{"class":218,"line":750},21,[752,757,761,765,770],{"type":66,"tag":216,"props":753,"children":754},{"style":235},[755],{"type":71,"value":756}," v-model",{"type":66,"tag":216,"props":758,"children":759},{"style":223},[760],{"type":71,"value":248},{"type":66,"tag":216,"props":762,"children":763},{"style":223},[764],{"type":71,"value":253},{"type":66,"tag":216,"props":766,"children":767},{"style":280},[768],{"type":71,"value":769},"email",{"type":66,"tag":216,"props":771,"children":772},{"style":223},[773],{"type":71,"value":774},"\"\n",{"type":66,"tag":216,"props":776,"children":778},{"class":218,"line":777},22,[779,784,788,792,796],{"type":66,"tag":216,"props":780,"children":781},{"style":235},[782],{"type":71,"value":783}," type",{"type":66,"tag":216,"props":785,"children":786},{"style":223},[787],{"type":71,"value":248},{"type":66,"tag":216,"props":789,"children":790},{"style":223},[791],{"type":71,"value":253},{"type":66,"tag":216,"props":793,"children":794},{"style":256},[795],{"type":71,"value":769},{"type":66,"tag":216,"props":797,"children":798},{"style":223},[799],{"type":71,"value":774},{"type":66,"tag":216,"props":801,"children":803},{"class":218,"line":802},23,[804],{"type":66,"tag":216,"props":805,"children":806},{"style":223},[807],{"type":71,"value":808}," />\n",{"type":66,"tag":216,"props":810,"children":812},{"class":218,"line":811},24,[813,818,822],{"type":66,"tag":216,"props":814,"children":815},{"style":223},[816],{"type":71,"value":817}," \u003C/",{"type":66,"tag":216,"props":819,"children":820},{"style":229},[821],{"type":71,"value":660},{"type":66,"tag":216,"props":823,"children":824},{"style":223},[825],{"type":71,"value":268},{"type":66,"tag":216,"props":827,"children":829},{"class":218,"line":828},25,[830,834,838],{"type":66,"tag":216,"props":831,"children":832},{"style":223},[833],{"type":71,"value":621},{"type":66,"tag":216,"props":835,"children":836},{"style":229},[837],{"type":71,"value":642},{"type":66,"tag":216,"props":839,"children":840},{"style":223},[841],{"type":71,"value":268},{"type":66,"tag":67,"props":843,"children":844},{},[845,847,852,854,858,860,866],{"type":71,"value":846},"Once the authorization flow is triggered using the ",{"type":66,"tag":99,"props":848,"children":850},{"className":849},[],[851],{"type":71,"value":431},{"type":71,"value":853}," wrapper of the ",{"type":66,"tag":74,"props":855,"children":856},{"href":22},[857],{"type":71,"value":21},{"type":71,"value":859}," composable, the session management is handled automatically and the user will be redirected to the page you specify in the redirect option (",{"type":66,"tag":99,"props":861,"children":863},{"className":862},[],[864],{"type":71,"value":865},"/confirm",{"type":71,"value":867}," by default).",{"type":66,"tag":141,"props":869,"children":871},{"id":870},"confirm-page-confirm",[872,874],{"type":71,"value":873},"Confirm page - ",{"type":66,"tag":99,"props":875,"children":877},{"className":876},[],[878],{"type":71,"value":865},{"type":66,"tag":67,"props":880,"children":881},{},[882],{"type":71,"value":883},"The confirmation page receives the supabase callback. From there you can check the user value and redirect to the appropriate page.",{"type":66,"tag":124,"props":885,"children":886},{"icon":126},[887],{"type":66,"tag":67,"props":888,"children":889},{},[890,892,898],{"type":71,"value":891},"The redirect URL must be configured in your Supabase dashboard under ",{"type":66,"tag":99,"props":893,"children":895},{"className":894},[],[896],{"type":71,"value":897},"Authentication -> URL Configuration -> Redirect URLs",{"type":71,"value":92},{"type":66,"tag":205,"props":900,"children":903},{"className":207,"code":901,"filename":902,"language":210,"meta":59,"style":59},"\u003Cscript setup lang=\"ts\">\nconst user = useSupabaseUser()\n\nwatch(user, () => {\n if (user.value) {\n // Redirect to protected page\n return navigateTo('/')\n }\n}, { immediate: true })\n\u003C/script>\n\n\u003Ctemplate>\n \u003Cdiv>Waiting for login...\u003C/div>\n\u003C/template>\n","pages/confirm.vue",[904],{"type":66,"tag":99,"props":905,"children":906},{"__ignoreMap":59},[907,946,971,978,1008,1040,1049,1083,1091,1126,1141,1148,1163,1196],{"type":66,"tag":216,"props":908,"children":909},{"class":218,"line":219},[910,914,918,922,926,930,934,938,942],{"type":66,"tag":216,"props":911,"children":912},{"style":223},[913],{"type":71,"value":226},{"type":66,"tag":216,"props":915,"children":916},{"style":229},[917],{"type":71,"value":232},{"type":66,"tag":216,"props":919,"children":920},{"style":235},[921],{"type":71,"value":238},{"type":66,"tag":216,"props":923,"children":924},{"style":235},[925],{"type":71,"value":243},{"type":66,"tag":216,"props":927,"children":928},{"style":223},[929],{"type":71,"value":248},{"type":66,"tag":216,"props":931,"children":932},{"style":223},[933],{"type":71,"value":253},{"type":66,"tag":216,"props":935,"children":936},{"style":256},[937],{"type":71,"value":259},{"type":66,"tag":216,"props":939,"children":940},{"style":223},[941],{"type":71,"value":253},{"type":66,"tag":216,"props":943,"children":944},{"style":223},[945],{"type":71,"value":268},{"type":66,"tag":216,"props":947,"children":948},{"class":218,"line":271},[949,953,958,962,967],{"type":66,"tag":216,"props":950,"children":951},{"style":235},[952],{"type":71,"value":277},{"type":66,"tag":216,"props":954,"children":955},{"style":280},[956],{"type":71,"value":957}," user ",{"type":66,"tag":216,"props":959,"children":960},{"style":223},[961],{"type":71,"value":248},{"type":66,"tag":216,"props":963,"children":964},{"style":290},[965],{"type":71,"value":966}," useSupabaseUser",{"type":66,"tag":216,"props":968,"children":969},{"style":280},[970],{"type":71,"value":298},{"type":66,"tag":216,"props":972,"children":973},{"class":218,"line":301},[974],{"type":66,"tag":216,"props":975,"children":976},{"emptyLinePlaceholder":342},[977],{"type":71,"value":345},{"type":66,"tag":216,"props":979,"children":980},{"class":218,"line":338},[981,986,991,996,1000,1004],{"type":66,"tag":216,"props":982,"children":983},{"style":290},[984],{"type":71,"value":985},"watch",{"type":66,"tag":216,"props":987,"children":988},{"style":280},[989],{"type":71,"value":990},"(user",{"type":66,"tag":216,"props":992,"children":993},{"style":223},[994],{"type":71,"value":995},",",{"type":66,"tag":216,"props":997,"children":998},{"style":223},[999],{"type":71,"value":372},{"type":66,"tag":216,"props":1001,"children":1002},{"style":235},[1003],{"type":71,"value":377},{"type":66,"tag":216,"props":1005,"children":1006},{"style":223},[1007],{"type":71,"value":382},{"type":66,"tag":216,"props":1009,"children":1010},{"class":218,"line":348},[1011,1015,1019,1024,1028,1032,1036],{"type":66,"tag":216,"props":1012,"children":1013},{"style":414},[1014],{"type":71,"value":562},{"type":66,"tag":216,"props":1016,"children":1017},{"style":229},[1018],{"type":71,"value":567},{"type":66,"tag":216,"props":1020,"children":1021},{"style":280},[1022],{"type":71,"value":1023},"user",{"type":66,"tag":216,"props":1025,"children":1026},{"style":223},[1027],{"type":71,"value":92},{"type":66,"tag":216,"props":1029,"children":1030},{"style":280},[1031],{"type":71,"value":477},{"type":66,"tag":216,"props":1033,"children":1034},{"style":229},[1035],{"type":71,"value":577},{"type":66,"tag":216,"props":1037,"children":1038},{"style":223},[1039],{"type":71,"value":449},{"type":66,"tag":216,"props":1041,"children":1042},{"class":218,"line":385},[1043],{"type":66,"tag":216,"props":1044,"children":1046},{"style":1045},"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[1047],{"type":71,"value":1048}," // Redirect to protected page\n",{"type":66,"tag":216,"props":1050,"children":1051},{"class":218,"line":452},[1052,1057,1062,1066,1070,1075,1079],{"type":66,"tag":216,"props":1053,"children":1054},{"style":414},[1055],{"type":71,"value":1056}," return",{"type":66,"tag":216,"props":1058,"children":1059},{"style":290},[1060],{"type":71,"value":1061}," navigateTo",{"type":66,"tag":216,"props":1063,"children":1064},{"style":229},[1065],{"type":71,"value":325},{"type":66,"tag":216,"props":1067,"children":1068},{"style":223},[1069],{"type":71,"value":527},{"type":66,"tag":216,"props":1071,"children":1072},{"style":256},[1073],{"type":71,"value":1074},"/",{"type":66,"tag":216,"props":1076,"children":1077},{"style":223},[1078],{"type":71,"value":527},{"type":66,"tag":216,"props":1080,"children":1081},{"style":229},[1082],{"type":71,"value":335},{"type":66,"tag":216,"props":1084,"children":1085},{"class":218,"line":485},[1086],{"type":66,"tag":216,"props":1087,"children":1088},{"style":223},[1089],{"type":71,"value":1090}," }\n",{"type":66,"tag":216,"props":1092,"children":1093},{"class":218,"line":502},[1094,1099,1103,1108,1112,1118,1122],{"type":66,"tag":216,"props":1095,"children":1096},{"style":223},[1097],{"type":71,"value":1098},"},",{"type":66,"tag":216,"props":1100,"children":1101},{"style":223},[1102],{"type":71,"value":396},{"type":66,"tag":216,"props":1104,"children":1105},{"style":229},[1106],{"type":71,"value":1107}," immediate",{"type":66,"tag":216,"props":1109,"children":1110},{"style":223},[1111],{"type":71,"value":463},{"type":66,"tag":216,"props":1113,"children":1115},{"style":1114},"--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC",[1116],{"type":71,"value":1117}," true",{"type":66,"tag":216,"props":1119,"children":1120},{"style":223},[1121],{"type":71,"value":406},{"type":66,"tag":216,"props":1123,"children":1124},{"style":280},[1125],{"type":71,"value":335},{"type":66,"tag":216,"props":1127,"children":1128},{"class":218,"line":534},[1129,1133,1137],{"type":66,"tag":216,"props":1130,"children":1131},{"style":223},[1132],{"type":71,"value":621},{"type":66,"tag":216,"props":1134,"children":1135},{"style":229},[1136],{"type":71,"value":232},{"type":66,"tag":216,"props":1138,"children":1139},{"style":223},[1140],{"type":71,"value":268},{"type":66,"tag":216,"props":1142,"children":1143},{"class":218,"line":543},[1144],{"type":66,"tag":216,"props":1145,"children":1146},{"emptyLinePlaceholder":342},[1147],{"type":71,"value":345},{"type":66,"tag":216,"props":1149,"children":1150},{"class":218,"line":556},[1151,1155,1159],{"type":66,"tag":216,"props":1152,"children":1153},{"style":223},[1154],{"type":71,"value":226},{"type":66,"tag":216,"props":1156,"children":1157},{"style":229},[1158],{"type":71,"value":642},{"type":66,"tag":216,"props":1160,"children":1161},{"style":223},[1162],{"type":71,"value":268},{"type":66,"tag":216,"props":1164,"children":1165},{"class":218,"line":606},[1166,1170,1174,1179,1184,1188,1192],{"type":66,"tag":216,"props":1167,"children":1168},{"style":223},[1169],{"type":71,"value":655},{"type":66,"tag":216,"props":1171,"children":1172},{"style":229},[1173],{"type":71,"value":660},{"type":66,"tag":216,"props":1175,"children":1176},{"style":223},[1177],{"type":71,"value":1178},">",{"type":66,"tag":216,"props":1180,"children":1181},{"style":280},[1182],{"type":71,"value":1183},"Waiting for login...",{"type":66,"tag":216,"props":1185,"children":1186},{"style":223},[1187],{"type":71,"value":621},{"type":66,"tag":216,"props":1189,"children":1190},{"style":229},[1191],{"type":71,"value":660},{"type":66,"tag":216,"props":1193,"children":1194},{"style":223},[1195],{"type":71,"value":268},{"type":66,"tag":216,"props":1197,"children":1198},{"class":218,"line":615},[1199,1203,1207],{"type":66,"tag":216,"props":1200,"children":1201},{"style":223},[1202],{"type":71,"value":621},{"type":66,"tag":216,"props":1204,"children":1205},{"style":229},[1206],{"type":71,"value":642},{"type":66,"tag":216,"props":1208,"children":1209},{"style":223},[1210],{"type":71,"value":268},{"type":66,"tag":1212,"props":1213,"children":1215},"h3",{"id":1214},"redirect-path",[1216],{"type":71,"value":1217},"Redirect path",{"type":66,"tag":67,"props":1219,"children":1220},{},[1221],{"type":71,"value":1222},"You can easily handle redirection to the initial requested route after login.",{"type":66,"tag":124,"props":1224,"children":1225},{"icon":126},[1226],{"type":66,"tag":67,"props":1227,"children":1228},{},[1229,1231,1237,1239,1244],{"type":71,"value":1230},"You must enable the ",{"type":66,"tag":99,"props":1232,"children":1234},{"className":1233},[],[1235],{"type":71,"value":1236},"cookieRedirect",{"type":71,"value":1238}," option of the ",{"type":66,"tag":74,"props":1240,"children":1241},{"href":160},[1242],{"type":71,"value":1243},"redirectOptions",{"type":71,"value":1245}," to allow cookie storage and take benefit of this feature.",{"type":66,"tag":205,"props":1247,"children":1249},{"className":207,"code":1248,"filename":902,"language":210,"meta":59,"style":59},"\u003Cscript setup lang=\"ts\">\nconst user = useSupabaseUser()\n\n// Get redirect path from cookies\nconst cookieName = useRuntimeConfig().public.supabase.cookieName\nconst redirectPath = useCookie(`${cookieName}-redirect-path`).value\n\nwatch(user, () => {\n if (user.value) {\n // Clear cookie\n useCookie(`${cookieName}-redirect-path`).value = null\n // Redirect to path\n return navigateTo(redirectPath || '/'); \n }\n}, { immediate: true })\n\u003C/script>\n\u003Ctemplate>\n \u003Cdiv>Waiting for login...\u003C/div>\n\u003C/template>\n",[1250],{"type":66,"tag":99,"props":1251,"children":1252},{"__ignoreMap":59},[1253,1292,1315,1322,1330,1383,1447,1454,1481,1512,1520,1573,1581,1632,1639,1670,1685,1700,1731],{"type":66,"tag":216,"props":1254,"children":1255},{"class":218,"line":219},[1256,1260,1264,1268,1272,1276,1280,1284,1288],{"type":66,"tag":216,"props":1257,"children":1258},{"style":223},[1259],{"type":71,"value":226},{"type":66,"tag":216,"props":1261,"children":1262},{"style":229},[1263],{"type":71,"value":232},{"type":66,"tag":216,"props":1265,"children":1266},{"style":235},[1267],{"type":71,"value":238},{"type":66,"tag":216,"props":1269,"children":1270},{"style":235},[1271],{"type":71,"value":243},{"type":66,"tag":216,"props":1273,"children":1274},{"style":223},[1275],{"type":71,"value":248},{"type":66,"tag":216,"props":1277,"children":1278},{"style":223},[1279],{"type":71,"value":253},{"type":66,"tag":216,"props":1281,"children":1282},{"style":256},[1283],{"type":71,"value":259},{"type":66,"tag":216,"props":1285,"children":1286},{"style":223},[1287],{"type":71,"value":253},{"type":66,"tag":216,"props":1289,"children":1290},{"style":223},[1291],{"type":71,"value":268},{"type":66,"tag":216,"props":1293,"children":1294},{"class":218,"line":271},[1295,1299,1303,1307,1311],{"type":66,"tag":216,"props":1296,"children":1297},{"style":235},[1298],{"type":71,"value":277},{"type":66,"tag":216,"props":1300,"children":1301},{"style":280},[1302],{"type":71,"value":957},{"type":66,"tag":216,"props":1304,"children":1305},{"style":223},[1306],{"type":71,"value":248},{"type":66,"tag":216,"props":1308,"children":1309},{"style":290},[1310],{"type":71,"value":966},{"type":66,"tag":216,"props":1312,"children":1313},{"style":280},[1314],{"type":71,"value":298},{"type":66,"tag":216,"props":1316,"children":1317},{"class":218,"line":301},[1318],{"type":66,"tag":216,"props":1319,"children":1320},{"emptyLinePlaceholder":342},[1321],{"type":71,"value":345},{"type":66,"tag":216,"props":1323,"children":1324},{"class":218,"line":338},[1325],{"type":66,"tag":216,"props":1326,"children":1327},{"style":1045},[1328],{"type":71,"value":1329},"// Get redirect path from cookies\n",{"type":66,"tag":216,"props":1331,"children":1332},{"class":218,"line":348},[1333,1337,1342,1346,1351,1356,1360,1365,1369,1374,1378],{"type":66,"tag":216,"props":1334,"children":1335},{"style":235},[1336],{"type":71,"value":277},{"type":66,"tag":216,"props":1338,"children":1339},{"style":280},[1340],{"type":71,"value":1341}," cookieName ",{"type":66,"tag":216,"props":1343,"children":1344},{"style":223},[1345],{"type":71,"value":248},{"type":66,"tag":216,"props":1347,"children":1348},{"style":290},[1349],{"type":71,"value":1350}," useRuntimeConfig",{"type":66,"tag":216,"props":1352,"children":1353},{"style":280},[1354],{"type":71,"value":1355},"()",{"type":66,"tag":216,"props":1357,"children":1358},{"style":223},[1359],{"type":71,"value":92},{"type":66,"tag":216,"props":1361,"children":1362},{"style":280},[1363],{"type":71,"value":1364},"public",{"type":66,"tag":216,"props":1366,"children":1367},{"style":223},[1368],{"type":71,"value":92},{"type":66,"tag":216,"props":1370,"children":1371},{"style":280},[1372],{"type":71,"value":1373},"supabase",{"type":66,"tag":216,"props":1375,"children":1376},{"style":223},[1377],{"type":71,"value":92},{"type":66,"tag":216,"props":1379,"children":1380},{"style":280},[1381],{"type":71,"value":1382},"cookieName\n",{"type":66,"tag":216,"props":1384,"children":1385},{"class":218,"line":385},[1386,1390,1395,1399,1404,1408,1413,1418,1423,1428,1433,1438,1442],{"type":66,"tag":216,"props":1387,"children":1388},{"style":235},[1389],{"type":71,"value":277},{"type":66,"tag":216,"props":1391,"children":1392},{"style":280},[1393],{"type":71,"value":1394}," redirectPath ",{"type":66,"tag":216,"props":1396,"children":1397},{"style":223},[1398],{"type":71,"value":248},{"type":66,"tag":216,"props":1400,"children":1401},{"style":290},[1402],{"type":71,"value":1403}," useCookie",{"type":66,"tag":216,"props":1405,"children":1406},{"style":280},[1407],{"type":71,"value":325},{"type":66,"tag":216,"props":1409,"children":1410},{"style":223},[1411],{"type":71,"value":1412},"`${",{"type":66,"tag":216,"props":1414,"children":1415},{"style":280},[1416],{"type":71,"value":1417},"cookieName",{"type":66,"tag":216,"props":1419,"children":1420},{"style":223},[1421],{"type":71,"value":1422},"}",{"type":66,"tag":216,"props":1424,"children":1425},{"style":256},[1426],{"type":71,"value":1427},"-redirect-path",{"type":66,"tag":216,"props":1429,"children":1430},{"style":223},[1431],{"type":71,"value":1432},"`",{"type":66,"tag":216,"props":1434,"children":1435},{"style":280},[1436],{"type":71,"value":1437},")",{"type":66,"tag":216,"props":1439,"children":1440},{"style":223},[1441],{"type":71,"value":92},{"type":66,"tag":216,"props":1443,"children":1444},{"style":280},[1445],{"type":71,"value":1446},"value\n",{"type":66,"tag":216,"props":1448,"children":1449},{"class":218,"line":452},[1450],{"type":66,"tag":216,"props":1451,"children":1452},{"emptyLinePlaceholder":342},[1453],{"type":71,"value":345},{"type":66,"tag":216,"props":1455,"children":1456},{"class":218,"line":485},[1457,1461,1465,1469,1473,1477],{"type":66,"tag":216,"props":1458,"children":1459},{"style":290},[1460],{"type":71,"value":985},{"type":66,"tag":216,"props":1462,"children":1463},{"style":280},[1464],{"type":71,"value":990},{"type":66,"tag":216,"props":1466,"children":1467},{"style":223},[1468],{"type":71,"value":995},{"type":66,"tag":216,"props":1470,"children":1471},{"style":223},[1472],{"type":71,"value":372},{"type":66,"tag":216,"props":1474,"children":1475},{"style":235},[1476],{"type":71,"value":377},{"type":66,"tag":216,"props":1478,"children":1479},{"style":223},[1480],{"type":71,"value":382},{"type":66,"tag":216,"props":1482,"children":1483},{"class":218,"line":502},[1484,1488,1492,1496,1500,1504,1508],{"type":66,"tag":216,"props":1485,"children":1486},{"style":414},[1487],{"type":71,"value":562},{"type":66,"tag":216,"props":1489,"children":1490},{"style":229},[1491],{"type":71,"value":567},{"type":66,"tag":216,"props":1493,"children":1494},{"style":280},[1495],{"type":71,"value":1023},{"type":66,"tag":216,"props":1497,"children":1498},{"style":223},[1499],{"type":71,"value":92},{"type":66,"tag":216,"props":1501,"children":1502},{"style":280},[1503],{"type":71,"value":477},{"type":66,"tag":216,"props":1505,"children":1506},{"style":229},[1507],{"type":71,"value":577},{"type":66,"tag":216,"props":1509,"children":1510},{"style":223},[1511],{"type":71,"value":449},{"type":66,"tag":216,"props":1513,"children":1514},{"class":218,"line":534},[1515],{"type":66,"tag":216,"props":1516,"children":1517},{"style":1045},[1518],{"type":71,"value":1519}," // Clear cookie\n",{"type":66,"tag":216,"props":1521,"children":1522},{"class":218,"line":543},[1523,1528,1532,1536,1540,1544,1548,1552,1556,1560,1564,1568],{"type":66,"tag":216,"props":1524,"children":1525},{"style":290},[1526],{"type":71,"value":1527}," useCookie",{"type":66,"tag":216,"props":1529,"children":1530},{"style":229},[1531],{"type":71,"value":325},{"type":66,"tag":216,"props":1533,"children":1534},{"style":223},[1535],{"type":71,"value":1412},{"type":66,"tag":216,"props":1537,"children":1538},{"style":280},[1539],{"type":71,"value":1417},{"type":66,"tag":216,"props":1541,"children":1542},{"style":223},[1543],{"type":71,"value":1422},{"type":66,"tag":216,"props":1545,"children":1546},{"style":256},[1547],{"type":71,"value":1427},{"type":66,"tag":216,"props":1549,"children":1550},{"style":223},[1551],{"type":71,"value":1432},{"type":66,"tag":216,"props":1553,"children":1554},{"style":229},[1555],{"type":71,"value":1437},{"type":66,"tag":216,"props":1557,"children":1558},{"style":223},[1559],{"type":71,"value":92},{"type":66,"tag":216,"props":1561,"children":1562},{"style":280},[1563],{"type":71,"value":477},{"type":66,"tag":216,"props":1565,"children":1566},{"style":223},[1567],{"type":71,"value":411},{"type":66,"tag":216,"props":1569,"children":1570},{"style":223},[1571],{"type":71,"value":1572}," null\n",{"type":66,"tag":216,"props":1574,"children":1575},{"class":218,"line":556},[1576],{"type":66,"tag":216,"props":1577,"children":1578},{"style":1045},[1579],{"type":71,"value":1580}," // Redirect to path\n",{"type":66,"tag":216,"props":1582,"children":1583},{"class":218,"line":606},[1584,1588,1592,1596,1601,1606,1610,1614,1618,1622,1627],{"type":66,"tag":216,"props":1585,"children":1586},{"style":414},[1587],{"type":71,"value":1056},{"type":66,"tag":216,"props":1589,"children":1590},{"style":290},[1591],{"type":71,"value":1061},{"type":66,"tag":216,"props":1593,"children":1594},{"style":229},[1595],{"type":71,"value":325},{"type":66,"tag":216,"props":1597,"children":1598},{"style":280},[1599],{"type":71,"value":1600},"redirectPath",{"type":66,"tag":216,"props":1602,"children":1603},{"style":223},[1604],{"type":71,"value":1605}," ||",{"type":66,"tag":216,"props":1607,"children":1608},{"style":223},[1609],{"type":71,"value":517},{"type":66,"tag":216,"props":1611,"children":1612},{"style":256},[1613],{"type":71,"value":1074},{"type":66,"tag":216,"props":1615,"children":1616},{"style":223},[1617],{"type":71,"value":527},{"type":66,"tag":216,"props":1619,"children":1620},{"style":229},[1621],{"type":71,"value":1437},{"type":66,"tag":216,"props":1623,"children":1624},{"style":223},[1625],{"type":71,"value":1626},";",{"type":66,"tag":216,"props":1628,"children":1629},{"style":229},[1630],{"type":71,"value":1631}," \n",{"type":66,"tag":216,"props":1633,"children":1634},{"class":218,"line":615},[1635],{"type":66,"tag":216,"props":1636,"children":1637},{"style":223},[1638],{"type":71,"value":1090},{"type":66,"tag":216,"props":1640,"children":1641},{"class":218,"line":632},[1642,1646,1650,1654,1658,1662,1666],{"type":66,"tag":216,"props":1643,"children":1644},{"style":223},[1645],{"type":71,"value":1098},{"type":66,"tag":216,"props":1647,"children":1648},{"style":223},[1649],{"type":71,"value":396},{"type":66,"tag":216,"props":1651,"children":1652},{"style":229},[1653],{"type":71,"value":1107},{"type":66,"tag":216,"props":1655,"children":1656},{"style":223},[1657],{"type":71,"value":463},{"type":66,"tag":216,"props":1659,"children":1660},{"style":1114},[1661],{"type":71,"value":1117},{"type":66,"tag":216,"props":1663,"children":1664},{"style":223},[1665],{"type":71,"value":406},{"type":66,"tag":216,"props":1667,"children":1668},{"style":280},[1669],{"type":71,"value":335},{"type":66,"tag":216,"props":1671,"children":1672},{"class":218,"line":649},[1673,1677,1681],{"type":66,"tag":216,"props":1674,"children":1675},{"style":223},[1676],{"type":71,"value":621},{"type":66,"tag":216,"props":1678,"children":1679},{"style":229},[1680],{"type":71,"value":232},{"type":66,"tag":216,"props":1682,"children":1683},{"style":223},[1684],{"type":71,"value":268},{"type":66,"tag":216,"props":1686,"children":1687},{"class":218,"line":667},[1688,1692,1696],{"type":66,"tag":216,"props":1689,"children":1690},{"style":223},[1691],{"type":71,"value":226},{"type":66,"tag":216,"props":1693,"children":1694},{"style":229},[1695],{"type":71,"value":642},{"type":66,"tag":216,"props":1697,"children":1698},{"style":223},[1699],{"type":71,"value":268},{"type":66,"tag":216,"props":1701,"children":1702},{"class":218,"line":711},[1703,1707,1711,1715,1719,1723,1727],{"type":66,"tag":216,"props":1704,"children":1705},{"style":223},[1706],{"type":71,"value":655},{"type":66,"tag":216,"props":1708,"children":1709},{"style":229},[1710],{"type":71,"value":660},{"type":66,"tag":216,"props":1712,"children":1713},{"style":223},[1714],{"type":71,"value":1178},{"type":66,"tag":216,"props":1716,"children":1717},{"style":280},[1718],{"type":71,"value":1183},{"type":66,"tag":216,"props":1720,"children":1721},{"style":223},[1722],{"type":71,"value":621},{"type":66,"tag":216,"props":1724,"children":1725},{"style":229},[1726],{"type":71,"value":660},{"type":66,"tag":216,"props":1728,"children":1729},{"style":223},[1730],{"type":71,"value":268},{"type":66,"tag":216,"props":1732,"children":1733},{"class":218,"line":720},[1734,1738,1742],{"type":66,"tag":216,"props":1735,"children":1736},{"style":223},[1737],{"type":71,"value":621},{"type":66,"tag":216,"props":1739,"children":1740},{"style":229},[1741],{"type":71,"value":642},{"type":66,"tag":216,"props":1743,"children":1744},{"style":223},[1745],{"type":71,"value":268},{"type":66,"tag":1747,"props":1748,"children":1749},"style",{},[1750],{"type":71,"value":1751},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":59,"searchDepth":271,"depth":271,"links":1753},[1754,1756],{"id":143,"depth":271,"text":1755},"Log-in page - /login",{"id":870,"depth":271,"text":1757,"children":1758},"Confirm page - /confirm",[1759],{"id":1214,"depth":301,"text":1217},"markdown","content:3.authentication.md","content","3.authentication.md","3.authentication","md",[1767,1769],{"_path":6,"title":5,"description":1768},"@nuxtjs/supabase is a Nuxt module for first class integration with Supabase.",{"_path":22,"title":21,"description":1770},"Make requests to the Supabase API with the useSupabaseClient composable",1724942526499] \ No newline at end of file diff --git a/authentication/index.html b/authentication/index.html index 8eebf020..b9ed882b 100644 --- a/authentication/index.html +++ b/authentication/index.html @@ -61,7 +61,7 @@ - + @@ -165,5 +165,5 @@ <div>Waiting for login...</div> </template>
Made with Nuxt Studio
- - \ No newline at end of file + + \ No newline at end of file diff --git a/changelog/_payload.json b/changelog/_payload.json index ab615eab..68a78073 100644 --- a/changelog/_payload.json +++ b/changelog/_payload.json @@ -1 +1 @@ -[{"data":1,"prerenderedAt":4687},["ShallowReactive",2],{"navigation":3,"/changelog":58,"/changelog-surround":86,"releases":91},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":52,"_dir":59,"_draft":60,"_partial":60,"_locale":59,"title":51,"description":61,"icon":53,"body":62,"_type":80,"_id":81,"_source":82,"_file":83,"_stem":84,"_extension":85},"",false,"Discover the latest updates of the Supabase Module",{"type":63,"children":64,"toc":77},"root",[65,73],{"type":66,"tag":67,"props":68,"children":69},"element","p",{},[70],{"type":71,"value":72},"text","Discover the lastest updates.",{"type":66,"tag":74,"props":75,"children":76},"releases",{},[],{"title":59,"searchDepth":78,"depth":78,"links":79},2,[],"markdown","content:6.changelog.md","content","6.changelog.md","6.changelog","md",[87,89],{"_path":48,"title":47,"description":88},"Demonstration of using Supabase with Nuxt.",{"_path":56,"title":55,"description":90},"Discover our kaban board for the next release of the Supabase module.",[92,170,222,297,532,588,688,786,890,1015,1190,1259,1365,1605,1698,2002,2104,2181,2247,2546,2820,2893,3025,3070,3130,3182,3329,3428,3491,3542,3587,3639,3752,3828,3906,3970,4055,4157,4263,4379,4413,4477,4541,4629],{"name":93,"tag_name":93,"date":94,"body":95,"v":161,"url":162,"tarball":163,"zipball":164,"prerelease":60,"author":165,"title":59,"description":59,"_type":80,"_id":169},"v1.3.5","2024-07-15T12:59:37Z",{"type":63,"children":96,"toc":155},[97,104,111,145],{"type":66,"tag":98,"props":99,"children":101},"h2",{"id":100},"whats-changed",[102],{"type":71,"value":103},"What's Changed",{"type":66,"tag":105,"props":106,"children":108},"h3",{"id":107},"bug-fixes",[109],{"type":71,"value":110},"Bug Fixes",{"type":66,"tag":112,"props":113,"children":114},"ul",{},[115],{"type":66,"tag":116,"props":117,"children":118},"li",{},[119,125,127,136,138],{"type":66,"tag":120,"props":121,"children":122},"strong",{},[123],{"type":71,"value":124},"types:",{"type":71,"value":126}," generate (",{"type":66,"tag":128,"props":129,"children":133},"a",{"href":130,"rel":131},"https://github.com/nuxt-community/supabase-module/commit/671295a3f8e1743384913f2940975c2e4217ff2e",[132],"nofollow",[134],{"type":71,"value":135},"671295a",{"type":71,"value":137},") resolves ",{"type":66,"tag":128,"props":139,"children":142},{"href":140,"rel":141},"https://github.com/nuxt-modules/supabase/issues/383",[132],[143],{"type":71,"value":144},"#383",{"type":66,"tag":67,"props":146,"children":147},{},[148],{"type":66,"tag":128,"props":149,"children":152},{"href":150,"rel":151},"https://github.com/nuxt-community/supabase-module/compare/v1.3.4...v1.3.5",[132],[153],{"type":71,"value":154},"Full changelog",{"title":59,"searchDepth":78,"depth":78,"links":156},[157],{"id":100,"depth":78,"text":103,"children":158},[159],{"id":107,"depth":160,"text":110},3,1,"https://github.com/nuxt-modules/supabase/releases/tag/v1.3.5","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.3.5","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.3.5",{"name":166,"url":167,"avatar":168},"larbish","https://github.com/larbish","https://avatars.githubusercontent.com/u/7290030?v=4","github:v1.3.5.md",{"name":171,"tag_name":171,"date":172,"body":173,"v":161,"url":217,"tarball":218,"zipball":219,"prerelease":60,"author":220,"title":59,"description":59,"_type":80,"_id":221},"v1.3.4","2024-07-10T07:00:38Z",{"type":63,"children":174,"toc":212},[175,179,183],{"type":66,"tag":98,"props":176,"children":177},{"id":100},[178],{"type":71,"value":103},{"type":66,"tag":105,"props":180,"children":181},{"id":107},[182],{"type":71,"value":110},{"type":66,"tag":112,"props":184,"children":185},{},[186],{"type":66,"tag":116,"props":187,"children":188},{},[189,194,196,203,205],{"type":66,"tag":120,"props":190,"children":191},{},[192],{"type":71,"value":193},"vite:",{"type":71,"value":195}," optimize order (",{"type":66,"tag":128,"props":197,"children":200},{"href":198,"rel":199},"https://github.com/nuxt-community/supabase-module/commit/663bd73ebb146ecde1abe5f29b52326e6dc2b6cd",[132],[201],{"type":71,"value":202},"663bd73",{"type":71,"value":204},") fixes ",{"type":66,"tag":128,"props":206,"children":209},{"href":207,"rel":208},"https://github.com/nuxt-modules/supabase/issues/385",[132],[210],{"type":71,"value":211},"#385",{"title":59,"searchDepth":78,"depth":78,"links":213},[214],{"id":100,"depth":78,"text":103,"children":215},[216],{"id":107,"depth":160,"text":110},"https://github.com/nuxt-modules/supabase/releases/tag/v1.3.4","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.3.4","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.3.4",{"name":166,"url":167,"avatar":168},"github:v1.3.4.md",{"name":223,"tag_name":223,"date":224,"body":225,"v":161,"url":289,"tarball":290,"zipball":291,"prerelease":60,"reactions":292,"author":295,"title":59,"description":59,"_type":80,"_id":296},"v1.3.2","2024-07-05T16:26:23Z",{"type":63,"children":226,"toc":283},[227,231,235,256,262],{"type":66,"tag":98,"props":228,"children":229},{"id":100},[230],{"type":71,"value":103},{"type":66,"tag":105,"props":232,"children":233},{"id":107},[234],{"type":71,"value":110},{"type":66,"tag":112,"props":236,"children":237},{},[238],{"type":66,"tag":116,"props":239,"children":240},{},[241,245,247,254],{"type":66,"tag":120,"props":242,"children":243},{},[244],{"type":71,"value":193},{"type":71,"value":246}," optimize postgrest (",{"type":66,"tag":128,"props":248,"children":251},{"href":249,"rel":250},"https://github.com/nuxt-community/supabase-module/commit/2a6d91a3ee83aa65cc5741afea907ca474e61d64",[132],[252],{"type":71,"value":253},"2a6d91a",{"type":71,"value":255},")",{"type":66,"tag":105,"props":257,"children":259},{"id":258},"features",[260],{"type":71,"value":261},"Features",{"type":66,"tag":112,"props":263,"children":264},{},[265],{"type":66,"tag":116,"props":266,"children":267},{},[268,273,275,282],{"type":66,"tag":120,"props":269,"children":270},{},[271],{"type":71,"value":272},"ci:",{"type":71,"value":274}," nightly version (",{"type":66,"tag":128,"props":276,"children":279},{"href":277,"rel":278},"https://github.com/nuxt-community/supabase-module/commit/298e608442ac5e8c15aa61c01411585e57732f4a",[132],[280],{"type":71,"value":281},"298e608",{"type":71,"value":255},{"title":59,"searchDepth":78,"depth":78,"links":284},[285],{"id":100,"depth":78,"text":103,"children":286},[287,288],{"id":107,"depth":160,"text":110},{"id":258,"depth":160,"text":261},"https://github.com/nuxt-modules/supabase/releases/tag/v1.3.2","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.3.2","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.3.2",{"url":293,"total_count":161,"+1":294,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":161,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/164188781/reactions",0,{"name":166,"url":167,"avatar":168},"github:v1.3.2.md",{"name":298,"tag_name":298,"date":299,"body":300,"v":161,"url":525,"tarball":526,"zipball":527,"prerelease":60,"reactions":528,"author":530,"title":59,"description":59,"_type":80,"_id":531},"v1.3.1","2024-07-05T12:25:51Z",{"type":63,"children":301,"toc":519},[302,306,328,334,356,374,388,401,406,459,476,482,510],{"type":66,"tag":98,"props":303,"children":304},{"id":100},[305],{"type":71,"value":103},{"type":66,"tag":67,"props":307,"children":308},{},[309,311,318,320,326],{"type":71,"value":310},"⚠️ You can switch directly to ",{"type":66,"tag":312,"props":313,"children":315},"code",{"className":314},[],[316],{"type":71,"value":317},"1.3.1",{"type":71,"value":319},", since ",{"type":66,"tag":312,"props":321,"children":323},{"className":322},[],[324],{"type":71,"value":325},"1.3.0",{"type":71,"value":327}," has been superseded.",{"type":66,"tag":105,"props":329,"children":331},{"id":330},"major-changes",[332],{"type":71,"value":333},"Major changes",{"type":66,"tag":67,"props":335,"children":336},{},[337,339,346,348,355],{"type":71,"value":338},"We're now using the ",{"type":66,"tag":128,"props":340,"children":343},{"href":341,"rel":342},"https://supabase.com/docs/guides/auth/server-side/creating-a-client",[132],[344],{"type":71,"value":345},"@supabase/ssr",{"type":71,"value":347}," library under the hood 🎉 (",{"type":66,"tag":128,"props":349,"children":352},{"href":350,"rel":351},"https://github.com/nuxt-modules/supabase/issues/357",[132],[353],{"type":71,"value":354},"#357",{"type":71,"value":255},{"type":66,"tag":67,"props":357,"children":358},{},[359,361,366,368],{"type":71,"value":360},"There are ",{"type":66,"tag":120,"props":362,"children":363},{},[364],{"type":71,"value":365},"no breaking changes",{"type":71,"value":367}," related to this improvement. However, a non-disruptive warning appears in this release:\r\n",{"type":66,"tag":312,"props":369,"children":371},{"className":370},[],[372],{"type":71,"value":373},"Using the user object as returned from supabase.auth.getSession() or from some supabase.auth.onAuthStateChange() events could be insecure.",{"type":66,"tag":67,"props":375,"children":376},{},[377,379,386],{"type":71,"value":378},"This warning is related to ",{"type":66,"tag":128,"props":380,"children":383},{"href":381,"rel":382},"https://github.com/supabase/auth-js/issues/912",[132],[384],{"type":71,"value":385},"an issue",{"type":71,"value":387}," in the Supabase library itself. Initially, I intended to wait for this fix but since managing updates across two separate branches is challenging I chose to merge it anyway. I could no longer delay the release due to users raising concerns about outdated dependencies and other issues within the module.",{"type":66,"tag":67,"props":389,"children":390},{},[391,393,399],{"type":71,"value":392},"You can upvote ",{"type":66,"tag":128,"props":394,"children":396},{"href":381,"rel":395},[132],[397],{"type":71,"value":398},"the issue",{"type":71,"value":400}," to encourage the Supabase maintainers to address it.",{"type":66,"tag":67,"props":402,"children":403},{},[404],{"type":71,"value":405},"This improvement might fix:",{"type":66,"tag":112,"props":407,"children":408},{},[409,419,429,439,449],{"type":66,"tag":116,"props":410,"children":411},{},[412],{"type":66,"tag":128,"props":413,"children":416},{"href":414,"rel":415},"https://github.com/nuxt-modules/supabase/issues/298",[132],[417],{"type":71,"value":418},"#298",{"type":66,"tag":116,"props":420,"children":421},{},[422],{"type":66,"tag":128,"props":423,"children":426},{"href":424,"rel":425},"https://github.com/nuxt-modules/supabase/issues/381",[132],[427],{"type":71,"value":428},"#381",{"type":66,"tag":116,"props":430,"children":431},{},[432],{"type":66,"tag":128,"props":433,"children":436},{"href":434,"rel":435},"https://github.com/nuxt-modules/supabase/issues/380",[132],[437],{"type":71,"value":438},"#380",{"type":66,"tag":116,"props":440,"children":441},{},[442],{"type":66,"tag":128,"props":443,"children":446},{"href":444,"rel":445},"https://github.com/nuxt-modules/supabase/issues/367",[132],[447],{"type":71,"value":448},"#367",{"type":66,"tag":116,"props":450,"children":451},{},[452],{"type":66,"tag":128,"props":453,"children":456},{"href":454,"rel":455},"https://github.com/nuxt-modules/supabase/issues/326",[132],[457],{"type":71,"value":458},"#326",{"type":66,"tag":67,"props":460,"children":461},{},[462,464,474],{"type":71,"value":463},"A big thanks to ",{"type":66,"tag":128,"props":465,"children":468},{"href":466,"rel":467},"https://github.com/felixgabler",[132],[469],{"type":66,"tag":120,"props":470,"children":471},{},[472],{"type":71,"value":473},"@felixgabler",{"type":71,"value":475}," for initiating this change and helping refactor the module.",{"type":66,"tag":105,"props":477,"children":479},{"id":478},"other-update",[480],{"type":71,"value":481},"Other update",{"type":66,"tag":112,"props":483,"children":484},{},[485],{"type":66,"tag":116,"props":486,"children":487},{},[488,490,500,502,509],{"type":71,"value":489},"Automatic database types by ",{"type":66,"tag":128,"props":491,"children":494},{"href":492,"rel":493},"https://github.com/IsraelOrtuno",[132],[495],{"type":66,"tag":120,"props":496,"children":497},{},[498],{"type":71,"value":499},"@IsraelOrtuno",{"type":71,"value":501}," (",{"type":66,"tag":128,"props":503,"children":506},{"href":504,"rel":505},"https://github.com/nuxt-modules/supabase/issues/336",[132],[507],{"type":71,"value":508},"#336",{"type":71,"value":255},{"type":66,"tag":67,"props":511,"children":512},{},[513],{"type":66,"tag":128,"props":514,"children":517},{"href":515,"rel":516},"https://github.com/nuxt-community/supabase-module/compare/v1.2.2...v1.3.1",[132],[518],{"type":71,"value":154},{"title":59,"searchDepth":78,"depth":78,"links":520},[521],{"id":100,"depth":78,"text":103,"children":522},[523,524],{"id":330,"depth":160,"text":333},{"id":478,"depth":160,"text":481},"https://github.com/nuxt-modules/supabase/releases/tag/v1.3.1","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.3.1","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.3.1",{"url":529,"total_count":78,"+1":294,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":78,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/164152561/reactions",{"name":166,"url":167,"avatar":168},"github:v1.3.1.md",{"name":533,"tag_name":533,"date":534,"body":535,"v":161,"url":580,"tarball":581,"zipball":582,"prerelease":60,"reactions":583,"author":586,"title":59,"description":59,"_type":80,"_id":587},"v1.2.2","2024-05-02T15:33:41Z",{"type":63,"children":536,"toc":575},[537,541,545,566],{"type":66,"tag":98,"props":538,"children":539},{"id":100},[540],{"type":71,"value":103},{"type":66,"tag":105,"props":542,"children":543},{"id":107},[544],{"type":71,"value":110},{"type":66,"tag":112,"props":546,"children":547},{},[548],{"type":66,"tag":116,"props":549,"children":550},{},[551,556,558,565],{"type":66,"tag":120,"props":552,"children":553},{},[554],{"type":71,"value":555},"serverSupabaseSession:",{"type":71,"value":557}," export service (",{"type":66,"tag":128,"props":559,"children":562},{"href":560,"rel":561},"https://github.com/nuxt-community/supabase-module/commit/9cfeb8726d562c5aac6fe1efa7dd1664bc39ed66",[132],[563],{"type":71,"value":564},"9cfeb87",{"type":71,"value":255},{"type":66,"tag":67,"props":567,"children":568},{},[569],{"type":66,"tag":128,"props":570,"children":573},{"href":571,"rel":572},"https://github.com/nuxt-community/supabase-module/compare/v1.2.1...v1.2.2",[132],[574],{"type":71,"value":154},{"title":59,"searchDepth":78,"depth":78,"links":576},[577],{"id":100,"depth":78,"text":103,"children":578},[579],{"id":107,"depth":160,"text":110},"https://github.com/nuxt-modules/supabase/releases/tag/v1.2.2","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.2.2","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.2.2",{"url":584,"total_count":585,"+1":294,"-1":294,"laugh":294,"hooray":161,"confused":294,"heart":78,"rocket":294,"eyes":161},"https://api.github.com/repos/nuxt-modules/supabase/releases/153851448/reactions",4,{"name":166,"url":167,"avatar":168},"github:v1.2.2.md",{"name":589,"tag_name":589,"date":590,"body":591,"v":161,"url":680,"tarball":681,"zipball":682,"prerelease":60,"reactions":683,"author":686,"title":59,"description":59,"_type":80,"_id":687},"v1.2.1","2024-04-18T08:32:42Z",{"type":63,"children":592,"toc":673},[593,597,603,627,633,647,653,664],{"type":66,"tag":98,"props":594,"children":595},{"id":100},[596],{"type":71,"value":103},{"type":66,"tag":105,"props":598,"children":600},{"id":599},"improvements",[601],{"type":71,"value":602},"Improvements",{"type":66,"tag":67,"props":604,"children":605},{},[606,608,618,620],{"type":71,"value":607},"Performance improvements by ",{"type":66,"tag":128,"props":609,"children":612},{"href":610,"rel":611},"https://github.com/vinceglb",[132],[613],{"type":66,"tag":120,"props":614,"children":615},{},[616],{"type":71,"value":617},"@vinceglb",{"type":71,"value":619}," in ",{"type":66,"tag":128,"props":621,"children":624},{"href":622,"rel":623},"https://github.com/nuxt-modules/supabase/issues/352",[132],[625],{"type":71,"value":626},"#352",{"type":66,"tag":105,"props":628,"children":630},{"id":629},"chore",[631],{"type":71,"value":632},"Chore",{"type":66,"tag":67,"props":634,"children":635},{},[636,638,645],{"type":71,"value":637},"Move to eslint v9 using ",{"type":66,"tag":128,"props":639,"children":642},{"href":640,"rel":641},"https://eslint.nuxt.com",[132],[643],{"type":71,"value":644},"@nuxt/eslint",{"type":71,"value":646}," package",{"type":66,"tag":105,"props":648,"children":650},{"id":649},"thanks-for-the-help-from",[651],{"type":71,"value":652},"💚 Thanks for the help from:",{"type":66,"tag":67,"props":654,"children":655},{},[656],{"type":66,"tag":128,"props":657,"children":659},{"href":610,"rel":658},[132],[660],{"type":66,"tag":120,"props":661,"children":662},{},[663],{"type":71,"value":617},{"type":66,"tag":67,"props":665,"children":666},{},[667],{"type":66,"tag":128,"props":668,"children":671},{"href":669,"rel":670},"https://github.com/nuxt-community/supabase-module/compare/v1.2.0...v1.2.1",[132],[672],{"type":71,"value":154},{"title":59,"searchDepth":78,"depth":78,"links":674},[675],{"id":100,"depth":78,"text":103,"children":676},[677,678,679],{"id":599,"depth":160,"text":602},{"id":629,"depth":160,"text":632},{"id":649,"depth":160,"text":652},"https://github.com/nuxt-modules/supabase/releases/tag/v1.2.1","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.2.1","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.2.1",{"url":684,"total_count":685,"+1":294,"-1":294,"laugh":294,"hooray":78,"confused":294,"heart":160,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/151694236/reactions",5,{"name":166,"url":167,"avatar":168},"github:v1.2.1.md",{"name":689,"tag_name":689,"date":690,"body":691,"v":161,"url":781,"tarball":782,"zipball":783,"prerelease":60,"author":784,"title":59,"description":59,"_type":80,"_id":785},"v1.2.0","2024-03-29T09:33:20Z",{"type":63,"children":692,"toc":776},[693,697,703,748,767],{"type":66,"tag":98,"props":694,"children":695},{"id":100},[696],{"type":71,"value":103},{"type":66,"tag":105,"props":698,"children":700},{"id":699},"minor-version-since-we-have-a-new-composable",[701],{"type":71,"value":702},"Minor version since we have a new composable 🎉",{"type":66,"tag":67,"props":704,"children":705},{},[706,712,714,720,722,729,731,738,740,747],{"type":66,"tag":128,"props":707,"children":710},{"href":708,"rel":709},"https://supabase.nuxtjs.org/usage/composables/usesupabasesession",[132],[711],{"type":71,"value":24},{"type":71,"value":713}," and ",{"type":66,"tag":128,"props":715,"children":718},{"href":716,"rel":717},"https://supabase.nuxtjs.org/usage/services/serversupabasesession",[132],[719],{"type":71,"value":40},{"type":71,"value":721}," are now available to fetch your session client and server side (",{"type":66,"tag":128,"props":723,"children":726},{"href":724,"rel":725},"https://github.com/nuxt-community/supabase-module/issues/338",[132],[727],{"type":71,"value":728},"#338",{"type":71,"value":730},") (",{"type":66,"tag":128,"props":732,"children":735},{"href":733,"rel":734},"https://github.com/nuxt-community/supabase-module/commit/07eb081d532510da4152554c7010c79ed6008559",[132],[736],{"type":71,"value":737},"07eb081",{"type":71,"value":739}," & ",{"type":66,"tag":128,"props":741,"children":744},{"href":742,"rel":743},"https://github.com/nuxt-community/supabase-module/commit/9dee37ee030506fc7888dfbb6cc1f29b9126a728",[132],[745],{"type":71,"value":746},"9dee37e",{"type":71,"value":255},{"type":66,"tag":749,"props":750,"children":752},"h4",{"id":751},"thanks-joeychilson-for-this-feature",[753,755,765],{"type":71,"value":754},"Thanks ",{"type":66,"tag":128,"props":756,"children":759},{"href":757,"rel":758},"https://github.com/joeychilson",[132],[760],{"type":66,"tag":120,"props":761,"children":762},{},[763],{"type":71,"value":764},"@joeychilson",{"type":71,"value":766}," for this feature 🙏",{"type":66,"tag":67,"props":768,"children":769},{},[770],{"type":66,"tag":128,"props":771,"children":774},{"href":772,"rel":773},"https://github.com/nuxt-community/supabase-module/compare/v1.1.7...v1.2.0",[132],[775],{"type":71,"value":154},{"title":59,"searchDepth":78,"depth":78,"links":777},[778],{"id":100,"depth":78,"text":103,"children":779},[780],{"id":699,"depth":160,"text":702},"https://github.com/nuxt-modules/supabase/releases/tag/v1.2.0","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.2.0","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.2.0",{"name":166,"url":167,"avatar":168},"github:v1.2.0.md",{"name":787,"tag_name":787,"date":788,"body":789,"v":161,"url":883,"tarball":884,"zipball":885,"prerelease":60,"reactions":886,"author":888,"title":59,"description":59,"_type":80,"_id":889},"v1.1.7","2024-03-07T09:33:03Z",{"type":63,"children":790,"toc":877},[791,795,799,850,855,868],{"type":66,"tag":98,"props":792,"children":793},{"id":100},[794],{"type":71,"value":103},{"type":66,"tag":105,"props":796,"children":797},{"id":258},[798],{"type":71,"value":261},{"type":66,"tag":112,"props":800,"children":801},{},[802],{"type":66,"tag":116,"props":803,"children":804},{},[805,810,812,818,820,826,827,833,834,841,843],{"type":66,"tag":120,"props":806,"children":807},{},[808],{"type":71,"value":809},"auth-middleware:",{"type":71,"value":811}," add ",{"type":66,"tag":312,"props":813,"children":815},{"className":814},[],[816],{"type":71,"value":817},"include",{"type":71,"value":819}," to ",{"type":66,"tag":312,"props":821,"children":823},{"className":822},[],[824],{"type":71,"value":825},"RedirectOptions",{"type":71,"value":501},{"type":66,"tag":128,"props":828,"children":831},{"href":829,"rel":830},"https://github.com/nuxt-community/supabase-module/issues/336",[132],[832],{"type":71,"value":508},{"type":71,"value":730},{"type":66,"tag":128,"props":835,"children":838},{"href":836,"rel":837},"https://github.com/nuxt-community/supabase-module/commit/f9aad558da8171af1c442a60915c979eb10b8fab",[132],[839],{"type":71,"value":840},"f9aad55",{"type":71,"value":842},"), closes ",{"type":66,"tag":128,"props":844,"children":847},{"href":845,"rel":846},"https://github.com/nuxt-community/supabase-module/issues/268",[132],[848],{"type":71,"value":849},"#268",{"type":66,"tag":105,"props":851,"children":852},{"id":649},[853],{"type":71,"value":854},"💚 Thanks for the help from",{"type":66,"tag":67,"props":856,"children":857},{},[858],{"type":66,"tag":128,"props":859,"children":862},{"href":860,"rel":861},"https://github.com/jojomatik",[132],[863],{"type":66,"tag":120,"props":864,"children":865},{},[866],{"type":71,"value":867},"@jojomatik",{"type":66,"tag":67,"props":869,"children":870},{},[871],{"type":66,"tag":128,"props":872,"children":875},{"href":873,"rel":874},"https://github.com/nuxt-community/supabase-module/compare/v1.1.6...v1.1.7",[132],[876],{"type":71,"value":154},{"title":59,"searchDepth":78,"depth":78,"links":878},[879],{"id":100,"depth":78,"text":103,"children":880},[881,882],{"id":258,"depth":160,"text":261},{"id":649,"depth":160,"text":854},"https://github.com/nuxt-modules/supabase/releases/tag/v1.1.7","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.1.7","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.1.7",{"url":887,"total_count":161,"+1":294,"-1":294,"laugh":294,"hooray":161,"confused":294,"heart":294,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/145217172/reactions",{"name":166,"url":167,"avatar":168},"github:v1.1.7.md",{"name":891,"tag_name":891,"date":892,"body":893,"v":161,"url":1008,"tarball":1009,"zipball":1010,"prerelease":60,"reactions":1011,"author":1013,"title":59,"description":59,"_type":80,"_id":1014},"v1.1.6","2024-01-26T15:22:23Z",{"type":63,"children":894,"toc":1001},[895,899,903,942,946,975,979,992],{"type":66,"tag":98,"props":896,"children":897},{"id":100},[898],{"type":71,"value":103},{"type":66,"tag":105,"props":900,"children":901},{"id":107},[902],{"type":71,"value":110},{"type":66,"tag":112,"props":904,"children":905},{},[906,924],{"type":66,"tag":116,"props":907,"children":908},{},[909,914,916,923],{"type":66,"tag":120,"props":910,"children":911},{},[912],{"type":71,"value":913},"deps:",{"type":71,"value":915}," set resolution (",{"type":66,"tag":128,"props":917,"children":920},{"href":918,"rel":919},"https://github.com/nuxt-community/supabase-module/commit/db8c102fb9d69395528eece3e1e0552a16e673da",[132],[921],{"type":71,"value":922},"db8c102",{"type":71,"value":255},{"type":66,"tag":116,"props":925,"children":926},{},[927,932,934,941],{"type":66,"tag":120,"props":928,"children":929},{},[930],{"type":71,"value":931},"playground:",{"type":71,"value":933}," watch on confirm page (",{"type":66,"tag":128,"props":935,"children":938},{"href":936,"rel":937},"https://github.com/nuxt-community/supabase-module/commit/0caf5c11d632df6b7e74e5e8973ee56a38b1c968",[132],[939],{"type":71,"value":940},"0caf5c1",{"type":71,"value":255},{"type":66,"tag":105,"props":943,"children":944},{"id":258},[945],{"type":71,"value":261},{"type":66,"tag":112,"props":947,"children":948},{},[949],{"type":66,"tag":116,"props":950,"children":951},{},[952,957,959,966,967,974],{"type":66,"tag":120,"props":953,"children":954},{},[955],{"type":71,"value":956},"app:",{"type":71,"value":958}," added redirect path cookie for use after signin (",{"type":66,"tag":128,"props":960,"children":963},{"href":961,"rel":962},"https://github.com/nuxt-community/supabase-module/issues/327",[132],[964],{"type":71,"value":965},"#327",{"type":71,"value":730},{"type":66,"tag":128,"props":968,"children":971},{"href":969,"rel":970},"https://github.com/nuxt-community/supabase-module/commit/1b78a050fdc6da155434e261823b029f9dce2d40",[132],[972],{"type":71,"value":973},"1b78a05",{"type":71,"value":255},{"type":66,"tag":105,"props":976,"children":977},{"id":649},[978],{"type":71,"value":854},{"type":66,"tag":67,"props":980,"children":981},{},[982],{"type":66,"tag":128,"props":983,"children":986},{"href":984,"rel":985},"https://github.com/Matthewenderle",[132],[987],{"type":66,"tag":120,"props":988,"children":989},{},[990],{"type":71,"value":991},"@Matthewenderle",{"type":66,"tag":67,"props":993,"children":994},{},[995],{"type":66,"tag":128,"props":996,"children":999},{"href":997,"rel":998},"https://github.com/nuxt-community/supabase-module/compare/v1.1.5...v1.1.6",[132],[1000],{"type":71,"value":154},{"title":59,"searchDepth":78,"depth":78,"links":1002},[1003],{"id":100,"depth":78,"text":103,"children":1004},[1005,1006,1007],{"id":107,"depth":160,"text":110},{"id":258,"depth":160,"text":261},{"id":649,"depth":160,"text":854},"https://github.com/nuxt-modules/supabase/releases/tag/v1.1.6","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.1.6","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.1.6",{"url":1012,"total_count":160,"+1":294,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":160,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/138681536/reactions",{"name":166,"url":167,"avatar":168},"github:v1.1.6.md",{"name":1016,"tag_name":1016,"date":1017,"body":1018,"v":161,"url":1183,"tarball":1184,"zipball":1185,"prerelease":60,"reactions":1186,"author":1188,"title":59,"description":59,"_type":80,"_id":1189},"v1.1.5","2023-12-28T14:29:18Z",{"type":63,"children":1019,"toc":1175},[1020,1024,1028,1049,1053,1072,1078,1115,1119,1166],{"type":66,"tag":98,"props":1021,"children":1022},{"id":100},[1023],{"type":71,"value":103},{"type":66,"tag":105,"props":1025,"children":1026},{"id":107},[1027],{"type":71,"value":110},{"type":66,"tag":112,"props":1029,"children":1030},{},[1031],{"type":66,"tag":116,"props":1032,"children":1033},{},[1034,1039,1041,1048],{"type":66,"tag":120,"props":1035,"children":1036},{},[1037],{"type":71,"value":1038},"server:",{"type":71,"value":1040}," fetch user from session (",{"type":66,"tag":128,"props":1042,"children":1045},{"href":1043,"rel":1044},"https://github.com/nuxt-community/supabase-module/commit/7a3b73c36cc9aea10100a0ff37b0e0e7ecefe2a8",[132],[1046],{"type":71,"value":1047},"7a3b73c",{"type":71,"value":255},{"type":66,"tag":105,"props":1050,"children":1051},{"id":599},[1052],{"type":71,"value":602},{"type":66,"tag":112,"props":1054,"children":1055},{},[1056],{"type":66,"tag":116,"props":1057,"children":1058},{},[1059,1063,1065],{"type":66,"tag":120,"props":1060,"children":1061},{},[1062],{"type":71,"value":956},{"type":71,"value":1064}," use module-builder stub mode for more accurate types ",{"type":66,"tag":128,"props":1066,"children":1069},{"href":1067,"rel":1068},"https://github.com/nuxt-modules/supabase/issues/315",[132],[1070],{"type":71,"value":1071},"#315",{"type":66,"tag":105,"props":1073,"children":1075},{"id":1074},"docs",[1076],{"type":71,"value":1077},"Docs",{"type":66,"tag":112,"props":1079,"children":1080},{},[1081,1098],{"type":66,"tag":116,"props":1082,"children":1083},{},[1084,1089,1091],{"type":66,"tag":120,"props":1085,"children":1086},{},[1087],{"type":71,"value":1088},"get-started:",{"type":71,"value":1090}," bun command ",{"type":66,"tag":128,"props":1092,"children":1095},{"href":1093,"rel":1094},"https://github.com/nuxt-modules/supabase/issues/317",[132],[1096],{"type":71,"value":1097},"#317",{"type":66,"tag":116,"props":1099,"children":1100},{},[1101,1106,1108],{"type":66,"tag":120,"props":1102,"children":1103},{},[1104],{"type":71,"value":1105},"readme:",{"type":71,"value":1107}," typo in #dev section ",{"type":66,"tag":128,"props":1109,"children":1112},{"href":1110,"rel":1111},"https://github.com/nuxt-modules/supabase/issues/316",[132],[1113],{"type":71,"value":1114},"#316",{"type":66,"tag":105,"props":1116,"children":1117},{"id":649},[1118],{"type":71,"value":854},{"type":66,"tag":67,"props":1120,"children":1121},{},[1122,1132,1134,1144,1145,1155,1156],{"type":66,"tag":128,"props":1123,"children":1126},{"href":1124,"rel":1125},"https://github.com/danielroe",[132],[1127],{"type":66,"tag":120,"props":1128,"children":1129},{},[1130],{"type":71,"value":1131},"@danielroe",{"type":71,"value":1133},"\r\n",{"type":66,"tag":128,"props":1135,"children":1138},{"href":1136,"rel":1137},"https://github.com/joshuabyler",[132],[1139],{"type":66,"tag":120,"props":1140,"children":1141},{},[1142],{"type":71,"value":1143},"@joshuabyler",{"type":71,"value":1133},{"type":66,"tag":128,"props":1146,"children":1149},{"href":1147,"rel":1148},"https://github.com/hafizjavaid",[132],[1150],{"type":66,"tag":120,"props":1151,"children":1152},{},[1153],{"type":71,"value":1154},"@hafizjavaid",{"type":71,"value":1133},{"type":66,"tag":128,"props":1157,"children":1160},{"href":1158,"rel":1159},"https://github.com/relisora",[132],[1161],{"type":66,"tag":120,"props":1162,"children":1163},{},[1164],{"type":71,"value":1165},"@relisora",{"type":66,"tag":67,"props":1167,"children":1168},{},[1169],{"type":66,"tag":128,"props":1170,"children":1173},{"href":1171,"rel":1172},"https://github.com/nuxt-community/supabase-module/compare/v1.1.4...v1.1.5",[132],[1174],{"type":71,"value":154},{"title":59,"searchDepth":78,"depth":78,"links":1176},[1177],{"id":100,"depth":78,"text":103,"children":1178},[1179,1180,1181,1182],{"id":107,"depth":160,"text":110},{"id":599,"depth":160,"text":602},{"id":1074,"depth":160,"text":1077},{"id":649,"depth":160,"text":854},"https://github.com/nuxt-modules/supabase/releases/tag/v1.1.5","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.1.5","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.1.5",{"url":1187,"total_count":585,"+1":160,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":161,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/135279818/reactions",{"name":166,"url":167,"avatar":168},"github:v1.1.5.md",{"name":1191,"tag_name":1191,"date":1192,"body":1193,"v":161,"url":1252,"tarball":1253,"zipball":1254,"prerelease":60,"reactions":1255,"author":1257,"title":59,"description":59,"_type":80,"_id":1258},"v1.1.4","2023-11-17T14:42:47Z",{"type":63,"children":1194,"toc":1247},[1195,1199,1203,1232],{"type":66,"tag":98,"props":1196,"children":1197},{"id":100},[1198],{"type":71,"value":103},{"type":66,"tag":105,"props":1200,"children":1201},{"id":107},[1202],{"type":71,"value":110},{"type":66,"tag":112,"props":1204,"children":1205},{},[1206],{"type":66,"tag":116,"props":1207,"children":1208},{},[1209,1214,1216,1223,1224,1231],{"type":66,"tag":120,"props":1210,"children":1211},{},[1212],{"type":71,"value":1213},"client:",{"type":71,"value":1215}," prevent useCookie usage outside of effect scope (",{"type":66,"tag":128,"props":1217,"children":1220},{"href":1218,"rel":1219},"https://github.com/nuxt-community/supabase-module/issues/309",[132],[1221],{"type":71,"value":1222},"#309",{"type":71,"value":730},{"type":66,"tag":128,"props":1225,"children":1228},{"href":1226,"rel":1227},"https://github.com/nuxt-community/supabase-module/commit/bb55bed870efb68c39f255ddbcbe0b5446965399",[132],[1229],{"type":71,"value":1230},"bb55bed",{"type":71,"value":255},{"type":66,"tag":67,"props":1233,"children":1234},{},[1235,1237],{"type":71,"value":1236},"💚 Thanks for the help from 💚\r\n",{"type":66,"tag":128,"props":1238,"children":1241},{"href":1239,"rel":1240},"https://github.com/AlbertBrand",[132],[1242],{"type":66,"tag":120,"props":1243,"children":1244},{},[1245],{"type":71,"value":1246},"@AlbertBrand",{"title":59,"searchDepth":78,"depth":78,"links":1248},[1249],{"id":100,"depth":78,"text":103,"children":1250},[1251],{"id":107,"depth":160,"text":110},"https://github.com/nuxt-modules/supabase/releases/tag/v1.1.4","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.1.4","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.1.4",{"url":1256,"total_count":161,"+1":161,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":294,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/129966845/reactions",{"name":166,"url":167,"avatar":168},"github:v1.1.4.md",{"name":1260,"tag_name":1260,"date":1261,"body":1262,"v":161,"url":1358,"tarball":1359,"zipball":1360,"prerelease":60,"reactions":1361,"author":1363,"title":59,"description":59,"_type":80,"_id":1364},"v1.1.3","2023-10-06T07:51:37Z",{"type":63,"children":1263,"toc":1355},[1264,1268,1330],{"type":66,"tag":98,"props":1265,"children":1266},{"id":100},[1267],{"type":71,"value":103},{"type":66,"tag":112,"props":1269,"children":1270},{},[1271,1304],{"type":66,"tag":116,"props":1272,"children":1273},{},[1274,1278,1280,1287,1288,1295,1296,1303],{"type":66,"tag":120,"props":1275,"children":1276},{},[1277],{"type":71,"value":1213},{"type":71,"value":1279}," clientOptions merge",{"type":66,"tag":128,"props":1281,"children":1284},{"href":1282,"rel":1283},"https://github.com/nuxt-community/supabase-module/issues/275",[132],[1285],{"type":71,"value":1286},"#275",{"type":71,"value":501},{"type":66,"tag":128,"props":1289,"children":1292},{"href":1290,"rel":1291},"https://github.com/nuxt-community/supabase-module/issues/277",[132],[1293],{"type":71,"value":1294},"#277",{"type":71,"value":730},{"type":66,"tag":128,"props":1297,"children":1300},{"href":1298,"rel":1299},"https://github.com/nuxt-community/supabase-module/commit/c0097a355b859cb6a2d97884a7648284128acca2",[132],[1301],{"type":71,"value":1302},"c0097a3",{"type":71,"value":255},{"type":66,"tag":116,"props":1305,"children":1306},{},[1307,1312,1314,1321,1322,1329],{"type":66,"tag":120,"props":1308,"children":1309},{},[1310],{"type":71,"value":1311},"module:",{"type":71,"value":1313}," do not warn when using runtimeConfig to set url and key (",{"type":66,"tag":128,"props":1315,"children":1318},{"href":1316,"rel":1317},"https://github.com/nuxt-community/supabase-module/issues/281",[132],[1319],{"type":71,"value":1320},"#281",{"type":71,"value":730},{"type":66,"tag":128,"props":1323,"children":1326},{"href":1324,"rel":1325},"https://github.com/nuxt-community/supabase-module/commit/8c151737b55738c68fc24b5e4db2517c4e866693",[132],[1327],{"type":71,"value":1328},"8c15173",{"type":71,"value":255},{"type":66,"tag":67,"props":1331,"children":1332},{},[1333,1334,1344,1345],{"type":71,"value":1236},{"type":66,"tag":128,"props":1335,"children":1338},{"href":1336,"rel":1337},"https://github.com/stafyniaksacha",[132],[1339],{"type":66,"tag":120,"props":1340,"children":1341},{},[1342],{"type":71,"value":1343},"@stafyniaksacha",{"type":71,"value":1133},{"type":66,"tag":128,"props":1346,"children":1349},{"href":1347,"rel":1348},"https://github.com/jonesisg1",[132],[1350],{"type":66,"tag":120,"props":1351,"children":1352},{},[1353],{"type":71,"value":1354},"@jonesisg1",{"title":59,"searchDepth":78,"depth":78,"links":1356},[1357],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v1.1.3","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.1.3","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.1.3",{"url":1362,"total_count":585,"+1":78,"-1":294,"laugh":294,"hooray":78,"confused":294,"heart":294,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/123992311/reactions",{"name":166,"url":167,"avatar":168},"github:v1.1.3.md",{"name":1366,"tag_name":1366,"date":1367,"body":1368,"v":161,"url":1598,"tarball":1599,"zipball":1600,"prerelease":60,"reactions":1601,"author":1603,"title":59,"description":59,"_type":80,"_id":1604},"v1.1.2","2023-09-06T17:44:35Z",{"type":63,"children":1369,"toc":1593},[1370,1374,1396,1439,1443,1521,1537],{"type":66,"tag":98,"props":1371,"children":1372},{"id":100},[1373],{"type":71,"value":103},{"type":66,"tag":67,"props":1375,"children":1376},{},[1377,1379,1386,1388,1394],{"type":71,"value":1378},"⚠️ BREAKING CHANGE ⚠️\r\nBreaking change is related to ",{"type":66,"tag":128,"props":1380,"children":1383},{"href":1381,"rel":1382},"https://github.com/nuxt-modules/supabase/issues/244",[132],[1384],{"type":71,"value":1385},"#244",{"type":71,"value":1387}," and was first adressed in the ",{"type":66,"tag":312,"props":1389,"children":1391},{"className":1390},[],[1392],{"type":71,"value":1393},"v1.1.0",{"type":71,"value":1395}," but patch has been necessary to fix the version.",{"type":66,"tag":67,"props":1397,"children":1398},{},[1399,1401,1407,1409,1415,1417,1423,1425,1431,1433],{"type":71,"value":1400},"On the confirm page, configured in ",{"type":66,"tag":312,"props":1402,"children":1404},{"className":1403},[],[1405],{"type":71,"value":1406},"redirect.callback",{"type":71,"value":1408}," option (default to ",{"type":66,"tag":312,"props":1410,"children":1412},{"className":1411},[],[1413],{"type":71,"value":1414},"/confirm",{"type":71,"value":1416},"), ensure to set the ",{"type":66,"tag":312,"props":1418,"children":1420},{"className":1419},[],[1421],{"type":71,"value":1422},"immediate",{"type":71,"value":1424}," option in the watch.\r\nCheck out the doc: ",{"type":66,"tag":128,"props":1426,"children":1429},{"href":1427,"rel":1428},"http://supabase.nuxtjs.org/authentication#confirm-page-confirm",[132],[1430],{"type":71,"value":1427},{"type":71,"value":1432},"\r\nCheck out the demo code: ",{"type":66,"tag":128,"props":1434,"children":1437},{"href":1435,"rel":1436},"https://github.com/nuxt-modules/supabase/blob/main/demo/pages/confirm.vue",[132],[1438],{"type":71,"value":1435},{"type":66,"tag":105,"props":1440,"children":1441},{"id":107},[1442],{"type":71,"value":110},{"type":66,"tag":112,"props":1444,"children":1445},{},[1446,1471,1495],{"type":66,"tag":116,"props":1447,"children":1448},{},[1449,1453,1455,1462,1463,1470],{"type":66,"tag":120,"props":1450,"children":1451},{},[1452],{"type":71,"value":1311},{"type":71,"value":1454}," priority of redirect options made by defu (",{"type":66,"tag":128,"props":1456,"children":1459},{"href":1457,"rel":1458},"https://github.com/nuxt-community/supabase-module/issues/256",[132],[1460],{"type":71,"value":1461},"#256",{"type":71,"value":730},{"type":66,"tag":128,"props":1464,"children":1467},{"href":1465,"rel":1466},"https://github.com/nuxt-community/supabase-module/commit/c4e30bf50eb7816fee3a2e46b404df5ce9f7cf4d",[132],[1468],{"type":71,"value":1469},"c4e30bf",{"type":71,"value":255},{"type":66,"tag":116,"props":1472,"children":1473},{},[1474,1479,1481,1486,1487,1494],{"type":66,"tag":120,"props":1475,"children":1476},{},[1477],{"type":71,"value":1478},"plugin:",{"type":71,"value":1480}," retrieve user for client only page (",{"type":66,"tag":128,"props":1482,"children":1484},{"href":1381,"rel":1483},[132],[1485],{"type":71,"value":1385},{"type":71,"value":730},{"type":66,"tag":128,"props":1488,"children":1491},{"href":1489,"rel":1490},"https://github.com/nuxt-community/supabase-module/commit/4a35428e26542bf22b3288db6e9a9309f1310705",[132],[1492],{"type":71,"value":1493},"4a35428",{"type":71,"value":255},{"type":66,"tag":116,"props":1496,"children":1497},{},[1498,1503,1505,1512,1513,1520],{"type":66,"tag":120,"props":1499,"children":1500},{},[1501],{"type":71,"value":1502},"useSupabaseUser:",{"type":71,"value":1504}," add explicit user type (",{"type":66,"tag":128,"props":1506,"children":1509},{"href":1507,"rel":1508},"https://github.com/nuxt-community/supabase-module/issues/254",[132],[1510],{"type":71,"value":1511},"#254",{"type":71,"value":730},{"type":66,"tag":128,"props":1514,"children":1517},{"href":1515,"rel":1516},"https://github.com/nuxt-community/supabase-module/commit/60d8551ee83a9c64a962b9f76b881b17d7384736",[132],[1518],{"type":71,"value":1519},"60d8551",{"type":71,"value":255},{"type":66,"tag":67,"props":1522,"children":1523},{},[1524,1529,1531],{"type":66,"tag":120,"props":1525,"children":1526},{},[1527],{"type":71,"value":1528},"Full Changelog",{"type":71,"value":1530},": ",{"type":66,"tag":128,"props":1532,"children":1535},{"href":1533,"rel":1534},"https://github.com/nuxt-community/supabase-module/compare/v1.0.2...v1.1.0",[132],[1536],{"type":71,"value":1533},{"type":66,"tag":67,"props":1538,"children":1539},{},[1540,1541,1551,1552,1562,1563,1571,1572,1582,1583],{"type":71,"value":1236},{"type":66,"tag":128,"props":1542,"children":1545},{"href":1543,"rel":1544},"https://github.com/52cs",[132],[1546],{"type":66,"tag":120,"props":1547,"children":1548},{},[1549],{"type":71,"value":1550},"@52cs",{"type":71,"value":1133},{"type":66,"tag":128,"props":1553,"children":1556},{"href":1554,"rel":1555},"https://github.com/Aietes",[132],[1557],{"type":66,"tag":120,"props":1558,"children":1559},{},[1560],{"type":71,"value":1561},"@Aietes",{"type":71,"value":1133},{"type":66,"tag":128,"props":1564,"children":1566},{"href":1239,"rel":1565},[132],[1567],{"type":66,"tag":120,"props":1568,"children":1569},{},[1570],{"type":71,"value":1246},{"type":71,"value":1133},{"type":66,"tag":128,"props":1573,"children":1576},{"href":1574,"rel":1575},"https://github.com/kiri10ten",[132],[1577],{"type":66,"tag":120,"props":1578,"children":1579},{},[1580],{"type":71,"value":1581},"@kiri10ten",{"type":71,"value":1133},{"type":66,"tag":128,"props":1584,"children":1587},{"href":1585,"rel":1586},"https://github.com/xMorthi",[132],[1588],{"type":66,"tag":120,"props":1589,"children":1590},{},[1591],{"type":71,"value":1592},"@xMorthi",{"title":59,"searchDepth":78,"depth":78,"links":1594},[1595],{"id":100,"depth":78,"text":103,"children":1596},[1597],{"id":107,"depth":160,"text":110},"https://github.com/nuxt-modules/supabase/releases/tag/v1.1.2","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.1.2","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.1.2",{"url":1602,"total_count":585,"+1":294,"-1":294,"laugh":294,"hooray":160,"confused":294,"heart":294,"rocket":294,"eyes":161},"https://api.github.com/repos/nuxt-modules/supabase/releases/120162649/reactions",{"name":166,"url":167,"avatar":168},"github:v1.1.2.md",{"name":1606,"tag_name":1606,"date":1607,"body":1608,"v":161,"url":1691,"tarball":1692,"zipball":1693,"prerelease":60,"reactions":1694,"author":1696,"title":59,"description":59,"_type":80,"_id":1697},"v1.0.2","2023-08-04T15:56:13Z",{"type":63,"children":1609,"toc":1688},[1610,1614,1651,1665],{"type":66,"tag":98,"props":1611,"children":1612},{"id":100},[1613],{"type":71,"value":103},{"type":66,"tag":112,"props":1615,"children":1616},{},[1617,1634],{"type":66,"tag":116,"props":1618,"children":1619},{},[1620,1622,1633],{"type":71,"value":1621},"docs(auth): update (",{"type":66,"tag":128,"props":1623,"children":1626},{"href":1624,"rel":1625},"https://github.com/nuxt-modules/supabase/commit/df00ffe8ecc253fc23572b65465ad7928e185b13",[132],[1627],{"type":66,"tag":312,"props":1628,"children":1630},{"className":1629},[],[1631],{"type":71,"value":1632},"df00ffe",{"type":71,"value":255},{"type":66,"tag":116,"props":1635,"children":1636},{},[1637,1639,1650],{"type":71,"value":1638},"fix(client): correct provider_token assignment to cookie (",{"type":66,"tag":128,"props":1640,"children":1643},{"href":1641,"rel":1642},"https://github.com/nuxt-modules/supabase/commit/a76df3f67d6b08daf359f38130ce08aeab57317b",[132],[1644],{"type":66,"tag":312,"props":1645,"children":1647},{"className":1646},[],[1648],{"type":71,"value":1649},"a76df3f",{"type":71,"value":255},{"type":66,"tag":67,"props":1652,"children":1653},{},[1654,1658,1659],{"type":66,"tag":120,"props":1655,"children":1656},{},[1657],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":1660,"children":1663},{"href":1661,"rel":1662},"https://github.com/nuxt-community/supabase-module/compare/v1.0.1...v1.0.2",[132],[1664],{"type":71,"value":1661},{"type":66,"tag":67,"props":1666,"children":1667},{},[1668,1669,1679,1680],{"type":71,"value":1236},{"type":66,"tag":128,"props":1670,"children":1673},{"href":1671,"rel":1672},"https://github.com/blqke",[132],[1674],{"type":66,"tag":120,"props":1675,"children":1676},{},[1677],{"type":71,"value":1678},"@blqke",{"type":71,"value":1133},{"type":66,"tag":128,"props":1681,"children":1683},{"href":1554,"rel":1682},[132],[1684],{"type":66,"tag":120,"props":1685,"children":1686},{},[1687],{"type":71,"value":1561},{"title":59,"searchDepth":78,"depth":78,"links":1689},[1690],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v1.0.2","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.0.2","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.0.2",{"url":1695,"total_count":160,"+1":294,"-1":294,"laugh":294,"hooray":160,"confused":294,"heart":294,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/115135546/reactions",{"name":166,"url":167,"avatar":168},"github:v1.0.2.md",{"name":1699,"tag_name":1699,"date":1700,"body":1701,"v":161,"url":1990,"tarball":1991,"zipball":1992,"prerelease":60,"reactions":1993,"author":1999,"title":59,"description":2000,"_type":80,"_id":2001},"v1.0.1","2023-08-02T15:46:15Z",{"type":63,"children":1702,"toc":1987},[1703,1716,1721,1789,1794,1815,1819,1824,1953,1969,1972],{"type":66,"tag":67,"props":1704,"children":1705},{},[1706,1708,1714],{"type":71,"value":1707},"I am happy to announce the release of version ",{"type":66,"tag":312,"props":1709,"children":1711},{"className":1710},[],[1712],{"type":71,"value":1713},"1.0.0",{"type":71,"value":1715}," of this module. While the module has been production-ready for quite some time, I never had the opportunity to create the first major version until now. Given that this version incorporates significant changes, I believe it is the perfect moment to establish this initial major release.",{"type":66,"tag":98,"props":1717,"children":1718},{"id":100},[1719],{"type":71,"value":1720},"What's changed",{"type":66,"tag":112,"props":1722,"children":1723},{},[1724,1746,1751],{"type":66,"tag":116,"props":1725,"children":1726},{},[1727,1729,1736,1738,1745],{"type":71,"value":1728},"Supabase introduced a new authentication flow (PKCE) a few months ago, which is now the default behavior of the module. However, you can still revert to the old (and less secure) authentication method through the module configuration. To help you seamlessly integrate this new flow, a ",{"type":66,"tag":128,"props":1730,"children":1733},{"href":1731,"rel":1732},"https://supabase.nuxtjs.org/authentication",[132],[1734],{"type":71,"value":1735},"dedicated section",{"type":71,"value":1737}," has been added to the documentation. (",{"type":66,"tag":128,"props":1739,"children":1742},{"href":1740,"rel":1741},"https://github.com/nuxt-modules/supabase/issues/219",[132],[1743],{"type":71,"value":1744},"#219",{"type":71,"value":255},{"type":66,"tag":116,"props":1747,"children":1748},{},[1749],{"type":71,"value":1750},"Building upon the previous point, we have implemented substantial changes to the session management, involving alterations to how Supabase clients are instantiated and how sessions are synchronized between the server and client-side. Consequently, these changes result in some breaking changes, which are listed below.",{"type":66,"tag":116,"props":1752,"children":1753},{},[1754,1756,1763,1765,1772,1774,1781,1783],{"type":71,"value":1755},"A brand new documentation has been built entirely using ",{"type":66,"tag":128,"props":1757,"children":1760},{"href":1758,"rel":1759},"https://nuxt.studio",[132],[1761],{"type":71,"value":1762},"Nuxt Studio",{"type":71,"value":1764},". Feel free to create PRs to suggest fixes or add any necessary changes to further enhance the documentation. (",{"type":66,"tag":128,"props":1766,"children":1769},{"href":1767,"rel":1768},"https://github.com/nuxt-modules/supabase/issues/210",[132],[1770],{"type":71,"value":1771},"#210",{"type":71,"value":1773}," / ",{"type":66,"tag":128,"props":1775,"children":1778},{"href":1776,"rel":1777},"https://github.com/nuxt-modules/supabase/issues/221",[132],[1779],{"type":71,"value":1780},"#221",{"type":71,"value":1782},") => ",{"type":66,"tag":128,"props":1784,"children":1787},{"href":1785,"rel":1786},"https://supabase.nuxtjs.org",[132],[1788],{"type":71,"value":1785},{"type":66,"tag":67,"props":1790,"children":1791},{},[1792],{"type":71,"value":1793},"Here's documentation that can help you understand the PKCE authentication flow:",{"type":66,"tag":112,"props":1795,"children":1796},{},[1797,1806],{"type":66,"tag":116,"props":1798,"children":1799},{},[1800],{"type":66,"tag":128,"props":1801,"children":1804},{"href":1802,"rel":1803},"https://supabase.com/blog/supabase-auth-sso-pkce#server-side-and-mobile-auth",[132],[1805],{"type":71,"value":1802},{"type":66,"tag":116,"props":1807,"children":1808},{},[1809],{"type":66,"tag":128,"props":1810,"children":1813},{"href":1811,"rel":1812},"https://supabase.com/docs/guides/resources/glossary#pkce",[132],[1814],{"type":71,"value":1811},{"type":66,"tag":1816,"props":1817,"children":1818},"br",{},[],{"type":66,"tag":67,"props":1820,"children":1821},{},[1822],{"type":71,"value":1823},"⚠️ BREAKING CHANGES ⚠️",{"type":66,"tag":112,"props":1825,"children":1826},{},[1827,1845,1871,1890,1918],{"type":66,"tag":116,"props":1828,"children":1829},{},[1830,1836,1838,1843],{"type":66,"tag":312,"props":1831,"children":1833},{"className":1832},[],[1834],{"type":71,"value":1835},"useSupabaseAuthClient",{"type":71,"value":1837}," has been removed in favor of ",{"type":66,"tag":312,"props":1839,"children":1841},{"className":1840},[],[1842],{"type":71,"value":21},{"type":71,"value":1844}," in all cases",{"type":66,"tag":116,"props":1846,"children":1847},{},[1848,1853,1855,1861,1863,1869],{"type":66,"tag":312,"props":1849,"children":1851},{"className":1850},[],[1852],{"type":71,"value":34},{"type":71,"value":1854}," is now returning a promise (should be called with ",{"type":66,"tag":312,"props":1856,"children":1858},{"className":1857},[],[1859],{"type":71,"value":1860},"await",{"type":71,"value":1862}," in an ",{"type":66,"tag":312,"props":1864,"children":1866},{"className":1865},[],[1867],{"type":71,"value":1868},"async",{"type":71,"value":1870}," method)",{"type":66,"tag":116,"props":1872,"children":1873},{},[1874,1880,1882,1888],{"type":66,"tag":312,"props":1875,"children":1877},{"className":1876},[],[1878],{"type":71,"value":1879},"redirect",{"type":71,"value":1881}," option is enable by default, follow this ",{"type":66,"tag":128,"props":1883,"children":1885},{"href":1731,"rel":1884},[132],[1886],{"type":71,"value":1887},"guide",{"type":71,"value":1889}," to update your app",{"type":66,"tag":116,"props":1891,"children":1892},{},[1893,1899,1901,1907,1909,1916],{"type":66,"tag":312,"props":1894,"children":1896},{"className":1895},[],[1897],{"type":71,"value":1898},"client",{"type":71,"value":1900}," option becomes ",{"type":66,"tag":312,"props":1902,"children":1904},{"className":1903},[],[1905],{"type":71,"value":1906},"clientOptions",{"type":71,"value":1908}," with new ",{"type":66,"tag":128,"props":1910,"children":1913},{"href":1911,"rel":1912},"https://supabase.nuxtjs.org/get-started#clientoptions",[132],[1914],{"type":71,"value":1915},"default value",{"type":71,"value":1917}," (including the PKCE flow)",{"type":66,"tag":116,"props":1919,"children":1920},{},[1921,1927,1929,1935,1936,1942,1944,1951],{"type":66,"tag":312,"props":1922,"children":1924},{"className":1923},[],[1925],{"type":71,"value":1926},"cookies",{"type":71,"value":1928}," options is split in ",{"type":66,"tag":312,"props":1930,"children":1932},{"className":1931},[],[1933],{"type":71,"value":1934},"cookieName",{"type":71,"value":713},{"type":66,"tag":312,"props":1937,"children":1939},{"className":1938},[],[1940],{"type":71,"value":1941},"cookieOptions",{"type":71,"value":1943},", ",{"type":66,"tag":128,"props":1945,"children":1948},{"href":1946,"rel":1947},"https://supabase.nuxtjs.org/get-started#cookieoptions",[132],[1949],{"type":71,"value":1950},"default values",{"type":71,"value":1952}," have not changed",{"type":66,"tag":67,"props":1954,"children":1955},{},[1956,1958],{"type":71,"value":1957},"Here si the commit done for updating the demo with the last version: ",{"type":66,"tag":128,"props":1959,"children":1962},{"href":1960,"rel":1961},"https://github.com/nuxt-modules/supabase/commit/10e05860862b68c49817f6420d50d082452f7a7f",[132],[1963],{"type":66,"tag":312,"props":1964,"children":1966},{"className":1965},[],[1967],{"type":71,"value":1968},"10e0586",{"type":66,"tag":1816,"props":1970,"children":1971},{},[],{"type":66,"tag":67,"props":1973,"children":1974},{},[1975,1977,1985],{"type":71,"value":1976},"A huge thanks to ",{"type":66,"tag":128,"props":1978,"children":1980},{"href":1554,"rel":1979},[132],[1981],{"type":66,"tag":120,"props":1982,"children":1983},{},[1984],{"type":71,"value":1561},{"type":71,"value":1986}," for initialising all those changes and help me built it 💚",{"title":59,"searchDepth":78,"depth":78,"links":1988},[1989],{"id":100,"depth":78,"text":1720},"https://github.com/nuxt-modules/supabase/releases/tag/v1.0.1","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.0.1","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.0.1",{"url":1994,"total_count":1995,"+1":1996,"-1":294,"laugh":294,"hooray":1997,"confused":294,"heart":585,"rocket":1998,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/114843996/reactions",40,9,19,8,{"name":166,"url":167,"avatar":168},"I am happy to announce the release of version 1.0.0 of this module. While the module has been production-ready for quite some time, I never had the opportunity to create the first major version until now. Given that this version incorporates significant changes, I believe it is the perfect moment to establish this initial major release.","github:v1.0.1.md",{"name":2003,"tag_name":2003,"date":2004,"body":2005,"v":294,"url":2097,"tarball":2098,"zipball":2099,"prerelease":60,"reactions":2100,"author":2102,"title":59,"description":59,"_type":80,"_id":2103},"v0.3.8","2023-07-03T08:29:53Z",{"type":63,"children":2006,"toc":2094},[2007,2011,2068,2082],{"type":66,"tag":98,"props":2008,"children":2009},{"id":100},[2010],{"type":71,"value":103},{"type":66,"tag":112,"props":2012,"children":2013},{},[2014,2051],{"type":66,"tag":116,"props":2015,"children":2016},{},[2017,2019,2030,2032,2039,2041],{"type":71,"value":2018},"feat(session): save provider access/refresh tokens in cookies (",{"type":66,"tag":128,"props":2020,"children":2023},{"href":2021,"rel":2022},"https://github.com/nuxt-modules/supabase/commit/ea8c21f3d625984832cb27a3ae7605b16caaf94b",[132],[2024],{"type":66,"tag":312,"props":2025,"children":2027},{"className":2026},[],[2028],{"type":71,"value":2029},"ea8c21f",{"type":71,"value":2031},") in ",{"type":66,"tag":128,"props":2033,"children":2036},{"href":2034,"rel":2035},"https://github.com/nuxt-modules/supabase/issues/197",[132],[2037],{"type":71,"value":2038},"#197",{"type":71,"value":2040}," by ",{"type":66,"tag":128,"props":2042,"children":2045},{"href":2043,"rel":2044},"https://github.com/mitjans",[132],[2046],{"type":66,"tag":120,"props":2047,"children":2048},{},[2049],{"type":71,"value":2050},"@mitjans",{"type":66,"tag":116,"props":2052,"children":2053},{},[2054,2056,2067],{"type":71,"value":2055},"chore(deps): upgrade to latest (",{"type":66,"tag":128,"props":2057,"children":2060},{"href":2058,"rel":2059},"https://github.com/nuxt-modules/supabase/commit/a52abc871b6ab756c2b477f7c6b3c0f51279693c",[132],[2061],{"type":66,"tag":312,"props":2062,"children":2064},{"className":2063},[],[2065],{"type":71,"value":2066},"a52abc8",{"type":71,"value":255},{"type":66,"tag":67,"props":2069,"children":2070},{},[2071,2075,2076],{"type":66,"tag":120,"props":2072,"children":2073},{},[2074],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":2077,"children":2080},{"href":2078,"rel":2079},"https://github.com/nuxt-community/supabase-module/compare/v0.3.7...v0.3.8",[132],[2081],{"type":71,"value":2078},{"type":66,"tag":67,"props":2083,"children":2084},{},[2085,2086],{"type":71,"value":1236},{"type":66,"tag":128,"props":2087,"children":2089},{"href":2043,"rel":2088},[132],[2090],{"type":66,"tag":120,"props":2091,"children":2092},{},[2093],{"type":71,"value":2050},{"title":59,"searchDepth":78,"depth":78,"links":2095},[2096],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.3.8","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.3.8","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.3.8",{"url":2101,"total_count":685,"+1":294,"-1":294,"laugh":294,"hooray":685,"confused":294,"heart":294,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/110829614/reactions",{"name":166,"url":167,"avatar":168},"github:v0.3.8.md",{"name":2105,"tag_name":2105,"date":2106,"body":2107,"v":294,"url":2176,"tarball":2177,"zipball":2178,"prerelease":60,"author":2179,"title":59,"description":59,"_type":80,"_id":2180},"v0.3.7","2023-06-12T07:51:13Z",{"type":63,"children":2108,"toc":2173},[2109,2113,2159],{"type":66,"tag":98,"props":2110,"children":2111},{"id":100},[2112],{"type":71,"value":103},{"type":66,"tag":112,"props":2114,"children":2115},{},[2116,2142],{"type":66,"tag":116,"props":2117,"children":2118},{},[2119,2121,2126,2127,2134,2135],{"type":71,"value":2120},"fix(client): fix persist session warning for ",{"type":66,"tag":312,"props":2122,"children":2124},{"className":2123},[],[2125],{"type":71,"value":37},{"type":71,"value":501},{"type":66,"tag":128,"props":2128,"children":2131},{"href":2129,"rel":2130},"https://github.com/nuxt-modules/supabase/issues/194",[132],[2132],{"type":71,"value":2133},"#194",{"type":71,"value":137},{"type":66,"tag":128,"props":2136,"children":2139},{"href":2137,"rel":2138},"https://github.com/nuxt-modules/supabase/issues/193",[132],[2140],{"type":71,"value":2141},"#193",{"type":66,"tag":116,"props":2143,"children":2144},{},[2145,2147,2158],{"type":71,"value":2146},"docs(get-started): remove defineNuxtConfig (",{"type":66,"tag":128,"props":2148,"children":2151},{"href":2149,"rel":2150},"https://github.com/nuxt-modules/supabase/commit/0151901",[132],[2152],{"type":66,"tag":312,"props":2153,"children":2155},{"className":2154},[],[2156],{"type":71,"value":2157},"0151901",{"type":71,"value":255},{"type":66,"tag":67,"props":2160,"children":2161},{},[2162,2163],{"type":71,"value":1236},{"type":66,"tag":128,"props":2164,"children":2167},{"href":2165,"rel":2166},"https://github.com/jawngee",[132],[2168],{"type":66,"tag":120,"props":2169,"children":2170},{},[2171],{"type":71,"value":2172},"@jawngee",{"title":59,"searchDepth":78,"depth":78,"links":2174},[2175],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.3.7","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.3.7","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.3.7",{"name":166,"url":167,"avatar":168},"github:v0.3.7.md",{"name":2182,"tag_name":2182,"date":2183,"body":2184,"v":294,"url":2240,"tarball":2241,"zipball":2242,"prerelease":60,"reactions":2243,"author":2245,"title":59,"description":59,"_type":80,"_id":2246},"v0.3.6","2023-06-02T14:33:38Z",{"type":63,"children":2185,"toc":2237},[2186,2190],{"type":66,"tag":98,"props":2187,"children":2188},{"id":100},[2189],{"type":71,"value":103},{"type":66,"tag":112,"props":2191,"children":2192},{},[2193,2198,2224],{"type":66,"tag":116,"props":2194,"children":2195},{},[2196],{"type":71,"value":2197},"chore(deps): upgrade to nuxt and supabase latest version",{"type":66,"tag":116,"props":2199,"children":2200},{},[2201,2203,2214,2216,2223],{"type":71,"value":2202},"fix(client): remove persist session warning on server side in ",{"type":66,"tag":128,"props":2204,"children":2207},{"href":2205,"rel":2206},"https://github.com/nuxt-modules/supabase/commit/227113f68fb8723f9687adfa12150f825940e0c9",[132],[2208],{"type":66,"tag":312,"props":2209,"children":2211},{"className":2210},[],[2212],{"type":71,"value":2213},"227113f",{"type":71,"value":2215}," (Resolves ",{"type":66,"tag":128,"props":2217,"children":2220},{"href":2218,"rel":2219},"https://github.com/nuxt-modules/supabase/issues/188",[132],[2221],{"type":71,"value":2222},"#188",{"type":71,"value":255},{"type":66,"tag":116,"props":2225,"children":2226},{},[2227,2229,2236],{"type":71,"value":2228},"fix(chore): resolve imports (Resolves ",{"type":66,"tag":128,"props":2230,"children":2233},{"href":2231,"rel":2232},"https://github.com/nuxt-modules/supabase/issues/190",[132],[2234],{"type":71,"value":2235},"#190",{"type":71,"value":255},{"title":59,"searchDepth":78,"depth":78,"links":2238},[2239],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.3.6","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.3.6","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.3.6",{"url":2244,"total_count":685,"+1":161,"-1":294,"laugh":294,"hooray":585,"confused":294,"heart":294,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/105847469/reactions",{"name":166,"url":167,"avatar":168},"github:v0.3.6.md",{"name":2248,"tag_name":2248,"date":2249,"body":2250,"v":294,"url":2539,"tarball":2540,"zipball":2541,"prerelease":60,"reactions":2542,"author":2544,"title":59,"description":59,"_type":80,"_id":2545},"v0.3.5","2023-04-03T09:50:57Z",{"type":63,"children":2251,"toc":2536},[2252,2256,2485,2499],{"type":66,"tag":98,"props":2253,"children":2254},{"id":100},[2255],{"type":71,"value":103},{"type":66,"tag":112,"props":2257,"children":2258},{},[2259,2276,2293,2310,2327,2344,2361,2378,2395,2412,2444,2461],{"type":66,"tag":116,"props":2260,"children":2261},{},[2262,2264,2275],{"type":71,"value":2263},"chore(demo): upgrade on last version (",{"type":66,"tag":128,"props":2265,"children":2268},{"href":2266,"rel":2267},"https://github.com/nuxt-modules/supabase/commit/9bb9e2856823a0bb86c07ae7775462e02a1e430d",[132],[2269],{"type":66,"tag":312,"props":2270,"children":2272},{"className":2271},[],[2273],{"type":71,"value":2274},"9bb9e28",{"type":71,"value":255},{"type":66,"tag":116,"props":2277,"children":2278},{},[2279,2281,2292],{"type":71,"value":2280},"chore(demo): generate database types from supabase cli (",{"type":66,"tag":128,"props":2282,"children":2285},{"href":2283,"rel":2284},"https://github.com/nuxt-modules/supabase/commit/bca199292dfeb23d5e0581ab40a6994fed3d1157",[132],[2286],{"type":66,"tag":312,"props":2287,"children":2289},{"className":2288},[],[2290],{"type":71,"value":2291},"bca1992",{"type":71,"value":255},{"type":66,"tag":116,"props":2294,"children":2295},{},[2296,2298,2309],{"type":71,"value":2297},"docs(links): update nuxt & supabase links and fix typos (",{"type":66,"tag":128,"props":2299,"children":2302},{"href":2300,"rel":2301},"https://github.com/nuxt-modules/supabase/commit/5699dc6c22f9182e9593936fc1260fc785eea450",[132],[2303],{"type":66,"tag":312,"props":2304,"children":2306},{"className":2305},[],[2307],{"type":71,"value":2308},"5699dc6",{"type":71,"value":255},{"type":66,"tag":116,"props":2311,"children":2312},{},[2313,2315,2326],{"type":71,"value":2314},"chore(app): move to pnpm (",{"type":66,"tag":128,"props":2316,"children":2319},{"href":2317,"rel":2318},"https://github.com/nuxt-modules/supabase/commit/94f7e130747801584d2b0999bd2f5f904e575082",[132],[2320],{"type":66,"tag":312,"props":2321,"children":2323},{"className":2322},[],[2324],{"type":71,"value":2325},"94f7e13",{"type":71,"value":255},{"type":66,"tag":116,"props":2328,"children":2329},{},[2330,2332,2343],{"type":71,"value":2331},"chore(module): conditionally add redirect plugin (",{"type":66,"tag":128,"props":2333,"children":2336},{"href":2334,"rel":2335},"https://github.com/nuxt-modules/supabase/commit/0cad0a557934f669f2ab424ef072f6b07c098646",[132],[2337],{"type":66,"tag":312,"props":2338,"children":2340},{"className":2339},[],[2341],{"type":71,"value":2342},"0cad0a5",{"type":71,"value":255},{"type":66,"tag":116,"props":2345,"children":2346},{},[2347,2349,2360],{"type":71,"value":2348},"docs(get-started): fix typos (",{"type":66,"tag":128,"props":2350,"children":2353},{"href":2351,"rel":2352},"https://github.com/nuxt-modules/supabase/commit/ba437a8534f3dcda53f805cc34b5d6a943297354",[132],[2354],{"type":66,"tag":312,"props":2355,"children":2357},{"className":2356},[],[2358],{"type":71,"value":2359},"ba437a8",{"type":71,"value":255},{"type":66,"tag":116,"props":2362,"children":2363},{},[2364,2366,2377],{"type":71,"value":2365},"docs(composables): correct grammar errors (",{"type":66,"tag":128,"props":2367,"children":2370},{"href":2368,"rel":2369},"https://github.com/nuxt-modules/supabase/commit/034d7dfaf9f52a08da0ade4bf6d5ed31ec740734",[132],[2371],{"type":66,"tag":312,"props":2372,"children":2374},{"className":2373},[],[2375],{"type":71,"value":2376},"034d7df",{"type":71,"value":255},{"type":66,"tag":116,"props":2379,"children":2380},{},[2381,2383,2394],{"type":71,"value":2382},"feat(demo): add call from server route(",{"type":66,"tag":128,"props":2384,"children":2387},{"href":2385,"rel":2386},"https://github.com/nuxt-modules/supabase/commit/989a91eacdc471de90a2307c39cd03f23cca57ee",[132],[2388],{"type":66,"tag":312,"props":2389,"children":2391},{"className":2390},[],[2392],{"type":71,"value":2393},"989a91e",{"type":71,"value":255},{"type":66,"tag":116,"props":2396,"children":2397},{},[2398,2400,2411],{"type":71,"value":2399},"perf(useSupabaseAuthClient): avoid declaring unused variables (",{"type":66,"tag":128,"props":2401,"children":2404},{"href":2402,"rel":2403},"https://github.com/nuxt-modules/supabase/commit/8c070b9e571b3fe7870c08033ea561624a6ae575",[132],[2405],{"type":66,"tag":312,"props":2406,"children":2408},{"className":2407},[],[2409],{"type":71,"value":2410},"8c070b9",{"type":71,"value":255},{"type":66,"tag":116,"props":2413,"children":2414},{},[2415,2417,2428,2429,2436,2437],{"type":71,"value":2416},"fix(dev): optimize supabase deps (",{"type":66,"tag":128,"props":2418,"children":2421},{"href":2419,"rel":2420},"https://github.com/nuxt-modules/supabase/commit/d1da3f6b2f463e7196c69c3a580833438926a6e1",[132],[2422],{"type":66,"tag":312,"props":2423,"children":2425},{"className":2424},[],[2426],{"type":71,"value":2427},"d1da3f6",{"type":71,"value":137},{"type":66,"tag":128,"props":2430,"children":2433},{"href":2431,"rel":2432},"https://github.com/nuxt-modules/supabase/issues/172",[132],[2434],{"type":71,"value":2435},"#172",{"type":71,"value":739},{"type":66,"tag":128,"props":2438,"children":2441},{"href":2439,"rel":2440},"https://github.com/nuxt-modules/supabase/issues/151",[132],[2442],{"type":71,"value":2443},"#151",{"type":66,"tag":116,"props":2445,"children":2446},{},[2447,2449,2460],{"type":71,"value":2448},"chore(deps): transpile websocket lib prod only (",{"type":66,"tag":128,"props":2450,"children":2453},{"href":2451,"rel":2452},"https://github.com/nuxt-modules/supabase/commit/a1ee40c848c9da81aa41acc53dc3555b32bafd86",[132],[2454],{"type":66,"tag":312,"props":2455,"children":2457},{"className":2456},[],[2458],{"type":71,"value":2459},"a1ee40c",{"type":71,"value":255},{"type":66,"tag":116,"props":2462,"children":2463},{},[2464,2466,2477,2478,2483],{"type":71,"value":2465},"fix(deps): transpile gotrue only on client (",{"type":66,"tag":128,"props":2467,"children":2470},{"href":2468,"rel":2469},"https://github.com/nuxt-modules/supabase/commit/fcc6823e248395a513706cf67ab664f84daacb45",[132],[2471],{"type":66,"tag":312,"props":2472,"children":2474},{"className":2473},[],[2475],{"type":71,"value":2476},"fcc6823",{"type":71,"value":137},{"type":66,"tag":128,"props":2479,"children":2481},{"href":2431,"rel":2480},[132],[2482],{"type":71,"value":2435},{"type":71,"value":2484}," on server side",{"type":66,"tag":67,"props":2486,"children":2487},{},[2488,2492,2493],{"type":66,"tag":120,"props":2489,"children":2490},{},[2491],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":2494,"children":2497},{"href":2495,"rel":2496},"https://github.com/nuxt-community/supabase-module/compare/v0.3.1...v0.3.5",[132],[2498],{"type":71,"value":2495},{"type":66,"tag":67,"props":2500,"children":2501},{},[2502,2504,2511,2513,2520,2521,2528,2529],{"type":71,"value":2503},"💚 Thanks for the help from 💚\r\n@",{"type":66,"tag":128,"props":2505,"children":2508},{"href":2506,"rel":2507},"https://github.com/nuxt-modules/supabase/commits?author=kuizuo",[132],[2509],{"type":71,"value":2510},"kuizuo",{"type":71,"value":2512},"\r\n@",{"type":66,"tag":128,"props":2514,"children":2517},{"href":2515,"rel":2516},"https://github.com/nuxt-modules/supabase/commits?author=tnntwister",[132],[2518],{"type":71,"value":2519},"tnntwister",{"type":71,"value":2512},{"type":66,"tag":128,"props":2522,"children":2525},{"href":2523,"rel":2524},"https://github.com/nuxt-modules/supabase/commits?author=yannaufray",[132],[2526],{"type":71,"value":2527},"yannaufray",{"type":71,"value":2512},{"type":66,"tag":128,"props":2530,"children":2533},{"href":2531,"rel":2532},"https://github.com/nuxt-modules/supabase/commits?author=DamianGlowala",[132],[2534],{"type":71,"value":2535},"DamianGlowala",{"title":59,"searchDepth":78,"depth":78,"links":2537},[2538],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.3.5","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.3.5","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.3.5",{"url":2543,"total_count":161,"+1":294,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":294,"rocket":161,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/97822579/reactions",{"name":166,"url":167,"avatar":168},"github:v0.3.5.md",{"name":2547,"tag_name":2547,"date":2548,"body":2549,"v":294,"url":2812,"tarball":2813,"zipball":2814,"prerelease":2815,"reactions":2816,"author":2818,"title":59,"description":59,"_type":80,"_id":2819},"v0.3.3","2023-03-31T21:51:14Z",{"type":63,"children":2550,"toc":2809},[2551,2555,2795],{"type":66,"tag":98,"props":2552,"children":2553},{"id":100},[2554],{"type":71,"value":103},{"type":66,"tag":112,"props":2556,"children":2557},{},[2558,2581,2597,2614,2631,2654,2671,2696,2719,2742,2757,2780],{"type":66,"tag":116,"props":2559,"children":2560},{},[2561,2562,2569,2570,2580],{"type":71,"value":2399},{"type":66,"tag":128,"props":2563,"children":2566},{"href":2564,"rel":2565},"https://github.com/nuxt-modules/supabase/issues/166",[132],[2567],{"type":71,"value":2568},"#166",{"type":71,"value":730},{"type":66,"tag":128,"props":2571,"children":2574},{"href":2572,"rel":2573},"https://github.com/nuxt-modules/supabase/commit/8c070b9",[132],[2575],{"type":66,"tag":312,"props":2576,"children":2578},{"className":2577},[],[2579],{"type":71,"value":2410},{"type":71,"value":255},{"type":66,"tag":116,"props":2582,"children":2583},{},[2584,2586,2596],{"type":71,"value":2585},"feat(demo): add call from server route (",{"type":66,"tag":128,"props":2587,"children":2590},{"href":2588,"rel":2589},"https://github.com/nuxt-modules/supabase/commit/989a91e",[132],[2591],{"type":66,"tag":312,"props":2592,"children":2594},{"className":2593},[],[2595],{"type":71,"value":2393},{"type":71,"value":255},{"type":66,"tag":116,"props":2598,"children":2599},{},[2600,2602,2613],{"type":71,"value":2601},"chore(demo): upgrade deps (",{"type":66,"tag":128,"props":2603,"children":2606},{"href":2604,"rel":2605},"https://github.com/nuxt-modules/supabase/commit/9ebbc77",[132],[2607],{"type":66,"tag":312,"props":2608,"children":2610},{"className":2609},[],[2611],{"type":71,"value":2612},"9ebbc77",{"type":71,"value":255},{"type":66,"tag":116,"props":2615,"children":2616},{},[2617,2619,2630],{"type":71,"value":2618},"chore(deps): upgrade (",{"type":66,"tag":128,"props":2620,"children":2623},{"href":2621,"rel":2622},"https://github.com/nuxt-modules/supabase/commit/e274a5e",[132],[2624],{"type":66,"tag":312,"props":2625,"children":2627},{"className":2626},[],[2628],{"type":71,"value":2629},"e274a5e",{"type":71,"value":255},{"type":66,"tag":116,"props":2632,"children":2633},{},[2634,2635,2642,2643,2653],{"type":71,"value":2365},{"type":66,"tag":128,"props":2636,"children":2639},{"href":2637,"rel":2638},"https://github.com/nuxt-modules/supabase/issues/162",[132],[2640],{"type":71,"value":2641},"#162",{"type":71,"value":730},{"type":66,"tag":128,"props":2644,"children":2647},{"href":2645,"rel":2646},"https://github.com/nuxt-modules/supabase/commit/034d7df",[132],[2648],{"type":66,"tag":312,"props":2649,"children":2651},{"className":2650},[],[2652],{"type":71,"value":2376},{"type":71,"value":255},{"type":66,"tag":116,"props":2655,"children":2656},{},[2657,2659,2670],{"type":71,"value":2658},"docs(readme): add nuxt badge (",{"type":66,"tag":128,"props":2660,"children":2663},{"href":2661,"rel":2662},"https://github.com/nuxt-modules/supabase/commit/68271b8",[132],[2664],{"type":66,"tag":312,"props":2665,"children":2667},{"className":2666},[],[2668],{"type":71,"value":2669},"68271b8",{"type":71,"value":255},{"type":66,"tag":116,"props":2672,"children":2673},{},[2674,2676,2683,2684,2695],{"type":71,"value":2675},"docs(demo): fix typo (",{"type":66,"tag":128,"props":2677,"children":2680},{"href":2678,"rel":2679},"https://github.com/nuxt-modules/supabase/issues/125",[132],[2681],{"type":71,"value":2682},"#125",{"type":71,"value":730},{"type":66,"tag":128,"props":2685,"children":2688},{"href":2686,"rel":2687},"https://github.com/nuxt-modules/supabase/commit/bd33d12",[132],[2689],{"type":66,"tag":312,"props":2690,"children":2692},{"className":2691},[],[2693],{"type":71,"value":2694},"bd33d12",{"type":71,"value":255},{"type":66,"tag":116,"props":2697,"children":2698},{},[2699,2700,2707,2708,2718],{"type":71,"value":2348},{"type":66,"tag":128,"props":2701,"children":2704},{"href":2702,"rel":2703},"https://github.com/nuxt-modules/supabase/issues/154",[132],[2705],{"type":71,"value":2706},"#154",{"type":71,"value":730},{"type":66,"tag":128,"props":2709,"children":2712},{"href":2710,"rel":2711},"https://github.com/nuxt-modules/supabase/commit/ba437a8",[132],[2713],{"type":66,"tag":312,"props":2714,"children":2716},{"className":2715},[],[2717],{"type":71,"value":2359},{"type":71,"value":255},{"type":66,"tag":116,"props":2720,"children":2721},{},[2722,2723,2730,2731,2741],{"type":71,"value":2331},{"type":66,"tag":128,"props":2724,"children":2727},{"href":2725,"rel":2726},"https://github.com/nuxt-modules/supabase/issues/157",[132],[2728],{"type":71,"value":2729},"#157",{"type":71,"value":730},{"type":66,"tag":128,"props":2732,"children":2735},{"href":2733,"rel":2734},"https://github.com/nuxt-modules/supabase/commit/0cad0a5",[132],[2736],{"type":66,"tag":312,"props":2737,"children":2739},{"className":2738},[],[2740],{"type":71,"value":2342},{"type":71,"value":255},{"type":66,"tag":116,"props":2743,"children":2744},{},[2745,2746,2756],{"type":71,"value":2314},{"type":66,"tag":128,"props":2747,"children":2750},{"href":2748,"rel":2749},"https://github.com/nuxt-modules/supabase/commit/94f7e13",[132],[2751],{"type":66,"tag":312,"props":2752,"children":2754},{"className":2753},[],[2755],{"type":71,"value":2325},{"type":71,"value":255},{"type":66,"tag":116,"props":2758,"children":2759},{},[2760,2761,2768,2769,2779],{"type":71,"value":2297},{"type":66,"tag":128,"props":2762,"children":2765},{"href":2763,"rel":2764},"https://github.com/nuxt-modules/supabase/issues/126",[132],[2766],{"type":71,"value":2767},"#126",{"type":71,"value":730},{"type":66,"tag":128,"props":2770,"children":2773},{"href":2771,"rel":2772},"https://github.com/nuxt-modules/supabase/commit/5699dc6",[132],[2774],{"type":66,"tag":312,"props":2775,"children":2777},{"className":2776},[],[2778],{"type":71,"value":2308},{"type":71,"value":255},{"type":66,"tag":116,"props":2781,"children":2782},{},[2783,2784,2794],{"type":71,"value":2280},{"type":66,"tag":128,"props":2785,"children":2788},{"href":2786,"rel":2787},"https://github.com/nuxt-modules/supabase/commit/bca1992",[132],[2789],{"type":66,"tag":312,"props":2790,"children":2792},{"className":2791},[],[2793],{"type":71,"value":2291},{"type":71,"value":255},{"type":66,"tag":67,"props":2796,"children":2797},{},[2798,2802,2803],{"type":66,"tag":120,"props":2799,"children":2800},{},[2801],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":2804,"children":2807},{"href":2805,"rel":2806},"https://github.com/nuxt-community/supabase-module/compare/v0.3.1...v0.3.3",[132],[2808],{"type":71,"value":2805},{"title":59,"searchDepth":78,"depth":78,"links":2810},[2811],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.3.3","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.3.3","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.3.3",true,{"url":2817,"total_count":161,"+1":161,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":294,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/97697076/reactions",{"name":166,"url":167,"avatar":168},"github:v0.3.3.md",{"name":2821,"tag_name":2821,"date":2822,"body":2823,"v":294,"url":2888,"tarball":2889,"zipball":2890,"prerelease":60,"author":2891,"title":59,"description":59,"_type":80,"_id":2892},"v0.3.1","2023-02-07T20:18:04Z",{"type":63,"children":2824,"toc":2885},[2825,2829,2871],{"type":66,"tag":98,"props":2826,"children":2827},{"id":100},[2828],{"type":71,"value":103},{"type":66,"tag":112,"props":2830,"children":2831},{},[2832,2849,2866],{"type":66,"tag":116,"props":2833,"children":2834},{},[2835,2837,2848],{"type":71,"value":2836},"chore(app): upgrade deps and fix lint (",{"type":66,"tag":128,"props":2838,"children":2841},{"href":2839,"rel":2840},"https://github.com/nuxt-modules/supabase/commit/68baf68",[132],[2842],{"type":66,"tag":312,"props":2843,"children":2845},{"className":2844},[],[2846],{"type":71,"value":2847},"68baf68",{"type":71,"value":255},{"type":66,"tag":116,"props":2850,"children":2851},{},[2852,2854,2865],{"type":71,"value":2853},"fix(client): unset user before session on logout (",{"type":66,"tag":128,"props":2855,"children":2858},{"href":2856,"rel":2857},"https://github.com/nuxt-modules/supabase/commit/ab574ef",[132],[2859],{"type":66,"tag":312,"props":2860,"children":2862},{"className":2861},[],[2863],{"type":71,"value":2864},"ab574ef",{"type":71,"value":255},{"type":66,"tag":116,"props":2867,"children":2868},{},[2869],{"type":71,"value":2870},"chore(demo): update with latest and fix logout",{"type":66,"tag":67,"props":2872,"children":2873},{},[2874,2878,2879],{"type":66,"tag":120,"props":2875,"children":2876},{},[2877],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":2880,"children":2883},{"href":2881,"rel":2882},"https://github.com/nuxt-community/supabase-module/compare/v0.3.0...v0.3.1",[132],[2884],{"type":71,"value":2881},{"title":59,"searchDepth":78,"depth":78,"links":2886},[2887],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.3.1","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.3.1","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.3.1",{"name":166,"url":167,"avatar":168},"github:v0.3.1.md",{"name":2894,"tag_name":2894,"date":2895,"body":2896,"v":294,"url":3018,"tarball":3019,"zipball":3020,"prerelease":60,"reactions":3021,"author":3023,"title":59,"description":1823,"_type":80,"_id":3024},"v0.3.0","2022-11-22T15:26:02Z",{"type":63,"children":2897,"toc":3015},[2898,2902,2906,2927,2961,2989,3001],{"type":66,"tag":67,"props":2899,"children":2900},{},[2901],{"type":71,"value":1823},{"type":66,"tag":98,"props":2903,"children":2904},{"id":100},[2905],{"type":71,"value":103},{"type":66,"tag":67,"props":2907,"children":2908},{},[2909,2911,2918,2920,2925],{"type":71,"value":2910},"In order to resolve ",{"type":66,"tag":128,"props":2912,"children":2915},{"href":2913,"rel":2914},"https://github.com/nuxt-modules/supabase/issues/114",[132],[2916],{"type":71,"value":2917},"#114",{"type":71,"value":2919},", I have made the choice to separate the ",{"type":66,"tag":312,"props":2921,"children":2923},{"className":2922},[],[2924],{"type":71,"value":21},{"type":71,"value":2926}," in two other composables:",{"type":66,"tag":112,"props":2928,"children":2929},{},[2930,2950],{"type":66,"tag":116,"props":2931,"children":2932},{},[2933,2935,2940,2942,2948],{"type":71,"value":2934},"The ",{"type":66,"tag":312,"props":2936,"children":2938},{"className":2937},[],[2939],{"type":71,"value":1835},{"type":71,"value":2941}," is dedicated to authentification purpose only. It won't be recreate if your token expires, it is used in the client plugin to listen to ",{"type":66,"tag":312,"props":2943,"children":2945},{"className":2944},[],[2946],{"type":71,"value":2947},"onAuthStateChange",{"type":71,"value":2949}," events.",{"type":66,"tag":116,"props":2951,"children":2952},{},[2953,2954,2959],{"type":71,"value":2934},{"type":66,"tag":312,"props":2955,"children":2957},{"className":2956},[],[2958],{"type":71,"value":21},{"type":71,"value":2960}," is now only useful for data request.",{"type":66,"tag":67,"props":2962,"children":2963},{},[2964,2966,2971,2973,2978,2980,2987],{"type":71,"value":2965},"To avoid regression you just need to use ",{"type":66,"tag":312,"props":2967,"children":2969},{"className":2968},[],[2970],{"type":71,"value":1835},{"type":71,"value":2972}," instead of ",{"type":66,"tag":312,"props":2974,"children":2976},{"className":2975},[],[2977],{"type":71,"value":21},{"type":71,"value":2979}," everywhere you use ",{"type":66,"tag":128,"props":2981,"children":2984},{"href":2982,"rel":2983},"https://supabase.com/docs/reference/javascript/auth-signup",[132],[2985],{"type":71,"value":2986},"Supabase auth methods",{"type":71,"value":2988},".",{"type":66,"tag":67,"props":2990,"children":2991},{},[2992,2999],{"type":66,"tag":128,"props":2993,"children":2996},{"href":2994,"rel":2995},"https://supabase.nuxtjs.org/usage/composables/use-supabase-auth-client",[132],[2997],{"type":71,"value":2998},"Documentation",{"type":71,"value":3000}," has been updated.",{"type":66,"tag":67,"props":3002,"children":3003},{},[3004,3008,3009],{"type":66,"tag":120,"props":3005,"children":3006},{},[3007],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3010,"children":3013},{"href":3011,"rel":3012},"https://github.com/nuxt-community/supabase-module/compare/v0.2.6...v0.3.0",[132],[3014],{"type":71,"value":3011},{"title":59,"searchDepth":78,"depth":78,"links":3016},[3017],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.3.0","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.3.0","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.3.0",{"url":3022,"total_count":1998,"+1":78,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":160,"rocket":160,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/83886320/reactions",{"name":166,"url":167,"avatar":168},"github:v0.3.0.md",{"name":3026,"tag_name":3026,"date":3027,"body":3028,"v":294,"url":3065,"tarball":3066,"zipball":3067,"prerelease":60,"author":3068,"title":59,"description":59,"_type":80,"_id":3069},"v0.2.6","2022-11-22T15:16:16Z",{"type":63,"children":3029,"toc":3062},[3030,3034,3048],{"type":66,"tag":98,"props":3031,"children":3032},{"id":100},[3033],{"type":71,"value":103},{"type":66,"tag":112,"props":3035,"children":3036},{},[3037],{"type":66,"tag":116,"props":3038,"children":3039},{},[3040,3042],{"type":71,"value":3041},"chore: update to Nuxt 3 stable 🚀 ",{"type":66,"tag":128,"props":3043,"children":3046},{"href":3044,"rel":3045},"https://nuxt.com/v3",[132],[3047],{"type":71,"value":3044},{"type":66,"tag":67,"props":3049,"children":3050},{},[3051,3055,3056],{"type":66,"tag":120,"props":3052,"children":3053},{},[3054],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3057,"children":3060},{"href":3058,"rel":3059},"https://github.com/nuxt-community/supabase-module/compare/v0.2.5...v0.2.6",[132],[3061],{"type":71,"value":3058},{"title":59,"searchDepth":78,"depth":78,"links":3063},[3064],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.2.6","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.2.6","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.2.6",{"name":166,"url":167,"avatar":168},"github:v0.2.6.md",{"name":3071,"tag_name":3071,"date":3072,"body":3073,"v":294,"url":3125,"tarball":3126,"zipball":3127,"prerelease":60,"author":3128,"title":59,"description":59,"_type":80,"_id":3129},"v0.2.5","2022-11-22T15:14:51Z",{"type":63,"children":3074,"toc":3122},[3075,3079,3108],{"type":66,"tag":98,"props":3076,"children":3077},{"id":100},[3078],{"type":71,"value":103},{"type":66,"tag":112,"props":3080,"children":3081},{},[3082],{"type":66,"tag":116,"props":3083,"children":3084},{},[3085,3087,3098,3100,3107],{"type":71,"value":3086},"fix: use Router instead of navigateTo for login redirect in ",{"type":66,"tag":128,"props":3088,"children":3091},{"href":3089,"rel":3090},"https://github.com/nuxt-modules/supabase/commit/79fc0e43655d4dee5858acf06cf1979e3ead542b",[132],[3092],{"type":66,"tag":312,"props":3093,"children":3095},{"className":3094},[],[3096],{"type":71,"value":3097},"79fc0e4",{"type":71,"value":3099}," (resolves ",{"type":66,"tag":128,"props":3101,"children":3104},{"href":3102,"rel":3103},"https://github.com/nuxt-modules/supabase/issues/89",[132],[3105],{"type":71,"value":3106},"#89",{"type":71,"value":255},{"type":66,"tag":67,"props":3109,"children":3110},{},[3111,3115,3116],{"type":66,"tag":120,"props":3112,"children":3113},{},[3114],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3117,"children":3120},{"href":3118,"rel":3119},"https://github.com/nuxt-community/supabase-module/compare/v0.2.4...v0.2.5",[132],[3121],{"type":71,"value":3118},{"title":59,"searchDepth":78,"depth":78,"links":3123},[3124],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.2.5","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.2.5","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.2.5",{"name":166,"url":167,"avatar":168},"github:v0.2.5.md",{"name":3131,"tag_name":3131,"date":3132,"body":3133,"v":294,"url":3175,"tarball":3176,"zipball":3177,"prerelease":60,"reactions":3178,"author":3180,"title":59,"description":59,"_type":80,"_id":3181},"v0.2.4","2022-11-13T19:36:18Z",{"type":63,"children":3134,"toc":3172},[3135,3139,3158],{"type":66,"tag":98,"props":3136,"children":3137},{"id":100},[3138],{"type":71,"value":103},{"type":66,"tag":112,"props":3140,"children":3141},{},[3142],{"type":66,"tag":116,"props":3143,"children":3144},{},[3145,3147],{"type":71,"value":3146},"fix: handle TOKEN_REFRESHED session event in ",{"type":66,"tag":128,"props":3148,"children":3151},{"href":3149,"rel":3150},"https://github.com/nuxt-modules/supabase/commit/bf503029b48113b4b66545d0d2065c899209a06a",[132],[3152],{"type":66,"tag":312,"props":3153,"children":3155},{"className":3154},[],[3156],{"type":71,"value":3157},"bf50302",{"type":66,"tag":67,"props":3159,"children":3160},{},[3161,3165,3166],{"type":66,"tag":120,"props":3162,"children":3163},{},[3164],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3167,"children":3170},{"href":3168,"rel":3169},"https://github.com/nuxt-community/supabase-module/compare/v0.2.3...v0.2.4",[132],[3171],{"type":71,"value":3168},{"title":59,"searchDepth":78,"depth":78,"links":3173},[3174],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.2.4","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.2.4","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.2.4",{"url":3179,"total_count":78,"+1":294,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":78,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/82920199/reactions",{"name":166,"url":167,"avatar":168},"github:v0.2.4.md",{"name":3183,"tag_name":3183,"date":3184,"body":3185,"v":294,"url":3322,"tarball":3323,"zipball":3324,"prerelease":60,"reactions":3325,"author":3327,"title":59,"description":59,"_type":80,"_id":3328},"v0.2.3","2022-11-11T17:27:14Z",{"type":63,"children":3186,"toc":3318},[3187,3191,3270,3276,3304],{"type":66,"tag":98,"props":3188,"children":3189},{"id":100},[3190],{"type":71,"value":103},{"type":66,"tag":112,"props":3192,"children":3193},{},[3194,3222,3234,3247],{"type":66,"tag":116,"props":3195,"children":3196},{},[3197,3199,3210,3211],{"type":71,"value":3198},"feat: typed supabase client in ",{"type":66,"tag":128,"props":3200,"children":3203},{"href":3201,"rel":3202},"https://github.com/nuxt-modules/supabase/commit/b59ff1acfbbe2cd36aea1ade2d2b538404909260",[132],[3204],{"type":66,"tag":312,"props":3205,"children":3207},{"className":3206},[],[3208],{"type":71,"value":3209},"b59ff1a",{"type":71,"value":713},{"type":66,"tag":128,"props":3212,"children":3215},{"href":3213,"rel":3214},"https://github.com/nuxt-modules/supabase/commit/fd751d7e50c63c48df9e03763458cc826409ff35",[132],[3216],{"type":66,"tag":312,"props":3217,"children":3219},{"className":3218},[],[3220],{"type":71,"value":3221},"fd751d7",{"type":66,"tag":116,"props":3223,"children":3224},{},[3225,3227],{"type":71,"value":3226},"chore: upgrade to nuxt ",{"type":66,"tag":128,"props":3228,"children":3231},{"href":3229,"rel":3230},"https://github.com/nuxt/framework/releases/tag/v3.0.0-rc.13",[132],[3232],{"type":71,"value":3233},"rc13",{"type":66,"tag":116,"props":3235,"children":3236},{},[3237,3239,3246],{"type":71,"value":3238},"fix: do not apply token if not exists (",{"type":66,"tag":128,"props":3240,"children":3243},{"href":3241,"rel":3242},"https://github.com/nuxt-modules/supabase/issues/107",[132],[3244],{"type":71,"value":3245},"#107",{"type":71,"value":255},{"type":66,"tag":116,"props":3248,"children":3249},{},[3250,3252,3258,3259],{"type":71,"value":3251},"docs: add roadmap board from ",{"type":66,"tag":128,"props":3253,"children":3256},{"href":3254,"rel":3255},"https://volta.net",[132],[3257],{"type":71,"value":3254},{"type":71,"value":619},{"type":66,"tag":128,"props":3260,"children":3263},{"href":3261,"rel":3262},"https://github.com/nuxt-modules/supabase/commit/f8e73b535924f133e479dbc2863bb37856ff4555",[132],[3264],{"type":66,"tag":312,"props":3265,"children":3267},{"className":3266},[],[3268],{"type":71,"value":3269},"f8e73b5",{"type":66,"tag":98,"props":3271,"children":3273},{"id":3272},"contributors",[3274],{"type":71,"value":3275},"Contributors",{"type":66,"tag":67,"props":3277,"children":3278},{},[3279,3281,3291,3292,3302],{"type":71,"value":3280},"Thanks to ",{"type":66,"tag":128,"props":3282,"children":3285},{"href":3283,"rel":3284},"https://github.com/manniL",[132],[3286],{"type":66,"tag":120,"props":3287,"children":3288},{},[3289],{"type":71,"value":3290},"@manniL",{"type":71,"value":713},{"type":66,"tag":128,"props":3293,"children":3296},{"href":3294,"rel":3295},"https://github.com/levibe",[132],[3297],{"type":66,"tag":120,"props":3298,"children":3299},{},[3300],{"type":71,"value":3301},"@levibe",{"type":71,"value":3303}," 💚",{"type":66,"tag":67,"props":3305,"children":3306},{},[3307,3311,3312],{"type":66,"tag":120,"props":3308,"children":3309},{},[3310],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3313,"children":3316},{"href":3314,"rel":3315},"https://github.com/nuxt-community/supabase-module/compare/v0.2.0...v0.2.3",[132],[3317],{"type":71,"value":3314},{"title":59,"searchDepth":78,"depth":78,"links":3319},[3320,3321],{"id":100,"depth":78,"text":103},{"id":3272,"depth":78,"text":3275},"https://github.com/nuxt-modules/supabase/releases/tag/v0.2.3","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.2.3","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.2.3",{"url":3326,"total_count":161,"+1":294,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":161,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/82825289/reactions",{"name":166,"url":167,"avatar":168},"github:v0.2.3.md",{"name":3330,"tag_name":3330,"date":3331,"body":3332,"v":294,"url":3423,"tarball":3424,"zipball":3425,"prerelease":60,"author":3426,"title":59,"description":59,"_type":80,"_id":3427},"v0.2.0","2022-10-17T14:18:31Z",{"type":63,"children":3333,"toc":3420},[3334,3338,3343,3356,3369,3374,3379,3406],{"type":66,"tag":98,"props":3335,"children":3336},{"id":100},[3337],{"type":71,"value":103},{"type":66,"tag":67,"props":3339,"children":3340},{},[3341],{"type":71,"value":3342},"⚠️ Breaking Changes",{"type":66,"tag":67,"props":3344,"children":3345},{},[3346,3348,3355],{"type":71,"value":3347},"Upgrade to supabase-js v2, check Supabase ",{"type":66,"tag":128,"props":3349,"children":3352},{"href":3350,"rel":3351},"https://supabase.com/docs/reference/javascript/release-notes",[132],[3353],{"type":71,"value":3354},"release notes",{"type":71,"value":2988},{"type":66,"tag":67,"props":3357,"children":3358},{},[3359,3361,3367],{"type":71,"value":3360},"Module ",{"type":66,"tag":128,"props":3362,"children":3364},{"href":1785,"rel":3363},[132],[3365],{"type":71,"value":3366},"documentation",{"type":71,"value":3368}," has been updated in favor of supabase v2 syntax.",{"type":66,"tag":67,"props":3370,"children":3371},{},[3372],{"type":71,"value":3373},"Please feel free to make PR if I missed something 🙏",{"type":66,"tag":67,"props":3375,"children":3376},{},[3377],{"type":71,"value":3378},"🚀 Features",{"type":66,"tag":112,"props":3380,"children":3381},{},[3382,3394],{"type":66,"tag":116,"props":3383,"children":3384},{},[3385,3387,3393],{"type":71,"value":3386},"options: redirect user after signout or when user is not authenticated (check ",{"type":66,"tag":128,"props":3388,"children":3391},{"href":3389,"rel":3390},"https://supabase.nuxtjs.org/get-started#redirect",[132],[3392],{"type":71,"value":3366},{"type":71,"value":255},{"type":66,"tag":116,"props":3395,"children":3396},{},[3397,3399],{"type":71,"value":3398},"session: set refresh token ",{"type":66,"tag":128,"props":3400,"children":3403},{"href":3401,"rel":3402},"https://github.com/nuxt-modules/supabase/issues/18",[132],[3404],{"type":71,"value":3405},"#18",{"type":66,"tag":67,"props":3407,"children":3408},{},[3409,3413,3414],{"type":66,"tag":120,"props":3410,"children":3411},{},[3412],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3415,"children":3418},{"href":3416,"rel":3417},"https://github.com/nuxt-community/supabase-module/compare/v0.1.28...v0.2.0",[132],[3419],{"type":71,"value":3416},{"title":59,"searchDepth":78,"depth":78,"links":3421},[3422],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.2.0","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.2.0","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.2.0",{"name":166,"url":167,"avatar":168},"github:v0.2.0.md",{"name":3429,"tag_name":3429,"date":3430,"body":3431,"v":294,"url":3486,"tarball":3487,"zipball":3488,"prerelease":60,"author":3489,"title":59,"description":59,"_type":80,"_id":3490},"v0.1.28","2022-10-07T10:05:52Z",{"type":63,"children":3432,"toc":3483},[3433,3437,3453,3467],{"type":66,"tag":98,"props":3434,"children":3435},{"id":100},[3436],{"type":71,"value":103},{"type":66,"tag":112,"props":3438,"children":3439},{},[3440],{"type":66,"tag":116,"props":3441,"children":3442},{},[3443,3445,3452],{"type":71,"value":3444},"fix: cloudflare workers deployment (",{"type":66,"tag":128,"props":3446,"children":3449},{"href":3447,"rel":3448},"https://github.com/nuxt-modules/supabase/issues/46",[132],[3450],{"type":71,"value":3451},"#46",{"type":71,"value":255},{"type":66,"tag":67,"props":3454,"children":3455},{},[3456,3460,3461],{"type":66,"tag":120,"props":3457,"children":3458},{},[3459],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3462,"children":3465},{"href":3463,"rel":3464},"https://github.com/nuxt-community/supabase-module/compare/v0.1.27...v0.1.28",[132],[3466],{"type":71,"value":3463},{"type":66,"tag":67,"props":3468,"children":3469},{},[3470,3471,3481],{"type":71,"value":3280},{"type":66,"tag":128,"props":3472,"children":3475},{"href":3473,"rel":3474},"https://github.com/kevinmarrec",[132],[3476],{"type":66,"tag":120,"props":3477,"children":3478},{},[3479],{"type":71,"value":3480},"@kevinmarrec",{"type":71,"value":3482}," for the fix 🔥",{"title":59,"searchDepth":78,"depth":78,"links":3484},[3485],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.28","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.28","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.28",{"name":166,"url":167,"avatar":168},"github:v0.1.28.md",{"name":3492,"tag_name":3492,"date":3493,"body":3494,"v":294,"url":3537,"tarball":3538,"zipball":3539,"prerelease":60,"author":3540,"title":59,"description":59,"_type":80,"_id":3541},"v0.1.27","2022-09-23T10:19:42Z",{"type":63,"children":3495,"toc":3534},[3496,3500,3515,3520],{"type":66,"tag":98,"props":3497,"children":3498},{"id":100},[3499],{"type":71,"value":103},{"type":66,"tag":112,"props":3501,"children":3502},{},[3503],{"type":66,"tag":116,"props":3504,"children":3505},{},[3506,3508],{"type":71,"value":3507},"chore: upgrade to Nuxt ",{"type":66,"tag":128,"props":3509,"children":3512},{"href":3510,"rel":3511},"https://github.com/nuxt/framework/releases/tag/v3.0.0-rc.11",[132],[3513],{"type":71,"value":3514},"rc.11",{"type":66,"tag":67,"props":3516,"children":3517},{},[3518],{"type":71,"value":3519},"Stable is coming 🚀",{"type":66,"tag":67,"props":3521,"children":3522},{},[3523,3527,3528],{"type":66,"tag":120,"props":3524,"children":3525},{},[3526],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3529,"children":3532},{"href":3530,"rel":3531},"https://github.com/nuxt-community/supabase-module/compare/v0.1.26...v0.1.27",[132],[3533],{"type":71,"value":3530},{"title":59,"searchDepth":78,"depth":78,"links":3535},[3536],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.27","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.27","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.27",{"name":166,"url":167,"avatar":168},"github:v0.1.27.md",{"name":3330,"tag_name":3543,"date":3544,"body":3545,"v":294,"url":3583,"tarball":3584,"zipball":3585,"prerelease":2815,"author":3586,"title":59,"description":59,"_type":80,"_id":3427},"v0.2.0-16","2022-08-16T14:56:45Z",{"type":63,"children":3546,"toc":3580},[3547,3551,3555,3566],{"type":66,"tag":98,"props":3548,"children":3549},{"id":100},[3550],{"type":71,"value":103},{"type":66,"tag":67,"props":3552,"children":3553},{},[3554],{"type":71,"value":3342},{"type":66,"tag":67,"props":3556,"children":3557},{},[3558,3559,3565],{"type":71,"value":3347},{"type":66,"tag":128,"props":3560,"children":3563},{"href":3561,"rel":3562},"https://supabase.com/docs/reference/javascript/next/release-notes",[132],[3564],{"type":71,"value":3354},{"type":71,"value":2988},{"type":66,"tag":67,"props":3567,"children":3568},{},[3569,3573,3574],{"type":66,"tag":120,"props":3570,"children":3571},{},[3572],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3575,"children":3578},{"href":3576,"rel":3577},"https://github.com/nuxt-community/supabase-module/compare/v0.1.22...v0.2.0",[132],[3579],{"type":71,"value":3576},{"title":59,"searchDepth":78,"depth":78,"links":3581},[3582],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.2.0-16","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.2.0-16","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.2.0-16",{"name":166,"url":167,"avatar":168},{"name":3588,"tag_name":3588,"date":3589,"body":3590,"v":294,"url":3632,"tarball":3633,"zipball":3634,"prerelease":60,"reactions":3635,"author":3637,"title":59,"description":59,"_type":80,"_id":3638},"v0.1.26","2022-09-16T11:17:29Z",{"type":63,"children":3591,"toc":3629},[3592,3596,3610,3615],{"type":66,"tag":98,"props":3593,"children":3594},{"id":100},[3595],{"type":71,"value":103},{"type":66,"tag":112,"props":3597,"children":3598},{},[3599],{"type":66,"tag":116,"props":3600,"children":3601},{},[3602,3603],{"type":71,"value":3507},{"type":66,"tag":128,"props":3604,"children":3607},{"href":3605,"rel":3606},"https://github.com/nuxt/framework/releases/tag/v3.0.0-rc.10",[132],[3608],{"type":71,"value":3609},"rc.10",{"type":66,"tag":67,"props":3611,"children":3612},{},[3613],{"type":71,"value":3614},"Stable in coming 🚀",{"type":66,"tag":67,"props":3616,"children":3617},{},[3618,3622,3623],{"type":66,"tag":120,"props":3619,"children":3620},{},[3621],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3624,"children":3627},{"href":3625,"rel":3626},"https://github.com/nuxt-community/supabase-module/compare/v0.1.25...v0.1.26",[132],[3628],{"type":71,"value":3625},{"title":59,"searchDepth":78,"depth":78,"links":3630},[3631],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.26","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.26","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.26",{"url":3636,"total_count":161,"+1":161,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":294,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/77384555/reactions",{"name":166,"url":167,"avatar":168},"github:v0.1.26.md",{"name":3640,"tag_name":3640,"date":3641,"body":3642,"v":294,"url":3745,"tarball":3746,"zipball":3747,"prerelease":60,"reactions":3748,"author":3750,"title":59,"description":59,"_type":80,"_id":3751},"v0.1.25","2022-09-05T07:28:01Z",{"type":63,"children":3643,"toc":3742},[3644,3648,3728],{"type":66,"tag":98,"props":3645,"children":3646},{"id":100},[3647],{"type":71,"value":103},{"type":66,"tag":112,"props":3649,"children":3650},{},[3651,3687,3715],{"type":66,"tag":116,"props":3652,"children":3653},{},[3654,3656,3667,3668,3679,3681],{"type":71,"value":3655},"docs: new directory architecture + supabase module v2 coming soon in ",{"type":66,"tag":128,"props":3657,"children":3660},{"href":3658,"rel":3659},"https://github.com/nuxt-modules/supabase/commit/d48522a369bcced45dfb3d16793b33f0144ffa50",[132],[3661],{"type":66,"tag":312,"props":3662,"children":3664},{"className":3663},[],[3665],{"type":71,"value":3666},"d48522a",{"type":71,"value":713},{"type":66,"tag":128,"props":3669,"children":3672},{"href":3670,"rel":3671},"https://github.com/nuxt-modules/supabase/commit/e69712b4862a5baa464c01ae32755473358b82d2",[132],[3673],{"type":66,"tag":312,"props":3674,"children":3676},{"className":3675},[],[3677],{"type":71,"value":3678},"e69712b",{"type":71,"value":3680},". Check out ",{"type":66,"tag":128,"props":3682,"children":3685},{"href":3683,"rel":3684},"https://supabase.nuxtjs.org/",[132],[3686],{"type":71,"value":3683},{"type":66,"tag":116,"props":3688,"children":3689},{},[3690,3692,3703,3704],{"type":71,"value":3691},"chore: upgrade to rc9 in ",{"type":66,"tag":128,"props":3693,"children":3696},{"href":3694,"rel":3695},"https://github.com/nuxt-modules/supabase/commit/3c5220bf9569d2e939a466aa4a2814e0dc38622c",[132],[3697],{"type":66,"tag":312,"props":3698,"children":3700},{"className":3699},[],[3701],{"type":71,"value":3702},"3c5220b",{"type":71,"value":713},{"type":66,"tag":128,"props":3705,"children":3708},{"href":3706,"rel":3707},"https://github.com/nuxt-modules/supabase/commit/495e0b705622e9bda28072815c828beedea1082c",[132],[3709],{"type":66,"tag":312,"props":3710,"children":3712},{"className":3711},[],[3713],{"type":71,"value":3714},"495e0b7",{"type":66,"tag":116,"props":3716,"children":3717},{},[3718,3720,3727],{"type":71,"value":3719},"chore: fix nuxt compatibility (",{"type":66,"tag":128,"props":3721,"children":3724},{"href":3722,"rel":3723},"https://github.com/nuxt-modules/supabase/issues/70",[132],[3725],{"type":71,"value":3726},"#70",{"type":71,"value":255},{"type":66,"tag":67,"props":3729,"children":3730},{},[3731,3735,3736],{"type":66,"tag":120,"props":3732,"children":3733},{},[3734],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3737,"children":3740},{"href":3738,"rel":3739},"https://github.com/nuxt-community/supabase-module/compare/v0.1.23...v0.1.25",[132],[3741],{"type":71,"value":3738},{"title":59,"searchDepth":78,"depth":78,"links":3743},[3744],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.25","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.25","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.25",{"url":3749,"total_count":685,"+1":294,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":685,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/76259131/reactions",{"name":166,"url":167,"avatar":168},"github:v0.1.25.md",{"name":3753,"tag_name":3753,"date":3754,"body":3755,"v":294,"url":3823,"tarball":3824,"zipball":3825,"prerelease":60,"author":3826,"title":59,"description":59,"_type":80,"_id":3827},"v0.1.23","2022-08-16T10:12:13Z",{"type":63,"children":3756,"toc":3820},[3757,3761,3806],{"type":66,"tag":98,"props":3758,"children":3759},{"id":100},[3760],{"type":71,"value":103},{"type":66,"tag":112,"props":3762,"children":3763},{},[3764],{"type":66,"tag":116,"props":3765,"children":3766},{},[3767,3769,3782,3784,3796,3798,3805],{"type":71,"value":3768},"fix: transpile supabase packages in ",{"type":66,"tag":128,"props":3770,"children":3773},{"href":3771,"rel":3772},"https://github.com/nuxt-community/supabase-module/commit/66020204e8aad98db94a83964f1bb988642c90f3",[132],[3774,3776],{"type":71,"value":3775},"nuxt-community/supabase-module@",{"type":66,"tag":312,"props":3777,"children":3779},{"className":3778},[],[3780],{"type":71,"value":3781},"6602020",{"type":71,"value":3783}," ",{"type":66,"tag":128,"props":3785,"children":3788},{"href":3786,"rel":3787},"https://github.com/nuxt-community/supabase-module/commit/237ddf2cf83079e39748b6252182ca1d2f62cc54",[132],[3789,3790],{"type":71,"value":3775},{"type":66,"tag":312,"props":3791,"children":3793},{"className":3792},[],[3794],{"type":71,"value":3795},"237ddf2",{"type":71,"value":3797}," and (",{"type":66,"tag":128,"props":3799,"children":3802},{"href":3800,"rel":3801},"https://github.com/nuxt-modules/supabase/issues/62",[132],[3803],{"type":71,"value":3804},"#62",{"type":71,"value":255},{"type":66,"tag":67,"props":3807,"children":3808},{},[3809,3813,3814],{"type":66,"tag":120,"props":3810,"children":3811},{},[3812],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3815,"children":3818},{"href":3816,"rel":3817},"https://github.com/nuxt-community/supabase-module/compare/v0.1.20...v0.1.23",[132],[3819],{"type":71,"value":3816},{"title":59,"searchDepth":78,"depth":78,"links":3821},[3822],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.23","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.23","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.23",{"name":166,"url":167,"avatar":168},"github:v0.1.23.md",{"name":3829,"tag_name":3829,"date":3830,"body":3831,"v":294,"url":3901,"tarball":3902,"zipball":3903,"prerelease":60,"author":3904,"title":59,"description":59,"_type":80,"_id":3905},"v0.1.20","2022-08-16T09:12:14Z",{"type":63,"children":3832,"toc":3897},[3833,3837,3852,3866,3872],{"type":66,"tag":98,"props":3834,"children":3835},{"id":100},[3836],{"type":71,"value":103},{"type":66,"tag":112,"props":3838,"children":3839},{},[3840],{"type":66,"tag":116,"props":3841,"children":3842},{},[3843,3845],{"type":71,"value":3844},"chore: upgrade to ",{"type":66,"tag":128,"props":3846,"children":3849},{"href":3847,"rel":3848},"https://github.com/nuxt/framework/releases/tag/v3.0.0-rc.8",[132],[3850],{"type":71,"value":3851},"nuxt rc.8",{"type":66,"tag":67,"props":3853,"children":3854},{},[3855,3859,3860],{"type":66,"tag":120,"props":3856,"children":3857},{},[3858],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3861,"children":3864},{"href":3862,"rel":3863},"https://github.com/nuxt-community/supabase-module/compare/v0.1.19...v0.1.20",[132],[3865],{"type":71,"value":3862},{"type":66,"tag":98,"props":3867,"children":3869},{"id":3868},"new-contributors",[3870],{"type":71,"value":3871},"New Contributors",{"type":66,"tag":112,"props":3873,"children":3874},{},[3875],{"type":66,"tag":116,"props":3876,"children":3877},{},[3878,3888,3890],{"type":66,"tag":128,"props":3879,"children":3882},{"href":3880,"rel":3881},"https://github.com/josuemartinezz",[132],[3883],{"type":66,"tag":120,"props":3884,"children":3885},{},[3886],{"type":71,"value":3887},"@josuemartinezz",{"type":71,"value":3889}," made his first contribution in ",{"type":66,"tag":128,"props":3891,"children":3894},{"href":3892,"rel":3893},"https://github.com/nuxt-modules/supabase/issues/59",[132],[3895],{"type":71,"value":3896},"#59",{"title":59,"searchDepth":78,"depth":78,"links":3898},[3899,3900],{"id":100,"depth":78,"text":103},{"id":3868,"depth":78,"text":3871},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.20","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.20","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.20",{"name":166,"url":167,"avatar":168},"github:v0.1.20.md",{"name":3907,"tag_name":3907,"date":3908,"body":3909,"v":294,"url":3963,"tarball":3964,"zipball":3965,"prerelease":60,"reactions":3966,"author":3968,"title":59,"description":59,"_type":80,"_id":3969},"v0.1.19","2022-07-18T08:18:42Z",{"type":63,"children":3910,"toc":3960},[3911,3915,3946],{"type":66,"tag":98,"props":3912,"children":3913},{"id":100},[3914],{"type":71,"value":103},{"type":66,"tag":112,"props":3916,"children":3917},{},[3918,3929],{"type":66,"tag":116,"props":3919,"children":3920},{},[3921,3922],{"type":71,"value":3844},{"type":66,"tag":128,"props":3923,"children":3926},{"href":3924,"rel":3925},"https://github.com/nuxt/framework/pull/5825",[132],[3927],{"type":71,"value":3928},"nuxt rc.5",{"type":66,"tag":116,"props":3930,"children":3931},{},[3932,3934],{"type":71,"value":3933},"doc: add supabase icon in ",{"type":66,"tag":128,"props":3935,"children":3938},{"href":3936,"rel":3937},"https://github.com/nuxt-community/supabase-module/commit/c0cce016eae809fd64acc9a503b4807750280b39",[132],[3939,3940],{"type":71,"value":3775},{"type":66,"tag":312,"props":3941,"children":3943},{"className":3942},[],[3944],{"type":71,"value":3945},"c0cce01",{"type":66,"tag":67,"props":3947,"children":3948},{},[3949,3953,3954],{"type":66,"tag":120,"props":3950,"children":3951},{},[3952],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3955,"children":3958},{"href":3956,"rel":3957},"https://github.com/nuxt-community/supabase-module/compare/v0.1.18...v0.1.19",[132],[3959],{"type":71,"value":3956},{"title":59,"searchDepth":78,"depth":78,"links":3961},[3962],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.19","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.19","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.19",{"url":3967,"total_count":161,"+1":294,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":294,"rocket":161,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/72200550/reactions",{"name":166,"url":167,"avatar":168},"github:v0.1.19.md",{"name":3971,"tag_name":3971,"date":3972,"body":3973,"v":294,"url":4050,"tarball":4051,"zipball":4052,"prerelease":60,"author":4053,"title":59,"description":59,"_type":80,"_id":4054},"v0.1.18","2022-06-29T09:23:26Z",{"type":63,"children":3974,"toc":4047},[3975,3979,4033],{"type":66,"tag":98,"props":3976,"children":3977},{"id":100},[3978],{"type":71,"value":103},{"type":66,"tag":112,"props":3980,"children":3981},{},[3982,4008],{"type":66,"tag":116,"props":3983,"children":3984},{},[3985,3987,3999,4000,4007],{"type":71,"value":3986},"doc: update logo & social preview in ",{"type":66,"tag":128,"props":3988,"children":3991},{"href":3989,"rel":3990},"https://github.com/nuxt-community/supabase-module/commit/9b0b2fbee1f2fed50e903c2b368b817568d7ab1f",[132],[3992,3993],{"type":71,"value":3775},{"type":66,"tag":312,"props":3994,"children":3996},{"className":3995},[],[3997],{"type":71,"value":3998},"9b0b2fb",{"type":71,"value":501},{"type":66,"tag":128,"props":4001,"children":4004},{"href":4002,"rel":4003},"https://github.com/nuxt-modules/supabase/issues/53",[132],[4005],{"type":71,"value":4006},"#53",{"type":71,"value":255},{"type":66,"tag":116,"props":4009,"children":4010},{},[4011,4012,4024,4025,4032],{"type":71,"value":3768},{"type":66,"tag":128,"props":4013,"children":4016},{"href":4014,"rel":4015},"https://github.com/nuxt-community/supabase-module/commit/309c137f7ae23985f0ed9947fb85cb75cbfbfca2",[132],[4017,4018],{"type":71,"value":3775},{"type":66,"tag":312,"props":4019,"children":4021},{"className":4020},[],[4022],{"type":71,"value":4023},"309c137",{"type":71,"value":501},{"type":66,"tag":128,"props":4026,"children":4029},{"href":4027,"rel":4028},"https://github.com/nuxt-modules/supabase/issues/55",[132],[4030],{"type":71,"value":4031},"#55",{"type":71,"value":255},{"type":66,"tag":67,"props":4034,"children":4035},{},[4036,4040,4041],{"type":66,"tag":120,"props":4037,"children":4038},{},[4039],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":4042,"children":4045},{"href":4043,"rel":4044},"https://github.com/nuxt-community/supabase-module/compare/v0.1.17...v0.1.18",[132],[4046],{"type":71,"value":4043},{"title":59,"searchDepth":78,"depth":78,"links":4048},[4049],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.18","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.18","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.18",{"name":166,"url":167,"avatar":168},"github:v0.1.18.md",{"name":4056,"tag_name":4056,"date":4057,"body":4058,"v":294,"url":4150,"tarball":4151,"zipball":4152,"prerelease":60,"reactions":4153,"author":4155,"title":59,"description":59,"_type":80,"_id":4156},"v0.1.17","2022-06-17T07:01:12Z",{"type":63,"children":4059,"toc":4147},[4060,4064,4120,4133],{"type":66,"tag":98,"props":4061,"children":4062},{"id":100},[4063],{"type":71,"value":103},{"type":66,"tag":112,"props":4065,"children":4066},{},[4067,4078,4103],{"type":66,"tag":116,"props":4068,"children":4069},{},[4070,4071],{"type":71,"value":3844},{"type":66,"tag":128,"props":4072,"children":4075},{"href":4073,"rel":4074},"https://github.com/nuxt/framework/discussions/5445",[132],[4076],{"type":71,"value":4077},"nuxt rc.4",{"type":66,"tag":116,"props":4079,"children":4080},{},[4081,4083,4090,4091],{"type":71,"value":4082},"doc: update ",{"type":66,"tag":128,"props":4084,"children":4087},{"href":4085,"rel":4086},"https://docus.com/",[132],[4088],{"type":71,"value":4089},"docus theme",{"type":71,"value":619},{"type":66,"tag":128,"props":4092,"children":4095},{"href":4093,"rel":4094},"https://github.com/nuxt-community/supabase-module/commit/64a5add3db5e0416a8a3b7f9708d27148797e958",[132],[4096,4097],{"type":71,"value":3775},{"type":66,"tag":312,"props":4098,"children":4100},{"className":4099},[],[4101],{"type":71,"value":4102},"64a5add",{"type":66,"tag":116,"props":4104,"children":4105},{},[4106,4108],{"type":71,"value":4107},"doc: add advanced usage with supabase realtime ",{"type":66,"tag":128,"props":4109,"children":4112},{"href":4110,"rel":4111},"https://github.com/nuxt-community/supabase-module/commit/8047e311e5526a4597b81a99dc8045114348172f",[132],[4113,4114],{"type":71,"value":3775},{"type":66,"tag":312,"props":4115,"children":4117},{"className":4116},[],[4118],{"type":71,"value":4119},"8047e31",{"type":66,"tag":67,"props":4121,"children":4122},{},[4123,4125,4131],{"type":71,"value":4124},"Checkout the ",{"type":66,"tag":128,"props":4126,"children":4129},{"href":4127,"rel":4128},"https://supabase.nuxtjs.org/advanced#realtime",[132],[4130],{"type":71,"value":3366},{"type":71,"value":4132}," for supabase realtime!",{"type":66,"tag":67,"props":4134,"children":4135},{},[4136,4140,4141],{"type":66,"tag":120,"props":4137,"children":4138},{},[4139],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":4142,"children":4145},{"href":4143,"rel":4144},"https://github.com/nuxt-community/supabase-module/compare/v0.1.16...v0.1.17",[132],[4146],{"type":71,"value":4143},{"title":59,"searchDepth":78,"depth":78,"links":4148},[4149],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.17","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.17","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.17",{"url":4154,"total_count":161,"+1":294,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":161,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/69689480/reactions",{"name":166,"url":167,"avatar":168},"github:v0.1.17.md",{"name":4158,"tag_name":4158,"date":4159,"body":4160,"v":294,"url":4258,"tarball":4259,"zipball":4260,"prerelease":60,"author":4261,"title":59,"description":59,"_type":80,"_id":4262},"v0.1.16","2022-06-01T10:51:45Z",{"type":63,"children":4161,"toc":4255},[4162,4166,4229,4241],{"type":66,"tag":98,"props":4163,"children":4164},{"id":100},[4165],{"type":71,"value":103},{"type":66,"tag":112,"props":4167,"children":4168},{},[4169,4203],{"type":66,"tag":116,"props":4170,"children":4171},{},[4172,4174,4181,4182,4194,4195,4202],{"type":71,"value":4173},"doc: use docus theme (public release coming soon) powered by ",{"type":66,"tag":128,"props":4175,"children":4178},{"href":4176,"rel":4177},"https://content.nuxtjs.org/",[132],[4179],{"type":71,"value":4180},"nuxt content v2",{"type":71,"value":619},{"type":66,"tag":128,"props":4183,"children":4186},{"href":4184,"rel":4185},"https://github.com/nuxt-community/supabase-module/commit/c24a16ff0bc94221adc021231a2206b6db8f293c",[132],[4187,4188],{"type":71,"value":3775},{"type":66,"tag":312,"props":4189,"children":4191},{"className":4190},[],[4192],{"type":71,"value":4193},"c24a16f",{"type":71,"value":501},{"type":66,"tag":128,"props":4196,"children":4199},{"href":4197,"rel":4198},"https://github.com/nuxt-modules/supabase/issues/41",[132],[4200],{"type":71,"value":4201},"#41",{"type":71,"value":255},{"type":66,"tag":116,"props":4204,"children":4205},{},[4206,4208,4220,4221,4228],{"type":71,"value":4207},"feat: service role client to bypass RLS in ",{"type":66,"tag":128,"props":4209,"children":4212},{"href":4210,"rel":4211},"https://github.com/nuxt-community/supabase-module/commit/ba70a976be97acb3c438d59e45b789ee917bee6b",[132],[4213,4214],{"type":71,"value":3775},{"type":66,"tag":312,"props":4215,"children":4217},{"className":4216},[],[4218],{"type":71,"value":4219},"ba70a97",{"type":71,"value":501},{"type":66,"tag":128,"props":4222,"children":4225},{"href":4223,"rel":4224},"https://github.com/nuxt-modules/supabase/issues/43",[132],[4226],{"type":71,"value":4227},"#43",{"type":71,"value":255},{"type":66,"tag":67,"props":4230,"children":4231},{},[4232,4234,4239],{"type":71,"value":4233},"Checkout the new ",{"type":66,"tag":128,"props":4235,"children":4237},{"href":1785,"rel":4236},[132],[4238],{"type":71,"value":3366},{"type":71,"value":4240}," !",{"type":66,"tag":67,"props":4242,"children":4243},{},[4244,4248,4249],{"type":66,"tag":120,"props":4245,"children":4246},{},[4247],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":4250,"children":4253},{"href":4251,"rel":4252},"https://github.com/nuxt-community/supabase-module/compare/v0.1.14...v0.1.16",[132],[4254],{"type":71,"value":4251},{"title":59,"searchDepth":78,"depth":78,"links":4256},[4257],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.16","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.16","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.16",{"name":166,"url":167,"avatar":168},"github:v0.1.16.md",{"name":4264,"tag_name":4264,"date":4265,"body":4266,"v":294,"url":4374,"tarball":4375,"zipball":4376,"prerelease":60,"author":4377,"title":59,"description":59,"_type":80,"_id":4378},"v0.1.14","2022-05-13T16:48:40Z",{"type":63,"children":4267,"toc":4371},[4268,4272,4335,4357],{"type":66,"tag":98,"props":4269,"children":4270},{"id":100},[4271],{"type":71,"value":103},{"type":66,"tag":112,"props":4273,"children":4274},{},[4275,4292,4309],{"type":66,"tag":116,"props":4276,"children":4277},{},[4278,4280],{"type":71,"value":4279},"feat: add playground folder in ",{"type":66,"tag":128,"props":4281,"children":4284},{"href":4282,"rel":4283},"https://github.com/nuxt-community/supabase-module/commit/339cf31cf48d4059ba0e4470d6e5e2aa9ef184c7",[132],[4285,4286],{"type":71,"value":3775},{"type":66,"tag":312,"props":4287,"children":4289},{"className":4288},[],[4290],{"type":71,"value":4291},"339cf31",{"type":66,"tag":116,"props":4293,"children":4294},{},[4295,4297],{"type":71,"value":4296},"fix: client options in ",{"type":66,"tag":128,"props":4298,"children":4301},{"href":4299,"rel":4300},"https://github.com/nuxt-community/supabase-module/commit/4c5595c11caf7a55621d297f6a0183a756175473",[132],[4302,4303],{"type":71,"value":3775},{"type":66,"tag":312,"props":4304,"children":4306},{"className":4305},[],[4307],{"type":71,"value":4308},"4c5595c",{"type":66,"tag":116,"props":4310,"children":4311},{},[4312,4314,4326,4327,4334],{"type":71,"value":4313},"feat: add server routes services in ",{"type":66,"tag":128,"props":4315,"children":4318},{"href":4316,"rel":4317},"https://github.com/nuxt-community/supabase-module/commit/696d3e8d19b8db79c85e86b79a3ba4dd31bb2343",[132],[4319,4320],{"type":71,"value":3775},{"type":66,"tag":312,"props":4321,"children":4323},{"className":4322},[],[4324],{"type":71,"value":4325},"696d3e8",{"type":71,"value":501},{"type":66,"tag":128,"props":4328,"children":4331},{"href":4329,"rel":4330},"https://github.com/nuxt-modules/supabase/issues/36",[132],[4332],{"type":71,"value":4333},"#36",{"type":71,"value":255},{"type":66,"tag":67,"props":4336,"children":4337},{},[4338,4340,4347,4349,4355],{"type":71,"value":4339},"You can check the ",{"type":66,"tag":128,"props":4341,"children":4344},{"href":4342,"rel":4343},"https://supabase.nuxtjs.org/usage#server-routes-services",[132],[4345],{"type":71,"value":4346},"documentation updated",{"type":71,"value":4348}," for the use of ",{"type":66,"tag":312,"props":4350,"children":4352},{"className":4351},[],[4353],{"type":71,"value":4354},"services",{"type":71,"value":4356}," in server routes.",{"type":66,"tag":67,"props":4358,"children":4359},{},[4360,4364,4365],{"type":66,"tag":120,"props":4361,"children":4362},{},[4363],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":4366,"children":4369},{"href":4367,"rel":4368},"https://github.com/nuxt-community/supabase-module/compare/v0.1.11...v0.1.14",[132],[4370],{"type":71,"value":4367},{"title":59,"searchDepth":78,"depth":78,"links":4372},[4373],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.14","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.14","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.14",{"name":166,"url":167,"avatar":168},"github:v0.1.14.md",{"name":4380,"tag_name":4380,"date":4381,"body":4382,"v":294,"url":4408,"tarball":4409,"zipball":4410,"prerelease":60,"author":4411,"title":59,"description":59,"_type":80,"_id":4412},"v0.1.11","2022-05-06T08:51:02Z",{"type":63,"children":4383,"toc":4406},[4384,4392],{"type":66,"tag":112,"props":4385,"children":4386},{},[4387],{"type":66,"tag":116,"props":4388,"children":4389},{},[4390],{"type":71,"value":4391},"chore: upgrade deps",{"type":66,"tag":67,"props":4393,"children":4394},{},[4395,4399,4400],{"type":66,"tag":120,"props":4396,"children":4397},{},[4398],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":4401,"children":4404},{"href":4402,"rel":4403},"https://github.com/nuxt-community/supabase-module/compare/v0.1.9...v0.1.11",[132],[4405],{"type":71,"value":4402},{"title":59,"searchDepth":78,"depth":78,"links":4407},[],"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.11","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.11","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.11",{"name":166,"url":167,"avatar":168},"github:v0.1.11.md",{"name":4414,"tag_name":4414,"date":4415,"body":4416,"v":294,"url":4469,"tarball":4470,"zipball":4471,"prerelease":60,"author":4472,"title":59,"description":59,"_type":80,"_id":4476},"v0.1.9","2022-04-20T11:07:23Z",{"type":63,"children":4417,"toc":4467},[4418,4453],{"type":66,"tag":112,"props":4419,"children":4420},{},[4421],{"type":66,"tag":116,"props":4422,"children":4423},{},[4424,4426,4432,4433,4439,4440,4452],{"type":71,"value":4425},"fix: use ",{"type":66,"tag":312,"props":4427,"children":4429},{"className":4428},[],[4430],{"type":71,"value":4431},"#imports",{"type":71,"value":2972},{"type":66,"tag":312,"props":4434,"children":4436},{"className":4435},[],[4437],{"type":71,"value":4438},"#nitro",{"type":71,"value":501},{"type":66,"tag":128,"props":4441,"children":4444},{"href":4442,"rel":4443},"https://github.com/nuxt-community/supabase-module/commit/42af598b7d9f3adf2c577c20e9cfb68bbb17d52b",[132],[4445,4446],{"type":71,"value":3775},{"type":66,"tag":312,"props":4447,"children":4449},{"className":4448},[],[4450],{"type":71,"value":4451},"42af598",{"type":71,"value":255},{"type":66,"tag":67,"props":4454,"children":4455},{},[4456,4460,4461],{"type":66,"tag":120,"props":4457,"children":4458},{},[4459],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":4462,"children":4465},{"href":4463,"rel":4464},"https://github.com/nuxt-community/supabase-module/compare/v0.1.8...v0.1.9",[132],[4466],{"type":71,"value":4463},{"title":59,"searchDepth":78,"depth":78,"links":4468},[],"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.9","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.9","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.9",{"name":4473,"url":4474,"avatar":4475},"atinux","https://github.com/atinux","https://avatars.githubusercontent.com/u/904724?v=4","github:v0.1.9.md",{"name":4478,"tag_name":4478,"date":4479,"body":4480,"v":294,"url":4536,"tarball":4537,"zipball":4538,"prerelease":60,"author":4539,"title":59,"description":59,"_type":80,"_id":4540},"v0.1.8","2022-04-13T12:26:33Z",{"type":63,"children":4481,"toc":4533},[4482,4486],{"type":66,"tag":98,"props":4483,"children":4484},{"id":100},[4485],{"type":71,"value":103},{"type":66,"tag":112,"props":4487,"children":4488},{},[4489,4506],{"type":66,"tag":116,"props":4490,"children":4491},{},[4492,4494],{"type":71,"value":4493},"fix: update runtime config fetch and override in ",{"type":66,"tag":128,"props":4495,"children":4498},{"href":4496,"rel":4497},"https://github.com/nuxt-community/supabase-module/commit/260ebc7be39dfa65902ad4fe6a49639c99a69da8",[132],[4499,4500],{"type":71,"value":3775},{"type":66,"tag":312,"props":4501,"children":4503},{"className":4502},[],[4504],{"type":71,"value":4505},"260ebc7",{"type":66,"tag":116,"props":4507,"children":4508},{},[4509,4511,4523,4525,4532],{"type":71,"value":4510},"feat: handle session with defineEventHandler in ",{"type":66,"tag":128,"props":4512,"children":4515},{"href":4513,"rel":4514},"https://github.com/nuxt-community/supabase-module/commit/e646b1ce03773bf44932824726f280ad15455ec2",[132],[4516,4517],{"type":71,"value":3775},{"type":66,"tag":312,"props":4518,"children":4520},{"className":4519},[],[4521],{"type":71,"value":4522},"e646b1c",{"type":71,"value":4524}," (Check ",{"type":66,"tag":128,"props":4526,"children":4529},{"href":4527,"rel":4528},"https://v3.nuxtjs.org/guide/features/server-routes",[132],[4530],{"type":71,"value":4531},"Nuxt doc",{"type":71,"value":255},{"title":59,"searchDepth":78,"depth":78,"links":4534},[4535],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.8","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.8","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.8",{"name":166,"url":167,"avatar":168},"github:v0.1.8.md",{"name":4542,"tag_name":4542,"date":4543,"body":4544,"v":294,"url":4622,"tarball":4623,"zipball":4624,"prerelease":60,"reactions":4625,"author":4627,"title":59,"description":59,"_type":80,"_id":4628},"v0.1.7","2022-04-07T21:31:24Z",{"type":63,"children":4545,"toc":4618},[4546,4550,4593,4597],{"type":66,"tag":98,"props":4547,"children":4548},{"id":100},[4549],{"type":71,"value":103},{"type":66,"tag":112,"props":4551,"children":4552},{},[4553,4570],{"type":66,"tag":116,"props":4554,"children":4555},{},[4556,4558],{"type":71,"value":4557},"fix: assert method and use correct key for server middleware in ",{"type":66,"tag":128,"props":4559,"children":4562},{"href":4560,"rel":4561},"https://github.com/nuxt-community/supabase-module/commit/8a4d63101e6d2bc24563f7944988909ec7dcc6e5",[132],[4563,4564],{"type":71,"value":3775},{"type":66,"tag":312,"props":4565,"children":4567},{"className":4566},[],[4568],{"type":71,"value":4569},"8a4d631",{"type":66,"tag":116,"props":4571,"children":4572},{},[4573,4575,4585,4586],{"type":71,"value":4574},"fix: replace #config with #nitro by ",{"type":66,"tag":128,"props":4576,"children":4579},{"href":4577,"rel":4578},"https://github.com/psto",[132],[4580],{"type":66,"tag":120,"props":4581,"children":4582},{},[4583],{"type":71,"value":4584},"@psto",{"type":71,"value":619},{"type":66,"tag":128,"props":4587,"children":4590},{"href":4588,"rel":4589},"https://github.com/nuxt-community/supabase-module/pull/23",[132],[4591],{"type":71,"value":4592},"nuxt-community/supabase-module#23",{"type":66,"tag":98,"props":4594,"children":4595},{"id":3868},[4596],{"type":71,"value":3871},{"type":66,"tag":112,"props":4598,"children":4599},{},[4600],{"type":66,"tag":116,"props":4601,"children":4602},{},[4603,4611,4613],{"type":66,"tag":128,"props":4604,"children":4606},{"href":4577,"rel":4605},[132],[4607],{"type":66,"tag":120,"props":4608,"children":4609},{},[4610],{"type":71,"value":4584},{"type":71,"value":4612}," made their first contribution in ",{"type":66,"tag":128,"props":4614,"children":4616},{"href":4588,"rel":4615},[132],[4617],{"type":71,"value":4592},{"title":59,"searchDepth":78,"depth":78,"links":4619},[4620,4621],{"id":100,"depth":78,"text":103},{"id":3868,"depth":78,"text":3871},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.7","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.7","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.7",{"url":4626,"total_count":160,"+1":294,"-1":294,"laugh":294,"hooray":160,"confused":294,"heart":294,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/63922233/reactions",{"name":4473,"url":4474,"avatar":4475},"github:v0.1.7.md",{"name":4630,"tag_name":4630,"date":4631,"body":4632,"v":294,"url":4679,"tarball":4680,"zipball":4681,"prerelease":60,"reactions":4682,"author":4685,"title":59,"description":59,"_type":80,"_id":4686},"v0.1.5","2022-04-04T10:15:21Z",{"type":63,"children":4633,"toc":4676},[4634,4638,4662],{"type":66,"tag":105,"props":4635,"children":4636},{"id":107},[4637],{"type":71,"value":110},{"type":66,"tag":112,"props":4639,"children":4640},{},[4641],{"type":66,"tag":116,"props":4642,"children":4643},{},[4644,4646,4653,4655],{"type":71,"value":4645},"remove lodash.clonedeep (",{"type":66,"tag":128,"props":4647,"children":4650},{"href":4648,"rel":4649},"https://github.com/nuxt-community/supabase-module/commit/b5c5c60358ab192b98c8a63185f58a2eb0ab706a",[132],[4651],{"type":71,"value":4652},"b5c5c60",{"type":71,"value":4654},"), resolved ",{"type":66,"tag":128,"props":4656,"children":4659},{"href":4657,"rel":4658},"https://github.com/nuxt-modules/supabase/issues/21",[132],[4660],{"type":71,"value":4661},"#21",{"type":66,"tag":67,"props":4663,"children":4664},{},[4665,4669,4670],{"type":66,"tag":120,"props":4666,"children":4667},{},[4668],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":4671,"children":4674},{"href":4672,"rel":4673},"https://github.com/nuxt-community/supabase-module/compare/v0.1.4...v0.1.5",[132],[4675],{"type":71,"value":4672},{"title":59,"searchDepth":78,"depth":78,"links":4677},[4678],{"id":107,"depth":160,"text":110},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.5","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.5","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.5",{"url":4683,"total_count":4684,"+1":294,"-1":294,"laugh":294,"hooray":585,"confused":294,"heart":78,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/63507078/reactions",6,{"name":4473,"url":4474,"avatar":4475},"github:v0.1.5.md",1724940863160] \ No newline at end of file +[{"data":1,"prerenderedAt":4687},["ShallowReactive",2],{"navigation":3,"/changelog":58,"/changelog-surround":86,"releases":91},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":52,"_dir":59,"_draft":60,"_partial":60,"_locale":59,"title":51,"description":61,"icon":53,"body":62,"_type":80,"_id":81,"_source":82,"_file":83,"_stem":84,"_extension":85},"",false,"Discover the latest updates of the Supabase Module",{"type":63,"children":64,"toc":77},"root",[65,73],{"type":66,"tag":67,"props":68,"children":69},"element","p",{},[70],{"type":71,"value":72},"text","Discover the lastest updates.",{"type":66,"tag":74,"props":75,"children":76},"releases",{},[],{"title":59,"searchDepth":78,"depth":78,"links":79},2,[],"markdown","content:6.changelog.md","content","6.changelog.md","6.changelog","md",[87,89],{"_path":48,"title":47,"description":88},"Demonstration of using Supabase with Nuxt.",{"_path":56,"title":55,"description":90},"Discover our kaban board for the next release of the Supabase module.",[92,170,222,297,532,588,688,786,890,1015,1190,1259,1365,1605,1698,2002,2104,2181,2247,2546,2820,2893,3025,3070,3130,3182,3329,3428,3491,3542,3587,3639,3752,3828,3906,3970,4055,4157,4263,4379,4413,4477,4541,4629],{"name":93,"tag_name":93,"date":94,"body":95,"v":161,"url":162,"tarball":163,"zipball":164,"prerelease":60,"author":165,"title":59,"description":59,"_type":80,"_id":169},"v1.3.5","2024-07-15T12:59:37Z",{"type":63,"children":96,"toc":155},[97,104,111,145],{"type":66,"tag":98,"props":99,"children":101},"h2",{"id":100},"whats-changed",[102],{"type":71,"value":103},"What's Changed",{"type":66,"tag":105,"props":106,"children":108},"h3",{"id":107},"bug-fixes",[109],{"type":71,"value":110},"Bug Fixes",{"type":66,"tag":112,"props":113,"children":114},"ul",{},[115],{"type":66,"tag":116,"props":117,"children":118},"li",{},[119,125,127,136,138],{"type":66,"tag":120,"props":121,"children":122},"strong",{},[123],{"type":71,"value":124},"types:",{"type":71,"value":126}," generate (",{"type":66,"tag":128,"props":129,"children":133},"a",{"href":130,"rel":131},"https://github.com/nuxt-community/supabase-module/commit/671295a3f8e1743384913f2940975c2e4217ff2e",[132],"nofollow",[134],{"type":71,"value":135},"671295a",{"type":71,"value":137},") resolves ",{"type":66,"tag":128,"props":139,"children":142},{"href":140,"rel":141},"https://github.com/nuxt-modules/supabase/issues/383",[132],[143],{"type":71,"value":144},"#383",{"type":66,"tag":67,"props":146,"children":147},{},[148],{"type":66,"tag":128,"props":149,"children":152},{"href":150,"rel":151},"https://github.com/nuxt-community/supabase-module/compare/v1.3.4...v1.3.5",[132],[153],{"type":71,"value":154},"Full changelog",{"title":59,"searchDepth":78,"depth":78,"links":156},[157],{"id":100,"depth":78,"text":103,"children":158},[159],{"id":107,"depth":160,"text":110},3,1,"https://github.com/nuxt-modules/supabase/releases/tag/v1.3.5","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.3.5","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.3.5",{"name":166,"url":167,"avatar":168},"larbish","https://github.com/larbish","https://avatars.githubusercontent.com/u/7290030?v=4","github:v1.3.5.md",{"name":171,"tag_name":171,"date":172,"body":173,"v":161,"url":217,"tarball":218,"zipball":219,"prerelease":60,"author":220,"title":59,"description":59,"_type":80,"_id":221},"v1.3.4","2024-07-10T07:00:38Z",{"type":63,"children":174,"toc":212},[175,179,183],{"type":66,"tag":98,"props":176,"children":177},{"id":100},[178],{"type":71,"value":103},{"type":66,"tag":105,"props":180,"children":181},{"id":107},[182],{"type":71,"value":110},{"type":66,"tag":112,"props":184,"children":185},{},[186],{"type":66,"tag":116,"props":187,"children":188},{},[189,194,196,203,205],{"type":66,"tag":120,"props":190,"children":191},{},[192],{"type":71,"value":193},"vite:",{"type":71,"value":195}," optimize order (",{"type":66,"tag":128,"props":197,"children":200},{"href":198,"rel":199},"https://github.com/nuxt-community/supabase-module/commit/663bd73ebb146ecde1abe5f29b52326e6dc2b6cd",[132],[201],{"type":71,"value":202},"663bd73",{"type":71,"value":204},") fixes ",{"type":66,"tag":128,"props":206,"children":209},{"href":207,"rel":208},"https://github.com/nuxt-modules/supabase/issues/385",[132],[210],{"type":71,"value":211},"#385",{"title":59,"searchDepth":78,"depth":78,"links":213},[214],{"id":100,"depth":78,"text":103,"children":215},[216],{"id":107,"depth":160,"text":110},"https://github.com/nuxt-modules/supabase/releases/tag/v1.3.4","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.3.4","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.3.4",{"name":166,"url":167,"avatar":168},"github:v1.3.4.md",{"name":223,"tag_name":223,"date":224,"body":225,"v":161,"url":289,"tarball":290,"zipball":291,"prerelease":60,"reactions":292,"author":295,"title":59,"description":59,"_type":80,"_id":296},"v1.3.2","2024-07-05T16:26:23Z",{"type":63,"children":226,"toc":283},[227,231,235,256,262],{"type":66,"tag":98,"props":228,"children":229},{"id":100},[230],{"type":71,"value":103},{"type":66,"tag":105,"props":232,"children":233},{"id":107},[234],{"type":71,"value":110},{"type":66,"tag":112,"props":236,"children":237},{},[238],{"type":66,"tag":116,"props":239,"children":240},{},[241,245,247,254],{"type":66,"tag":120,"props":242,"children":243},{},[244],{"type":71,"value":193},{"type":71,"value":246}," optimize postgrest (",{"type":66,"tag":128,"props":248,"children":251},{"href":249,"rel":250},"https://github.com/nuxt-community/supabase-module/commit/2a6d91a3ee83aa65cc5741afea907ca474e61d64",[132],[252],{"type":71,"value":253},"2a6d91a",{"type":71,"value":255},")",{"type":66,"tag":105,"props":257,"children":259},{"id":258},"features",[260],{"type":71,"value":261},"Features",{"type":66,"tag":112,"props":263,"children":264},{},[265],{"type":66,"tag":116,"props":266,"children":267},{},[268,273,275,282],{"type":66,"tag":120,"props":269,"children":270},{},[271],{"type":71,"value":272},"ci:",{"type":71,"value":274}," nightly version (",{"type":66,"tag":128,"props":276,"children":279},{"href":277,"rel":278},"https://github.com/nuxt-community/supabase-module/commit/298e608442ac5e8c15aa61c01411585e57732f4a",[132],[280],{"type":71,"value":281},"298e608",{"type":71,"value":255},{"title":59,"searchDepth":78,"depth":78,"links":284},[285],{"id":100,"depth":78,"text":103,"children":286},[287,288],{"id":107,"depth":160,"text":110},{"id":258,"depth":160,"text":261},"https://github.com/nuxt-modules/supabase/releases/tag/v1.3.2","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.3.2","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.3.2",{"url":293,"total_count":161,"+1":294,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":161,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/164188781/reactions",0,{"name":166,"url":167,"avatar":168},"github:v1.3.2.md",{"name":298,"tag_name":298,"date":299,"body":300,"v":161,"url":525,"tarball":526,"zipball":527,"prerelease":60,"reactions":528,"author":530,"title":59,"description":59,"_type":80,"_id":531},"v1.3.1","2024-07-05T12:25:51Z",{"type":63,"children":301,"toc":519},[302,306,328,334,356,374,388,401,406,459,476,482,510],{"type":66,"tag":98,"props":303,"children":304},{"id":100},[305],{"type":71,"value":103},{"type":66,"tag":67,"props":307,"children":308},{},[309,311,318,320,326],{"type":71,"value":310},"⚠️ You can switch directly to ",{"type":66,"tag":312,"props":313,"children":315},"code",{"className":314},[],[316],{"type":71,"value":317},"1.3.1",{"type":71,"value":319},", since ",{"type":66,"tag":312,"props":321,"children":323},{"className":322},[],[324],{"type":71,"value":325},"1.3.0",{"type":71,"value":327}," has been superseded.",{"type":66,"tag":105,"props":329,"children":331},{"id":330},"major-changes",[332],{"type":71,"value":333},"Major changes",{"type":66,"tag":67,"props":335,"children":336},{},[337,339,346,348,355],{"type":71,"value":338},"We're now using the ",{"type":66,"tag":128,"props":340,"children":343},{"href":341,"rel":342},"https://supabase.com/docs/guides/auth/server-side/creating-a-client",[132],[344],{"type":71,"value":345},"@supabase/ssr",{"type":71,"value":347}," library under the hood 🎉 (",{"type":66,"tag":128,"props":349,"children":352},{"href":350,"rel":351},"https://github.com/nuxt-modules/supabase/issues/357",[132],[353],{"type":71,"value":354},"#357",{"type":71,"value":255},{"type":66,"tag":67,"props":357,"children":358},{},[359,361,366,368],{"type":71,"value":360},"There are ",{"type":66,"tag":120,"props":362,"children":363},{},[364],{"type":71,"value":365},"no breaking changes",{"type":71,"value":367}," related to this improvement. However, a non-disruptive warning appears in this release:\r\n",{"type":66,"tag":312,"props":369,"children":371},{"className":370},[],[372],{"type":71,"value":373},"Using the user object as returned from supabase.auth.getSession() or from some supabase.auth.onAuthStateChange() events could be insecure.",{"type":66,"tag":67,"props":375,"children":376},{},[377,379,386],{"type":71,"value":378},"This warning is related to ",{"type":66,"tag":128,"props":380,"children":383},{"href":381,"rel":382},"https://github.com/supabase/auth-js/issues/912",[132],[384],{"type":71,"value":385},"an issue",{"type":71,"value":387}," in the Supabase library itself. Initially, I intended to wait for this fix but since managing updates across two separate branches is challenging I chose to merge it anyway. I could no longer delay the release due to users raising concerns about outdated dependencies and other issues within the module.",{"type":66,"tag":67,"props":389,"children":390},{},[391,393,399],{"type":71,"value":392},"You can upvote ",{"type":66,"tag":128,"props":394,"children":396},{"href":381,"rel":395},[132],[397],{"type":71,"value":398},"the issue",{"type":71,"value":400}," to encourage the Supabase maintainers to address it.",{"type":66,"tag":67,"props":402,"children":403},{},[404],{"type":71,"value":405},"This improvement might fix:",{"type":66,"tag":112,"props":407,"children":408},{},[409,419,429,439,449],{"type":66,"tag":116,"props":410,"children":411},{},[412],{"type":66,"tag":128,"props":413,"children":416},{"href":414,"rel":415},"https://github.com/nuxt-modules/supabase/issues/298",[132],[417],{"type":71,"value":418},"#298",{"type":66,"tag":116,"props":420,"children":421},{},[422],{"type":66,"tag":128,"props":423,"children":426},{"href":424,"rel":425},"https://github.com/nuxt-modules/supabase/issues/381",[132],[427],{"type":71,"value":428},"#381",{"type":66,"tag":116,"props":430,"children":431},{},[432],{"type":66,"tag":128,"props":433,"children":436},{"href":434,"rel":435},"https://github.com/nuxt-modules/supabase/issues/380",[132],[437],{"type":71,"value":438},"#380",{"type":66,"tag":116,"props":440,"children":441},{},[442],{"type":66,"tag":128,"props":443,"children":446},{"href":444,"rel":445},"https://github.com/nuxt-modules/supabase/issues/367",[132],[447],{"type":71,"value":448},"#367",{"type":66,"tag":116,"props":450,"children":451},{},[452],{"type":66,"tag":128,"props":453,"children":456},{"href":454,"rel":455},"https://github.com/nuxt-modules/supabase/issues/326",[132],[457],{"type":71,"value":458},"#326",{"type":66,"tag":67,"props":460,"children":461},{},[462,464,474],{"type":71,"value":463},"A big thanks to ",{"type":66,"tag":128,"props":465,"children":468},{"href":466,"rel":467},"https://github.com/felixgabler",[132],[469],{"type":66,"tag":120,"props":470,"children":471},{},[472],{"type":71,"value":473},"@felixgabler",{"type":71,"value":475}," for initiating this change and helping refactor the module.",{"type":66,"tag":105,"props":477,"children":479},{"id":478},"other-update",[480],{"type":71,"value":481},"Other update",{"type":66,"tag":112,"props":483,"children":484},{},[485],{"type":66,"tag":116,"props":486,"children":487},{},[488,490,500,502,509],{"type":71,"value":489},"Automatic database types by ",{"type":66,"tag":128,"props":491,"children":494},{"href":492,"rel":493},"https://github.com/IsraelOrtuno",[132],[495],{"type":66,"tag":120,"props":496,"children":497},{},[498],{"type":71,"value":499},"@IsraelOrtuno",{"type":71,"value":501}," (",{"type":66,"tag":128,"props":503,"children":506},{"href":504,"rel":505},"https://github.com/nuxt-modules/supabase/issues/336",[132],[507],{"type":71,"value":508},"#336",{"type":71,"value":255},{"type":66,"tag":67,"props":511,"children":512},{},[513],{"type":66,"tag":128,"props":514,"children":517},{"href":515,"rel":516},"https://github.com/nuxt-community/supabase-module/compare/v1.2.2...v1.3.1",[132],[518],{"type":71,"value":154},{"title":59,"searchDepth":78,"depth":78,"links":520},[521],{"id":100,"depth":78,"text":103,"children":522},[523,524],{"id":330,"depth":160,"text":333},{"id":478,"depth":160,"text":481},"https://github.com/nuxt-modules/supabase/releases/tag/v1.3.1","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.3.1","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.3.1",{"url":529,"total_count":78,"+1":294,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":78,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/164152561/reactions",{"name":166,"url":167,"avatar":168},"github:v1.3.1.md",{"name":533,"tag_name":533,"date":534,"body":535,"v":161,"url":580,"tarball":581,"zipball":582,"prerelease":60,"reactions":583,"author":586,"title":59,"description":59,"_type":80,"_id":587},"v1.2.2","2024-05-02T15:33:41Z",{"type":63,"children":536,"toc":575},[537,541,545,566],{"type":66,"tag":98,"props":538,"children":539},{"id":100},[540],{"type":71,"value":103},{"type":66,"tag":105,"props":542,"children":543},{"id":107},[544],{"type":71,"value":110},{"type":66,"tag":112,"props":546,"children":547},{},[548],{"type":66,"tag":116,"props":549,"children":550},{},[551,556,558,565],{"type":66,"tag":120,"props":552,"children":553},{},[554],{"type":71,"value":555},"serverSupabaseSession:",{"type":71,"value":557}," export service (",{"type":66,"tag":128,"props":559,"children":562},{"href":560,"rel":561},"https://github.com/nuxt-community/supabase-module/commit/9cfeb8726d562c5aac6fe1efa7dd1664bc39ed66",[132],[563],{"type":71,"value":564},"9cfeb87",{"type":71,"value":255},{"type":66,"tag":67,"props":567,"children":568},{},[569],{"type":66,"tag":128,"props":570,"children":573},{"href":571,"rel":572},"https://github.com/nuxt-community/supabase-module/compare/v1.2.1...v1.2.2",[132],[574],{"type":71,"value":154},{"title":59,"searchDepth":78,"depth":78,"links":576},[577],{"id":100,"depth":78,"text":103,"children":578},[579],{"id":107,"depth":160,"text":110},"https://github.com/nuxt-modules/supabase/releases/tag/v1.2.2","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.2.2","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.2.2",{"url":584,"total_count":585,"+1":294,"-1":294,"laugh":294,"hooray":161,"confused":294,"heart":78,"rocket":294,"eyes":161},"https://api.github.com/repos/nuxt-modules/supabase/releases/153851448/reactions",4,{"name":166,"url":167,"avatar":168},"github:v1.2.2.md",{"name":589,"tag_name":589,"date":590,"body":591,"v":161,"url":680,"tarball":681,"zipball":682,"prerelease":60,"reactions":683,"author":686,"title":59,"description":59,"_type":80,"_id":687},"v1.2.1","2024-04-18T08:32:42Z",{"type":63,"children":592,"toc":673},[593,597,603,627,633,647,653,664],{"type":66,"tag":98,"props":594,"children":595},{"id":100},[596],{"type":71,"value":103},{"type":66,"tag":105,"props":598,"children":600},{"id":599},"improvements",[601],{"type":71,"value":602},"Improvements",{"type":66,"tag":67,"props":604,"children":605},{},[606,608,618,620],{"type":71,"value":607},"Performance improvements by ",{"type":66,"tag":128,"props":609,"children":612},{"href":610,"rel":611},"https://github.com/vinceglb",[132],[613],{"type":66,"tag":120,"props":614,"children":615},{},[616],{"type":71,"value":617},"@vinceglb",{"type":71,"value":619}," in ",{"type":66,"tag":128,"props":621,"children":624},{"href":622,"rel":623},"https://github.com/nuxt-modules/supabase/issues/352",[132],[625],{"type":71,"value":626},"#352",{"type":66,"tag":105,"props":628,"children":630},{"id":629},"chore",[631],{"type":71,"value":632},"Chore",{"type":66,"tag":67,"props":634,"children":635},{},[636,638,645],{"type":71,"value":637},"Move to eslint v9 using ",{"type":66,"tag":128,"props":639,"children":642},{"href":640,"rel":641},"https://eslint.nuxt.com",[132],[643],{"type":71,"value":644},"@nuxt/eslint",{"type":71,"value":646}," package",{"type":66,"tag":105,"props":648,"children":650},{"id":649},"thanks-for-the-help-from",[651],{"type":71,"value":652},"💚 Thanks for the help from:",{"type":66,"tag":67,"props":654,"children":655},{},[656],{"type":66,"tag":128,"props":657,"children":659},{"href":610,"rel":658},[132],[660],{"type":66,"tag":120,"props":661,"children":662},{},[663],{"type":71,"value":617},{"type":66,"tag":67,"props":665,"children":666},{},[667],{"type":66,"tag":128,"props":668,"children":671},{"href":669,"rel":670},"https://github.com/nuxt-community/supabase-module/compare/v1.2.0...v1.2.1",[132],[672],{"type":71,"value":154},{"title":59,"searchDepth":78,"depth":78,"links":674},[675],{"id":100,"depth":78,"text":103,"children":676},[677,678,679],{"id":599,"depth":160,"text":602},{"id":629,"depth":160,"text":632},{"id":649,"depth":160,"text":652},"https://github.com/nuxt-modules/supabase/releases/tag/v1.2.1","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.2.1","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.2.1",{"url":684,"total_count":685,"+1":294,"-1":294,"laugh":294,"hooray":78,"confused":294,"heart":160,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/151694236/reactions",5,{"name":166,"url":167,"avatar":168},"github:v1.2.1.md",{"name":689,"tag_name":689,"date":690,"body":691,"v":161,"url":781,"tarball":782,"zipball":783,"prerelease":60,"author":784,"title":59,"description":59,"_type":80,"_id":785},"v1.2.0","2024-03-29T09:33:20Z",{"type":63,"children":692,"toc":776},[693,697,703,748,767],{"type":66,"tag":98,"props":694,"children":695},{"id":100},[696],{"type":71,"value":103},{"type":66,"tag":105,"props":698,"children":700},{"id":699},"minor-version-since-we-have-a-new-composable",[701],{"type":71,"value":702},"Minor version since we have a new composable 🎉",{"type":66,"tag":67,"props":704,"children":705},{},[706,712,714,720,722,729,731,738,740,747],{"type":66,"tag":128,"props":707,"children":710},{"href":708,"rel":709},"https://supabase.nuxtjs.org/usage/composables/usesupabasesession",[132],[711],{"type":71,"value":24},{"type":71,"value":713}," and ",{"type":66,"tag":128,"props":715,"children":718},{"href":716,"rel":717},"https://supabase.nuxtjs.org/usage/services/serversupabasesession",[132],[719],{"type":71,"value":40},{"type":71,"value":721}," are now available to fetch your session client and server side (",{"type":66,"tag":128,"props":723,"children":726},{"href":724,"rel":725},"https://github.com/nuxt-community/supabase-module/issues/338",[132],[727],{"type":71,"value":728},"#338",{"type":71,"value":730},") (",{"type":66,"tag":128,"props":732,"children":735},{"href":733,"rel":734},"https://github.com/nuxt-community/supabase-module/commit/07eb081d532510da4152554c7010c79ed6008559",[132],[736],{"type":71,"value":737},"07eb081",{"type":71,"value":739}," & ",{"type":66,"tag":128,"props":741,"children":744},{"href":742,"rel":743},"https://github.com/nuxt-community/supabase-module/commit/9dee37ee030506fc7888dfbb6cc1f29b9126a728",[132],[745],{"type":71,"value":746},"9dee37e",{"type":71,"value":255},{"type":66,"tag":749,"props":750,"children":752},"h4",{"id":751},"thanks-joeychilson-for-this-feature",[753,755,765],{"type":71,"value":754},"Thanks ",{"type":66,"tag":128,"props":756,"children":759},{"href":757,"rel":758},"https://github.com/joeychilson",[132],[760],{"type":66,"tag":120,"props":761,"children":762},{},[763],{"type":71,"value":764},"@joeychilson",{"type":71,"value":766}," for this feature 🙏",{"type":66,"tag":67,"props":768,"children":769},{},[770],{"type":66,"tag":128,"props":771,"children":774},{"href":772,"rel":773},"https://github.com/nuxt-community/supabase-module/compare/v1.1.7...v1.2.0",[132],[775],{"type":71,"value":154},{"title":59,"searchDepth":78,"depth":78,"links":777},[778],{"id":100,"depth":78,"text":103,"children":779},[780],{"id":699,"depth":160,"text":702},"https://github.com/nuxt-modules/supabase/releases/tag/v1.2.0","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.2.0","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.2.0",{"name":166,"url":167,"avatar":168},"github:v1.2.0.md",{"name":787,"tag_name":787,"date":788,"body":789,"v":161,"url":883,"tarball":884,"zipball":885,"prerelease":60,"reactions":886,"author":888,"title":59,"description":59,"_type":80,"_id":889},"v1.1.7","2024-03-07T09:33:03Z",{"type":63,"children":790,"toc":877},[791,795,799,850,855,868],{"type":66,"tag":98,"props":792,"children":793},{"id":100},[794],{"type":71,"value":103},{"type":66,"tag":105,"props":796,"children":797},{"id":258},[798],{"type":71,"value":261},{"type":66,"tag":112,"props":800,"children":801},{},[802],{"type":66,"tag":116,"props":803,"children":804},{},[805,810,812,818,820,826,827,833,834,841,843],{"type":66,"tag":120,"props":806,"children":807},{},[808],{"type":71,"value":809},"auth-middleware:",{"type":71,"value":811}," add ",{"type":66,"tag":312,"props":813,"children":815},{"className":814},[],[816],{"type":71,"value":817},"include",{"type":71,"value":819}," to ",{"type":66,"tag":312,"props":821,"children":823},{"className":822},[],[824],{"type":71,"value":825},"RedirectOptions",{"type":71,"value":501},{"type":66,"tag":128,"props":828,"children":831},{"href":829,"rel":830},"https://github.com/nuxt-community/supabase-module/issues/336",[132],[832],{"type":71,"value":508},{"type":71,"value":730},{"type":66,"tag":128,"props":835,"children":838},{"href":836,"rel":837},"https://github.com/nuxt-community/supabase-module/commit/f9aad558da8171af1c442a60915c979eb10b8fab",[132],[839],{"type":71,"value":840},"f9aad55",{"type":71,"value":842},"), closes ",{"type":66,"tag":128,"props":844,"children":847},{"href":845,"rel":846},"https://github.com/nuxt-community/supabase-module/issues/268",[132],[848],{"type":71,"value":849},"#268",{"type":66,"tag":105,"props":851,"children":852},{"id":649},[853],{"type":71,"value":854},"💚 Thanks for the help from",{"type":66,"tag":67,"props":856,"children":857},{},[858],{"type":66,"tag":128,"props":859,"children":862},{"href":860,"rel":861},"https://github.com/jojomatik",[132],[863],{"type":66,"tag":120,"props":864,"children":865},{},[866],{"type":71,"value":867},"@jojomatik",{"type":66,"tag":67,"props":869,"children":870},{},[871],{"type":66,"tag":128,"props":872,"children":875},{"href":873,"rel":874},"https://github.com/nuxt-community/supabase-module/compare/v1.1.6...v1.1.7",[132],[876],{"type":71,"value":154},{"title":59,"searchDepth":78,"depth":78,"links":878},[879],{"id":100,"depth":78,"text":103,"children":880},[881,882],{"id":258,"depth":160,"text":261},{"id":649,"depth":160,"text":854},"https://github.com/nuxt-modules/supabase/releases/tag/v1.1.7","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.1.7","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.1.7",{"url":887,"total_count":161,"+1":294,"-1":294,"laugh":294,"hooray":161,"confused":294,"heart":294,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/145217172/reactions",{"name":166,"url":167,"avatar":168},"github:v1.1.7.md",{"name":891,"tag_name":891,"date":892,"body":893,"v":161,"url":1008,"tarball":1009,"zipball":1010,"prerelease":60,"reactions":1011,"author":1013,"title":59,"description":59,"_type":80,"_id":1014},"v1.1.6","2024-01-26T15:22:23Z",{"type":63,"children":894,"toc":1001},[895,899,903,942,946,975,979,992],{"type":66,"tag":98,"props":896,"children":897},{"id":100},[898],{"type":71,"value":103},{"type":66,"tag":105,"props":900,"children":901},{"id":107},[902],{"type":71,"value":110},{"type":66,"tag":112,"props":904,"children":905},{},[906,924],{"type":66,"tag":116,"props":907,"children":908},{},[909,914,916,923],{"type":66,"tag":120,"props":910,"children":911},{},[912],{"type":71,"value":913},"deps:",{"type":71,"value":915}," set resolution (",{"type":66,"tag":128,"props":917,"children":920},{"href":918,"rel":919},"https://github.com/nuxt-community/supabase-module/commit/db8c102fb9d69395528eece3e1e0552a16e673da",[132],[921],{"type":71,"value":922},"db8c102",{"type":71,"value":255},{"type":66,"tag":116,"props":925,"children":926},{},[927,932,934,941],{"type":66,"tag":120,"props":928,"children":929},{},[930],{"type":71,"value":931},"playground:",{"type":71,"value":933}," watch on confirm page (",{"type":66,"tag":128,"props":935,"children":938},{"href":936,"rel":937},"https://github.com/nuxt-community/supabase-module/commit/0caf5c11d632df6b7e74e5e8973ee56a38b1c968",[132],[939],{"type":71,"value":940},"0caf5c1",{"type":71,"value":255},{"type":66,"tag":105,"props":943,"children":944},{"id":258},[945],{"type":71,"value":261},{"type":66,"tag":112,"props":947,"children":948},{},[949],{"type":66,"tag":116,"props":950,"children":951},{},[952,957,959,966,967,974],{"type":66,"tag":120,"props":953,"children":954},{},[955],{"type":71,"value":956},"app:",{"type":71,"value":958}," added redirect path cookie for use after signin (",{"type":66,"tag":128,"props":960,"children":963},{"href":961,"rel":962},"https://github.com/nuxt-community/supabase-module/issues/327",[132],[964],{"type":71,"value":965},"#327",{"type":71,"value":730},{"type":66,"tag":128,"props":968,"children":971},{"href":969,"rel":970},"https://github.com/nuxt-community/supabase-module/commit/1b78a050fdc6da155434e261823b029f9dce2d40",[132],[972],{"type":71,"value":973},"1b78a05",{"type":71,"value":255},{"type":66,"tag":105,"props":976,"children":977},{"id":649},[978],{"type":71,"value":854},{"type":66,"tag":67,"props":980,"children":981},{},[982],{"type":66,"tag":128,"props":983,"children":986},{"href":984,"rel":985},"https://github.com/Matthewenderle",[132],[987],{"type":66,"tag":120,"props":988,"children":989},{},[990],{"type":71,"value":991},"@Matthewenderle",{"type":66,"tag":67,"props":993,"children":994},{},[995],{"type":66,"tag":128,"props":996,"children":999},{"href":997,"rel":998},"https://github.com/nuxt-community/supabase-module/compare/v1.1.5...v1.1.6",[132],[1000],{"type":71,"value":154},{"title":59,"searchDepth":78,"depth":78,"links":1002},[1003],{"id":100,"depth":78,"text":103,"children":1004},[1005,1006,1007],{"id":107,"depth":160,"text":110},{"id":258,"depth":160,"text":261},{"id":649,"depth":160,"text":854},"https://github.com/nuxt-modules/supabase/releases/tag/v1.1.6","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.1.6","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.1.6",{"url":1012,"total_count":160,"+1":294,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":160,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/138681536/reactions",{"name":166,"url":167,"avatar":168},"github:v1.1.6.md",{"name":1016,"tag_name":1016,"date":1017,"body":1018,"v":161,"url":1183,"tarball":1184,"zipball":1185,"prerelease":60,"reactions":1186,"author":1188,"title":59,"description":59,"_type":80,"_id":1189},"v1.1.5","2023-12-28T14:29:18Z",{"type":63,"children":1019,"toc":1175},[1020,1024,1028,1049,1053,1072,1078,1115,1119,1166],{"type":66,"tag":98,"props":1021,"children":1022},{"id":100},[1023],{"type":71,"value":103},{"type":66,"tag":105,"props":1025,"children":1026},{"id":107},[1027],{"type":71,"value":110},{"type":66,"tag":112,"props":1029,"children":1030},{},[1031],{"type":66,"tag":116,"props":1032,"children":1033},{},[1034,1039,1041,1048],{"type":66,"tag":120,"props":1035,"children":1036},{},[1037],{"type":71,"value":1038},"server:",{"type":71,"value":1040}," fetch user from session (",{"type":66,"tag":128,"props":1042,"children":1045},{"href":1043,"rel":1044},"https://github.com/nuxt-community/supabase-module/commit/7a3b73c36cc9aea10100a0ff37b0e0e7ecefe2a8",[132],[1046],{"type":71,"value":1047},"7a3b73c",{"type":71,"value":255},{"type":66,"tag":105,"props":1050,"children":1051},{"id":599},[1052],{"type":71,"value":602},{"type":66,"tag":112,"props":1054,"children":1055},{},[1056],{"type":66,"tag":116,"props":1057,"children":1058},{},[1059,1063,1065],{"type":66,"tag":120,"props":1060,"children":1061},{},[1062],{"type":71,"value":956},{"type":71,"value":1064}," use module-builder stub mode for more accurate types ",{"type":66,"tag":128,"props":1066,"children":1069},{"href":1067,"rel":1068},"https://github.com/nuxt-modules/supabase/issues/315",[132],[1070],{"type":71,"value":1071},"#315",{"type":66,"tag":105,"props":1073,"children":1075},{"id":1074},"docs",[1076],{"type":71,"value":1077},"Docs",{"type":66,"tag":112,"props":1079,"children":1080},{},[1081,1098],{"type":66,"tag":116,"props":1082,"children":1083},{},[1084,1089,1091],{"type":66,"tag":120,"props":1085,"children":1086},{},[1087],{"type":71,"value":1088},"get-started:",{"type":71,"value":1090}," bun command ",{"type":66,"tag":128,"props":1092,"children":1095},{"href":1093,"rel":1094},"https://github.com/nuxt-modules/supabase/issues/317",[132],[1096],{"type":71,"value":1097},"#317",{"type":66,"tag":116,"props":1099,"children":1100},{},[1101,1106,1108],{"type":66,"tag":120,"props":1102,"children":1103},{},[1104],{"type":71,"value":1105},"readme:",{"type":71,"value":1107}," typo in #dev section ",{"type":66,"tag":128,"props":1109,"children":1112},{"href":1110,"rel":1111},"https://github.com/nuxt-modules/supabase/issues/316",[132],[1113],{"type":71,"value":1114},"#316",{"type":66,"tag":105,"props":1116,"children":1117},{"id":649},[1118],{"type":71,"value":854},{"type":66,"tag":67,"props":1120,"children":1121},{},[1122,1132,1134,1144,1145,1155,1156],{"type":66,"tag":128,"props":1123,"children":1126},{"href":1124,"rel":1125},"https://github.com/danielroe",[132],[1127],{"type":66,"tag":120,"props":1128,"children":1129},{},[1130],{"type":71,"value":1131},"@danielroe",{"type":71,"value":1133},"\r\n",{"type":66,"tag":128,"props":1135,"children":1138},{"href":1136,"rel":1137},"https://github.com/joshuabyler",[132],[1139],{"type":66,"tag":120,"props":1140,"children":1141},{},[1142],{"type":71,"value":1143},"@joshuabyler",{"type":71,"value":1133},{"type":66,"tag":128,"props":1146,"children":1149},{"href":1147,"rel":1148},"https://github.com/hafizjavaid",[132],[1150],{"type":66,"tag":120,"props":1151,"children":1152},{},[1153],{"type":71,"value":1154},"@hafizjavaid",{"type":71,"value":1133},{"type":66,"tag":128,"props":1157,"children":1160},{"href":1158,"rel":1159},"https://github.com/relisora",[132],[1161],{"type":66,"tag":120,"props":1162,"children":1163},{},[1164],{"type":71,"value":1165},"@relisora",{"type":66,"tag":67,"props":1167,"children":1168},{},[1169],{"type":66,"tag":128,"props":1170,"children":1173},{"href":1171,"rel":1172},"https://github.com/nuxt-community/supabase-module/compare/v1.1.4...v1.1.5",[132],[1174],{"type":71,"value":154},{"title":59,"searchDepth":78,"depth":78,"links":1176},[1177],{"id":100,"depth":78,"text":103,"children":1178},[1179,1180,1181,1182],{"id":107,"depth":160,"text":110},{"id":599,"depth":160,"text":602},{"id":1074,"depth":160,"text":1077},{"id":649,"depth":160,"text":854},"https://github.com/nuxt-modules/supabase/releases/tag/v1.1.5","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.1.5","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.1.5",{"url":1187,"total_count":585,"+1":160,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":161,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/135279818/reactions",{"name":166,"url":167,"avatar":168},"github:v1.1.5.md",{"name":1191,"tag_name":1191,"date":1192,"body":1193,"v":161,"url":1252,"tarball":1253,"zipball":1254,"prerelease":60,"reactions":1255,"author":1257,"title":59,"description":59,"_type":80,"_id":1258},"v1.1.4","2023-11-17T14:42:47Z",{"type":63,"children":1194,"toc":1247},[1195,1199,1203,1232],{"type":66,"tag":98,"props":1196,"children":1197},{"id":100},[1198],{"type":71,"value":103},{"type":66,"tag":105,"props":1200,"children":1201},{"id":107},[1202],{"type":71,"value":110},{"type":66,"tag":112,"props":1204,"children":1205},{},[1206],{"type":66,"tag":116,"props":1207,"children":1208},{},[1209,1214,1216,1223,1224,1231],{"type":66,"tag":120,"props":1210,"children":1211},{},[1212],{"type":71,"value":1213},"client:",{"type":71,"value":1215}," prevent useCookie usage outside of effect scope (",{"type":66,"tag":128,"props":1217,"children":1220},{"href":1218,"rel":1219},"https://github.com/nuxt-community/supabase-module/issues/309",[132],[1221],{"type":71,"value":1222},"#309",{"type":71,"value":730},{"type":66,"tag":128,"props":1225,"children":1228},{"href":1226,"rel":1227},"https://github.com/nuxt-community/supabase-module/commit/bb55bed870efb68c39f255ddbcbe0b5446965399",[132],[1229],{"type":71,"value":1230},"bb55bed",{"type":71,"value":255},{"type":66,"tag":67,"props":1233,"children":1234},{},[1235,1237],{"type":71,"value":1236},"💚 Thanks for the help from 💚\r\n",{"type":66,"tag":128,"props":1238,"children":1241},{"href":1239,"rel":1240},"https://github.com/AlbertBrand",[132],[1242],{"type":66,"tag":120,"props":1243,"children":1244},{},[1245],{"type":71,"value":1246},"@AlbertBrand",{"title":59,"searchDepth":78,"depth":78,"links":1248},[1249],{"id":100,"depth":78,"text":103,"children":1250},[1251],{"id":107,"depth":160,"text":110},"https://github.com/nuxt-modules/supabase/releases/tag/v1.1.4","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.1.4","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.1.4",{"url":1256,"total_count":161,"+1":161,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":294,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/129966845/reactions",{"name":166,"url":167,"avatar":168},"github:v1.1.4.md",{"name":1260,"tag_name":1260,"date":1261,"body":1262,"v":161,"url":1358,"tarball":1359,"zipball":1360,"prerelease":60,"reactions":1361,"author":1363,"title":59,"description":59,"_type":80,"_id":1364},"v1.1.3","2023-10-06T07:51:37Z",{"type":63,"children":1263,"toc":1355},[1264,1268,1330],{"type":66,"tag":98,"props":1265,"children":1266},{"id":100},[1267],{"type":71,"value":103},{"type":66,"tag":112,"props":1269,"children":1270},{},[1271,1304],{"type":66,"tag":116,"props":1272,"children":1273},{},[1274,1278,1280,1287,1288,1295,1296,1303],{"type":66,"tag":120,"props":1275,"children":1276},{},[1277],{"type":71,"value":1213},{"type":71,"value":1279}," clientOptions merge",{"type":66,"tag":128,"props":1281,"children":1284},{"href":1282,"rel":1283},"https://github.com/nuxt-community/supabase-module/issues/275",[132],[1285],{"type":71,"value":1286},"#275",{"type":71,"value":501},{"type":66,"tag":128,"props":1289,"children":1292},{"href":1290,"rel":1291},"https://github.com/nuxt-community/supabase-module/issues/277",[132],[1293],{"type":71,"value":1294},"#277",{"type":71,"value":730},{"type":66,"tag":128,"props":1297,"children":1300},{"href":1298,"rel":1299},"https://github.com/nuxt-community/supabase-module/commit/c0097a355b859cb6a2d97884a7648284128acca2",[132],[1301],{"type":71,"value":1302},"c0097a3",{"type":71,"value":255},{"type":66,"tag":116,"props":1305,"children":1306},{},[1307,1312,1314,1321,1322,1329],{"type":66,"tag":120,"props":1308,"children":1309},{},[1310],{"type":71,"value":1311},"module:",{"type":71,"value":1313}," do not warn when using runtimeConfig to set url and key (",{"type":66,"tag":128,"props":1315,"children":1318},{"href":1316,"rel":1317},"https://github.com/nuxt-community/supabase-module/issues/281",[132],[1319],{"type":71,"value":1320},"#281",{"type":71,"value":730},{"type":66,"tag":128,"props":1323,"children":1326},{"href":1324,"rel":1325},"https://github.com/nuxt-community/supabase-module/commit/8c151737b55738c68fc24b5e4db2517c4e866693",[132],[1327],{"type":71,"value":1328},"8c15173",{"type":71,"value":255},{"type":66,"tag":67,"props":1331,"children":1332},{},[1333,1334,1344,1345],{"type":71,"value":1236},{"type":66,"tag":128,"props":1335,"children":1338},{"href":1336,"rel":1337},"https://github.com/stafyniaksacha",[132],[1339],{"type":66,"tag":120,"props":1340,"children":1341},{},[1342],{"type":71,"value":1343},"@stafyniaksacha",{"type":71,"value":1133},{"type":66,"tag":128,"props":1346,"children":1349},{"href":1347,"rel":1348},"https://github.com/jonesisg1",[132],[1350],{"type":66,"tag":120,"props":1351,"children":1352},{},[1353],{"type":71,"value":1354},"@jonesisg1",{"title":59,"searchDepth":78,"depth":78,"links":1356},[1357],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v1.1.3","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.1.3","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.1.3",{"url":1362,"total_count":585,"+1":78,"-1":294,"laugh":294,"hooray":78,"confused":294,"heart":294,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/123992311/reactions",{"name":166,"url":167,"avatar":168},"github:v1.1.3.md",{"name":1366,"tag_name":1366,"date":1367,"body":1368,"v":161,"url":1598,"tarball":1599,"zipball":1600,"prerelease":60,"reactions":1601,"author":1603,"title":59,"description":59,"_type":80,"_id":1604},"v1.1.2","2023-09-06T17:44:35Z",{"type":63,"children":1369,"toc":1593},[1370,1374,1396,1439,1443,1521,1537],{"type":66,"tag":98,"props":1371,"children":1372},{"id":100},[1373],{"type":71,"value":103},{"type":66,"tag":67,"props":1375,"children":1376},{},[1377,1379,1386,1388,1394],{"type":71,"value":1378},"⚠️ BREAKING CHANGE ⚠️\r\nBreaking change is related to ",{"type":66,"tag":128,"props":1380,"children":1383},{"href":1381,"rel":1382},"https://github.com/nuxt-modules/supabase/issues/244",[132],[1384],{"type":71,"value":1385},"#244",{"type":71,"value":1387}," and was first adressed in the ",{"type":66,"tag":312,"props":1389,"children":1391},{"className":1390},[],[1392],{"type":71,"value":1393},"v1.1.0",{"type":71,"value":1395}," but patch has been necessary to fix the version.",{"type":66,"tag":67,"props":1397,"children":1398},{},[1399,1401,1407,1409,1415,1417,1423,1425,1431,1433],{"type":71,"value":1400},"On the confirm page, configured in ",{"type":66,"tag":312,"props":1402,"children":1404},{"className":1403},[],[1405],{"type":71,"value":1406},"redirect.callback",{"type":71,"value":1408}," option (default to ",{"type":66,"tag":312,"props":1410,"children":1412},{"className":1411},[],[1413],{"type":71,"value":1414},"/confirm",{"type":71,"value":1416},"), ensure to set the ",{"type":66,"tag":312,"props":1418,"children":1420},{"className":1419},[],[1421],{"type":71,"value":1422},"immediate",{"type":71,"value":1424}," option in the watch.\r\nCheck out the doc: ",{"type":66,"tag":128,"props":1426,"children":1429},{"href":1427,"rel":1428},"http://supabase.nuxtjs.org/authentication#confirm-page-confirm",[132],[1430],{"type":71,"value":1427},{"type":71,"value":1432},"\r\nCheck out the demo code: ",{"type":66,"tag":128,"props":1434,"children":1437},{"href":1435,"rel":1436},"https://github.com/nuxt-modules/supabase/blob/main/demo/pages/confirm.vue",[132],[1438],{"type":71,"value":1435},{"type":66,"tag":105,"props":1440,"children":1441},{"id":107},[1442],{"type":71,"value":110},{"type":66,"tag":112,"props":1444,"children":1445},{},[1446,1471,1495],{"type":66,"tag":116,"props":1447,"children":1448},{},[1449,1453,1455,1462,1463,1470],{"type":66,"tag":120,"props":1450,"children":1451},{},[1452],{"type":71,"value":1311},{"type":71,"value":1454}," priority of redirect options made by defu (",{"type":66,"tag":128,"props":1456,"children":1459},{"href":1457,"rel":1458},"https://github.com/nuxt-community/supabase-module/issues/256",[132],[1460],{"type":71,"value":1461},"#256",{"type":71,"value":730},{"type":66,"tag":128,"props":1464,"children":1467},{"href":1465,"rel":1466},"https://github.com/nuxt-community/supabase-module/commit/c4e30bf50eb7816fee3a2e46b404df5ce9f7cf4d",[132],[1468],{"type":71,"value":1469},"c4e30bf",{"type":71,"value":255},{"type":66,"tag":116,"props":1472,"children":1473},{},[1474,1479,1481,1486,1487,1494],{"type":66,"tag":120,"props":1475,"children":1476},{},[1477],{"type":71,"value":1478},"plugin:",{"type":71,"value":1480}," retrieve user for client only page (",{"type":66,"tag":128,"props":1482,"children":1484},{"href":1381,"rel":1483},[132],[1485],{"type":71,"value":1385},{"type":71,"value":730},{"type":66,"tag":128,"props":1488,"children":1491},{"href":1489,"rel":1490},"https://github.com/nuxt-community/supabase-module/commit/4a35428e26542bf22b3288db6e9a9309f1310705",[132],[1492],{"type":71,"value":1493},"4a35428",{"type":71,"value":255},{"type":66,"tag":116,"props":1496,"children":1497},{},[1498,1503,1505,1512,1513,1520],{"type":66,"tag":120,"props":1499,"children":1500},{},[1501],{"type":71,"value":1502},"useSupabaseUser:",{"type":71,"value":1504}," add explicit user type (",{"type":66,"tag":128,"props":1506,"children":1509},{"href":1507,"rel":1508},"https://github.com/nuxt-community/supabase-module/issues/254",[132],[1510],{"type":71,"value":1511},"#254",{"type":71,"value":730},{"type":66,"tag":128,"props":1514,"children":1517},{"href":1515,"rel":1516},"https://github.com/nuxt-community/supabase-module/commit/60d8551ee83a9c64a962b9f76b881b17d7384736",[132],[1518],{"type":71,"value":1519},"60d8551",{"type":71,"value":255},{"type":66,"tag":67,"props":1522,"children":1523},{},[1524,1529,1531],{"type":66,"tag":120,"props":1525,"children":1526},{},[1527],{"type":71,"value":1528},"Full Changelog",{"type":71,"value":1530},": ",{"type":66,"tag":128,"props":1532,"children":1535},{"href":1533,"rel":1534},"https://github.com/nuxt-community/supabase-module/compare/v1.0.2...v1.1.0",[132],[1536],{"type":71,"value":1533},{"type":66,"tag":67,"props":1538,"children":1539},{},[1540,1541,1551,1552,1562,1563,1571,1572,1582,1583],{"type":71,"value":1236},{"type":66,"tag":128,"props":1542,"children":1545},{"href":1543,"rel":1544},"https://github.com/52cs",[132],[1546],{"type":66,"tag":120,"props":1547,"children":1548},{},[1549],{"type":71,"value":1550},"@52cs",{"type":71,"value":1133},{"type":66,"tag":128,"props":1553,"children":1556},{"href":1554,"rel":1555},"https://github.com/Aietes",[132],[1557],{"type":66,"tag":120,"props":1558,"children":1559},{},[1560],{"type":71,"value":1561},"@Aietes",{"type":71,"value":1133},{"type":66,"tag":128,"props":1564,"children":1566},{"href":1239,"rel":1565},[132],[1567],{"type":66,"tag":120,"props":1568,"children":1569},{},[1570],{"type":71,"value":1246},{"type":71,"value":1133},{"type":66,"tag":128,"props":1573,"children":1576},{"href":1574,"rel":1575},"https://github.com/kiri10ten",[132],[1577],{"type":66,"tag":120,"props":1578,"children":1579},{},[1580],{"type":71,"value":1581},"@kiri10ten",{"type":71,"value":1133},{"type":66,"tag":128,"props":1584,"children":1587},{"href":1585,"rel":1586},"https://github.com/xMorthi",[132],[1588],{"type":66,"tag":120,"props":1589,"children":1590},{},[1591],{"type":71,"value":1592},"@xMorthi",{"title":59,"searchDepth":78,"depth":78,"links":1594},[1595],{"id":100,"depth":78,"text":103,"children":1596},[1597],{"id":107,"depth":160,"text":110},"https://github.com/nuxt-modules/supabase/releases/tag/v1.1.2","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.1.2","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.1.2",{"url":1602,"total_count":585,"+1":294,"-1":294,"laugh":294,"hooray":160,"confused":294,"heart":294,"rocket":294,"eyes":161},"https://api.github.com/repos/nuxt-modules/supabase/releases/120162649/reactions",{"name":166,"url":167,"avatar":168},"github:v1.1.2.md",{"name":1606,"tag_name":1606,"date":1607,"body":1608,"v":161,"url":1691,"tarball":1692,"zipball":1693,"prerelease":60,"reactions":1694,"author":1696,"title":59,"description":59,"_type":80,"_id":1697},"v1.0.2","2023-08-04T15:56:13Z",{"type":63,"children":1609,"toc":1688},[1610,1614,1651,1665],{"type":66,"tag":98,"props":1611,"children":1612},{"id":100},[1613],{"type":71,"value":103},{"type":66,"tag":112,"props":1615,"children":1616},{},[1617,1634],{"type":66,"tag":116,"props":1618,"children":1619},{},[1620,1622,1633],{"type":71,"value":1621},"docs(auth): update (",{"type":66,"tag":128,"props":1623,"children":1626},{"href":1624,"rel":1625},"https://github.com/nuxt-modules/supabase/commit/df00ffe8ecc253fc23572b65465ad7928e185b13",[132],[1627],{"type":66,"tag":312,"props":1628,"children":1630},{"className":1629},[],[1631],{"type":71,"value":1632},"df00ffe",{"type":71,"value":255},{"type":66,"tag":116,"props":1635,"children":1636},{},[1637,1639,1650],{"type":71,"value":1638},"fix(client): correct provider_token assignment to cookie (",{"type":66,"tag":128,"props":1640,"children":1643},{"href":1641,"rel":1642},"https://github.com/nuxt-modules/supabase/commit/a76df3f67d6b08daf359f38130ce08aeab57317b",[132],[1644],{"type":66,"tag":312,"props":1645,"children":1647},{"className":1646},[],[1648],{"type":71,"value":1649},"a76df3f",{"type":71,"value":255},{"type":66,"tag":67,"props":1652,"children":1653},{},[1654,1658,1659],{"type":66,"tag":120,"props":1655,"children":1656},{},[1657],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":1660,"children":1663},{"href":1661,"rel":1662},"https://github.com/nuxt-community/supabase-module/compare/v1.0.1...v1.0.2",[132],[1664],{"type":71,"value":1661},{"type":66,"tag":67,"props":1666,"children":1667},{},[1668,1669,1679,1680],{"type":71,"value":1236},{"type":66,"tag":128,"props":1670,"children":1673},{"href":1671,"rel":1672},"https://github.com/blqke",[132],[1674],{"type":66,"tag":120,"props":1675,"children":1676},{},[1677],{"type":71,"value":1678},"@blqke",{"type":71,"value":1133},{"type":66,"tag":128,"props":1681,"children":1683},{"href":1554,"rel":1682},[132],[1684],{"type":66,"tag":120,"props":1685,"children":1686},{},[1687],{"type":71,"value":1561},{"title":59,"searchDepth":78,"depth":78,"links":1689},[1690],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v1.0.2","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.0.2","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.0.2",{"url":1695,"total_count":160,"+1":294,"-1":294,"laugh":294,"hooray":160,"confused":294,"heart":294,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/115135546/reactions",{"name":166,"url":167,"avatar":168},"github:v1.0.2.md",{"name":1699,"tag_name":1699,"date":1700,"body":1701,"v":161,"url":1990,"tarball":1991,"zipball":1992,"prerelease":60,"reactions":1993,"author":1999,"title":59,"description":2000,"_type":80,"_id":2001},"v1.0.1","2023-08-02T15:46:15Z",{"type":63,"children":1702,"toc":1987},[1703,1716,1721,1789,1794,1815,1819,1824,1953,1969,1972],{"type":66,"tag":67,"props":1704,"children":1705},{},[1706,1708,1714],{"type":71,"value":1707},"I am happy to announce the release of version ",{"type":66,"tag":312,"props":1709,"children":1711},{"className":1710},[],[1712],{"type":71,"value":1713},"1.0.0",{"type":71,"value":1715}," of this module. While the module has been production-ready for quite some time, I never had the opportunity to create the first major version until now. Given that this version incorporates significant changes, I believe it is the perfect moment to establish this initial major release.",{"type":66,"tag":98,"props":1717,"children":1718},{"id":100},[1719],{"type":71,"value":1720},"What's changed",{"type":66,"tag":112,"props":1722,"children":1723},{},[1724,1746,1751],{"type":66,"tag":116,"props":1725,"children":1726},{},[1727,1729,1736,1738,1745],{"type":71,"value":1728},"Supabase introduced a new authentication flow (PKCE) a few months ago, which is now the default behavior of the module. However, you can still revert to the old (and less secure) authentication method through the module configuration. To help you seamlessly integrate this new flow, a ",{"type":66,"tag":128,"props":1730,"children":1733},{"href":1731,"rel":1732},"https://supabase.nuxtjs.org/authentication",[132],[1734],{"type":71,"value":1735},"dedicated section",{"type":71,"value":1737}," has been added to the documentation. (",{"type":66,"tag":128,"props":1739,"children":1742},{"href":1740,"rel":1741},"https://github.com/nuxt-modules/supabase/issues/219",[132],[1743],{"type":71,"value":1744},"#219",{"type":71,"value":255},{"type":66,"tag":116,"props":1747,"children":1748},{},[1749],{"type":71,"value":1750},"Building upon the previous point, we have implemented substantial changes to the session management, involving alterations to how Supabase clients are instantiated and how sessions are synchronized between the server and client-side. Consequently, these changes result in some breaking changes, which are listed below.",{"type":66,"tag":116,"props":1752,"children":1753},{},[1754,1756,1763,1765,1772,1774,1781,1783],{"type":71,"value":1755},"A brand new documentation has been built entirely using ",{"type":66,"tag":128,"props":1757,"children":1760},{"href":1758,"rel":1759},"https://nuxt.studio",[132],[1761],{"type":71,"value":1762},"Nuxt Studio",{"type":71,"value":1764},". Feel free to create PRs to suggest fixes or add any necessary changes to further enhance the documentation. (",{"type":66,"tag":128,"props":1766,"children":1769},{"href":1767,"rel":1768},"https://github.com/nuxt-modules/supabase/issues/210",[132],[1770],{"type":71,"value":1771},"#210",{"type":71,"value":1773}," / ",{"type":66,"tag":128,"props":1775,"children":1778},{"href":1776,"rel":1777},"https://github.com/nuxt-modules/supabase/issues/221",[132],[1779],{"type":71,"value":1780},"#221",{"type":71,"value":1782},") => ",{"type":66,"tag":128,"props":1784,"children":1787},{"href":1785,"rel":1786},"https://supabase.nuxtjs.org",[132],[1788],{"type":71,"value":1785},{"type":66,"tag":67,"props":1790,"children":1791},{},[1792],{"type":71,"value":1793},"Here's documentation that can help you understand the PKCE authentication flow:",{"type":66,"tag":112,"props":1795,"children":1796},{},[1797,1806],{"type":66,"tag":116,"props":1798,"children":1799},{},[1800],{"type":66,"tag":128,"props":1801,"children":1804},{"href":1802,"rel":1803},"https://supabase.com/blog/supabase-auth-sso-pkce#server-side-and-mobile-auth",[132],[1805],{"type":71,"value":1802},{"type":66,"tag":116,"props":1807,"children":1808},{},[1809],{"type":66,"tag":128,"props":1810,"children":1813},{"href":1811,"rel":1812},"https://supabase.com/docs/guides/resources/glossary#pkce",[132],[1814],{"type":71,"value":1811},{"type":66,"tag":1816,"props":1817,"children":1818},"br",{},[],{"type":66,"tag":67,"props":1820,"children":1821},{},[1822],{"type":71,"value":1823},"⚠️ BREAKING CHANGES ⚠️",{"type":66,"tag":112,"props":1825,"children":1826},{},[1827,1845,1871,1890,1918],{"type":66,"tag":116,"props":1828,"children":1829},{},[1830,1836,1838,1843],{"type":66,"tag":312,"props":1831,"children":1833},{"className":1832},[],[1834],{"type":71,"value":1835},"useSupabaseAuthClient",{"type":71,"value":1837}," has been removed in favor of ",{"type":66,"tag":312,"props":1839,"children":1841},{"className":1840},[],[1842],{"type":71,"value":21},{"type":71,"value":1844}," in all cases",{"type":66,"tag":116,"props":1846,"children":1847},{},[1848,1853,1855,1861,1863,1869],{"type":66,"tag":312,"props":1849,"children":1851},{"className":1850},[],[1852],{"type":71,"value":34},{"type":71,"value":1854}," is now returning a promise (should be called with ",{"type":66,"tag":312,"props":1856,"children":1858},{"className":1857},[],[1859],{"type":71,"value":1860},"await",{"type":71,"value":1862}," in an ",{"type":66,"tag":312,"props":1864,"children":1866},{"className":1865},[],[1867],{"type":71,"value":1868},"async",{"type":71,"value":1870}," method)",{"type":66,"tag":116,"props":1872,"children":1873},{},[1874,1880,1882,1888],{"type":66,"tag":312,"props":1875,"children":1877},{"className":1876},[],[1878],{"type":71,"value":1879},"redirect",{"type":71,"value":1881}," option is enable by default, follow this ",{"type":66,"tag":128,"props":1883,"children":1885},{"href":1731,"rel":1884},[132],[1886],{"type":71,"value":1887},"guide",{"type":71,"value":1889}," to update your app",{"type":66,"tag":116,"props":1891,"children":1892},{},[1893,1899,1901,1907,1909,1916],{"type":66,"tag":312,"props":1894,"children":1896},{"className":1895},[],[1897],{"type":71,"value":1898},"client",{"type":71,"value":1900}," option becomes ",{"type":66,"tag":312,"props":1902,"children":1904},{"className":1903},[],[1905],{"type":71,"value":1906},"clientOptions",{"type":71,"value":1908}," with new ",{"type":66,"tag":128,"props":1910,"children":1913},{"href":1911,"rel":1912},"https://supabase.nuxtjs.org/get-started#clientoptions",[132],[1914],{"type":71,"value":1915},"default value",{"type":71,"value":1917}," (including the PKCE flow)",{"type":66,"tag":116,"props":1919,"children":1920},{},[1921,1927,1929,1935,1936,1942,1944,1951],{"type":66,"tag":312,"props":1922,"children":1924},{"className":1923},[],[1925],{"type":71,"value":1926},"cookies",{"type":71,"value":1928}," options is split in ",{"type":66,"tag":312,"props":1930,"children":1932},{"className":1931},[],[1933],{"type":71,"value":1934},"cookieName",{"type":71,"value":713},{"type":66,"tag":312,"props":1937,"children":1939},{"className":1938},[],[1940],{"type":71,"value":1941},"cookieOptions",{"type":71,"value":1943},", ",{"type":66,"tag":128,"props":1945,"children":1948},{"href":1946,"rel":1947},"https://supabase.nuxtjs.org/get-started#cookieoptions",[132],[1949],{"type":71,"value":1950},"default values",{"type":71,"value":1952}," have not changed",{"type":66,"tag":67,"props":1954,"children":1955},{},[1956,1958],{"type":71,"value":1957},"Here si the commit done for updating the demo with the last version: ",{"type":66,"tag":128,"props":1959,"children":1962},{"href":1960,"rel":1961},"https://github.com/nuxt-modules/supabase/commit/10e05860862b68c49817f6420d50d082452f7a7f",[132],[1963],{"type":66,"tag":312,"props":1964,"children":1966},{"className":1965},[],[1967],{"type":71,"value":1968},"10e0586",{"type":66,"tag":1816,"props":1970,"children":1971},{},[],{"type":66,"tag":67,"props":1973,"children":1974},{},[1975,1977,1985],{"type":71,"value":1976},"A huge thanks to ",{"type":66,"tag":128,"props":1978,"children":1980},{"href":1554,"rel":1979},[132],[1981],{"type":66,"tag":120,"props":1982,"children":1983},{},[1984],{"type":71,"value":1561},{"type":71,"value":1986}," for initialising all those changes and help me built it 💚",{"title":59,"searchDepth":78,"depth":78,"links":1988},[1989],{"id":100,"depth":78,"text":1720},"https://github.com/nuxt-modules/supabase/releases/tag/v1.0.1","https://api.github.com/repos/nuxt-modules/supabase/tarball/v1.0.1","https://api.github.com/repos/nuxt-modules/supabase/zipball/v1.0.1",{"url":1994,"total_count":1995,"+1":1996,"-1":294,"laugh":294,"hooray":1997,"confused":294,"heart":585,"rocket":1998,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/114843996/reactions",40,9,19,8,{"name":166,"url":167,"avatar":168},"I am happy to announce the release of version 1.0.0 of this module. While the module has been production-ready for quite some time, I never had the opportunity to create the first major version until now. Given that this version incorporates significant changes, I believe it is the perfect moment to establish this initial major release.","github:v1.0.1.md",{"name":2003,"tag_name":2003,"date":2004,"body":2005,"v":294,"url":2097,"tarball":2098,"zipball":2099,"prerelease":60,"reactions":2100,"author":2102,"title":59,"description":59,"_type":80,"_id":2103},"v0.3.8","2023-07-03T08:29:53Z",{"type":63,"children":2006,"toc":2094},[2007,2011,2068,2082],{"type":66,"tag":98,"props":2008,"children":2009},{"id":100},[2010],{"type":71,"value":103},{"type":66,"tag":112,"props":2012,"children":2013},{},[2014,2051],{"type":66,"tag":116,"props":2015,"children":2016},{},[2017,2019,2030,2032,2039,2041],{"type":71,"value":2018},"feat(session): save provider access/refresh tokens in cookies (",{"type":66,"tag":128,"props":2020,"children":2023},{"href":2021,"rel":2022},"https://github.com/nuxt-modules/supabase/commit/ea8c21f3d625984832cb27a3ae7605b16caaf94b",[132],[2024],{"type":66,"tag":312,"props":2025,"children":2027},{"className":2026},[],[2028],{"type":71,"value":2029},"ea8c21f",{"type":71,"value":2031},") in ",{"type":66,"tag":128,"props":2033,"children":2036},{"href":2034,"rel":2035},"https://github.com/nuxt-modules/supabase/issues/197",[132],[2037],{"type":71,"value":2038},"#197",{"type":71,"value":2040}," by ",{"type":66,"tag":128,"props":2042,"children":2045},{"href":2043,"rel":2044},"https://github.com/mitjans",[132],[2046],{"type":66,"tag":120,"props":2047,"children":2048},{},[2049],{"type":71,"value":2050},"@mitjans",{"type":66,"tag":116,"props":2052,"children":2053},{},[2054,2056,2067],{"type":71,"value":2055},"chore(deps): upgrade to latest (",{"type":66,"tag":128,"props":2057,"children":2060},{"href":2058,"rel":2059},"https://github.com/nuxt-modules/supabase/commit/a52abc871b6ab756c2b477f7c6b3c0f51279693c",[132],[2061],{"type":66,"tag":312,"props":2062,"children":2064},{"className":2063},[],[2065],{"type":71,"value":2066},"a52abc8",{"type":71,"value":255},{"type":66,"tag":67,"props":2069,"children":2070},{},[2071,2075,2076],{"type":66,"tag":120,"props":2072,"children":2073},{},[2074],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":2077,"children":2080},{"href":2078,"rel":2079},"https://github.com/nuxt-community/supabase-module/compare/v0.3.7...v0.3.8",[132],[2081],{"type":71,"value":2078},{"type":66,"tag":67,"props":2083,"children":2084},{},[2085,2086],{"type":71,"value":1236},{"type":66,"tag":128,"props":2087,"children":2089},{"href":2043,"rel":2088},[132],[2090],{"type":66,"tag":120,"props":2091,"children":2092},{},[2093],{"type":71,"value":2050},{"title":59,"searchDepth":78,"depth":78,"links":2095},[2096],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.3.8","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.3.8","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.3.8",{"url":2101,"total_count":685,"+1":294,"-1":294,"laugh":294,"hooray":685,"confused":294,"heart":294,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/110829614/reactions",{"name":166,"url":167,"avatar":168},"github:v0.3.8.md",{"name":2105,"tag_name":2105,"date":2106,"body":2107,"v":294,"url":2176,"tarball":2177,"zipball":2178,"prerelease":60,"author":2179,"title":59,"description":59,"_type":80,"_id":2180},"v0.3.7","2023-06-12T07:51:13Z",{"type":63,"children":2108,"toc":2173},[2109,2113,2159],{"type":66,"tag":98,"props":2110,"children":2111},{"id":100},[2112],{"type":71,"value":103},{"type":66,"tag":112,"props":2114,"children":2115},{},[2116,2142],{"type":66,"tag":116,"props":2117,"children":2118},{},[2119,2121,2126,2127,2134,2135],{"type":71,"value":2120},"fix(client): fix persist session warning for ",{"type":66,"tag":312,"props":2122,"children":2124},{"className":2123},[],[2125],{"type":71,"value":37},{"type":71,"value":501},{"type":66,"tag":128,"props":2128,"children":2131},{"href":2129,"rel":2130},"https://github.com/nuxt-modules/supabase/issues/194",[132],[2132],{"type":71,"value":2133},"#194",{"type":71,"value":137},{"type":66,"tag":128,"props":2136,"children":2139},{"href":2137,"rel":2138},"https://github.com/nuxt-modules/supabase/issues/193",[132],[2140],{"type":71,"value":2141},"#193",{"type":66,"tag":116,"props":2143,"children":2144},{},[2145,2147,2158],{"type":71,"value":2146},"docs(get-started): remove defineNuxtConfig (",{"type":66,"tag":128,"props":2148,"children":2151},{"href":2149,"rel":2150},"https://github.com/nuxt-modules/supabase/commit/0151901",[132],[2152],{"type":66,"tag":312,"props":2153,"children":2155},{"className":2154},[],[2156],{"type":71,"value":2157},"0151901",{"type":71,"value":255},{"type":66,"tag":67,"props":2160,"children":2161},{},[2162,2163],{"type":71,"value":1236},{"type":66,"tag":128,"props":2164,"children":2167},{"href":2165,"rel":2166},"https://github.com/jawngee",[132],[2168],{"type":66,"tag":120,"props":2169,"children":2170},{},[2171],{"type":71,"value":2172},"@jawngee",{"title":59,"searchDepth":78,"depth":78,"links":2174},[2175],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.3.7","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.3.7","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.3.7",{"name":166,"url":167,"avatar":168},"github:v0.3.7.md",{"name":2182,"tag_name":2182,"date":2183,"body":2184,"v":294,"url":2240,"tarball":2241,"zipball":2242,"prerelease":60,"reactions":2243,"author":2245,"title":59,"description":59,"_type":80,"_id":2246},"v0.3.6","2023-06-02T14:33:38Z",{"type":63,"children":2185,"toc":2237},[2186,2190],{"type":66,"tag":98,"props":2187,"children":2188},{"id":100},[2189],{"type":71,"value":103},{"type":66,"tag":112,"props":2191,"children":2192},{},[2193,2198,2224],{"type":66,"tag":116,"props":2194,"children":2195},{},[2196],{"type":71,"value":2197},"chore(deps): upgrade to nuxt and supabase latest version",{"type":66,"tag":116,"props":2199,"children":2200},{},[2201,2203,2214,2216,2223],{"type":71,"value":2202},"fix(client): remove persist session warning on server side in ",{"type":66,"tag":128,"props":2204,"children":2207},{"href":2205,"rel":2206},"https://github.com/nuxt-modules/supabase/commit/227113f68fb8723f9687adfa12150f825940e0c9",[132],[2208],{"type":66,"tag":312,"props":2209,"children":2211},{"className":2210},[],[2212],{"type":71,"value":2213},"227113f",{"type":71,"value":2215}," (Resolves ",{"type":66,"tag":128,"props":2217,"children":2220},{"href":2218,"rel":2219},"https://github.com/nuxt-modules/supabase/issues/188",[132],[2221],{"type":71,"value":2222},"#188",{"type":71,"value":255},{"type":66,"tag":116,"props":2225,"children":2226},{},[2227,2229,2236],{"type":71,"value":2228},"fix(chore): resolve imports (Resolves ",{"type":66,"tag":128,"props":2230,"children":2233},{"href":2231,"rel":2232},"https://github.com/nuxt-modules/supabase/issues/190",[132],[2234],{"type":71,"value":2235},"#190",{"type":71,"value":255},{"title":59,"searchDepth":78,"depth":78,"links":2238},[2239],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.3.6","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.3.6","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.3.6",{"url":2244,"total_count":685,"+1":161,"-1":294,"laugh":294,"hooray":585,"confused":294,"heart":294,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/105847469/reactions",{"name":166,"url":167,"avatar":168},"github:v0.3.6.md",{"name":2248,"tag_name":2248,"date":2249,"body":2250,"v":294,"url":2539,"tarball":2540,"zipball":2541,"prerelease":60,"reactions":2542,"author":2544,"title":59,"description":59,"_type":80,"_id":2545},"v0.3.5","2023-04-03T09:50:57Z",{"type":63,"children":2251,"toc":2536},[2252,2256,2485,2499],{"type":66,"tag":98,"props":2253,"children":2254},{"id":100},[2255],{"type":71,"value":103},{"type":66,"tag":112,"props":2257,"children":2258},{},[2259,2276,2293,2310,2327,2344,2361,2378,2395,2412,2444,2461],{"type":66,"tag":116,"props":2260,"children":2261},{},[2262,2264,2275],{"type":71,"value":2263},"chore(demo): upgrade on last version (",{"type":66,"tag":128,"props":2265,"children":2268},{"href":2266,"rel":2267},"https://github.com/nuxt-modules/supabase/commit/9bb9e2856823a0bb86c07ae7775462e02a1e430d",[132],[2269],{"type":66,"tag":312,"props":2270,"children":2272},{"className":2271},[],[2273],{"type":71,"value":2274},"9bb9e28",{"type":71,"value":255},{"type":66,"tag":116,"props":2277,"children":2278},{},[2279,2281,2292],{"type":71,"value":2280},"chore(demo): generate database types from supabase cli (",{"type":66,"tag":128,"props":2282,"children":2285},{"href":2283,"rel":2284},"https://github.com/nuxt-modules/supabase/commit/bca199292dfeb23d5e0581ab40a6994fed3d1157",[132],[2286],{"type":66,"tag":312,"props":2287,"children":2289},{"className":2288},[],[2290],{"type":71,"value":2291},"bca1992",{"type":71,"value":255},{"type":66,"tag":116,"props":2294,"children":2295},{},[2296,2298,2309],{"type":71,"value":2297},"docs(links): update nuxt & supabase links and fix typos (",{"type":66,"tag":128,"props":2299,"children":2302},{"href":2300,"rel":2301},"https://github.com/nuxt-modules/supabase/commit/5699dc6c22f9182e9593936fc1260fc785eea450",[132],[2303],{"type":66,"tag":312,"props":2304,"children":2306},{"className":2305},[],[2307],{"type":71,"value":2308},"5699dc6",{"type":71,"value":255},{"type":66,"tag":116,"props":2311,"children":2312},{},[2313,2315,2326],{"type":71,"value":2314},"chore(app): move to pnpm (",{"type":66,"tag":128,"props":2316,"children":2319},{"href":2317,"rel":2318},"https://github.com/nuxt-modules/supabase/commit/94f7e130747801584d2b0999bd2f5f904e575082",[132],[2320],{"type":66,"tag":312,"props":2321,"children":2323},{"className":2322},[],[2324],{"type":71,"value":2325},"94f7e13",{"type":71,"value":255},{"type":66,"tag":116,"props":2328,"children":2329},{},[2330,2332,2343],{"type":71,"value":2331},"chore(module): conditionally add redirect plugin (",{"type":66,"tag":128,"props":2333,"children":2336},{"href":2334,"rel":2335},"https://github.com/nuxt-modules/supabase/commit/0cad0a557934f669f2ab424ef072f6b07c098646",[132],[2337],{"type":66,"tag":312,"props":2338,"children":2340},{"className":2339},[],[2341],{"type":71,"value":2342},"0cad0a5",{"type":71,"value":255},{"type":66,"tag":116,"props":2345,"children":2346},{},[2347,2349,2360],{"type":71,"value":2348},"docs(get-started): fix typos (",{"type":66,"tag":128,"props":2350,"children":2353},{"href":2351,"rel":2352},"https://github.com/nuxt-modules/supabase/commit/ba437a8534f3dcda53f805cc34b5d6a943297354",[132],[2354],{"type":66,"tag":312,"props":2355,"children":2357},{"className":2356},[],[2358],{"type":71,"value":2359},"ba437a8",{"type":71,"value":255},{"type":66,"tag":116,"props":2362,"children":2363},{},[2364,2366,2377],{"type":71,"value":2365},"docs(composables): correct grammar errors (",{"type":66,"tag":128,"props":2367,"children":2370},{"href":2368,"rel":2369},"https://github.com/nuxt-modules/supabase/commit/034d7dfaf9f52a08da0ade4bf6d5ed31ec740734",[132],[2371],{"type":66,"tag":312,"props":2372,"children":2374},{"className":2373},[],[2375],{"type":71,"value":2376},"034d7df",{"type":71,"value":255},{"type":66,"tag":116,"props":2379,"children":2380},{},[2381,2383,2394],{"type":71,"value":2382},"feat(demo): add call from server route(",{"type":66,"tag":128,"props":2384,"children":2387},{"href":2385,"rel":2386},"https://github.com/nuxt-modules/supabase/commit/989a91eacdc471de90a2307c39cd03f23cca57ee",[132],[2388],{"type":66,"tag":312,"props":2389,"children":2391},{"className":2390},[],[2392],{"type":71,"value":2393},"989a91e",{"type":71,"value":255},{"type":66,"tag":116,"props":2396,"children":2397},{},[2398,2400,2411],{"type":71,"value":2399},"perf(useSupabaseAuthClient): avoid declaring unused variables (",{"type":66,"tag":128,"props":2401,"children":2404},{"href":2402,"rel":2403},"https://github.com/nuxt-modules/supabase/commit/8c070b9e571b3fe7870c08033ea561624a6ae575",[132],[2405],{"type":66,"tag":312,"props":2406,"children":2408},{"className":2407},[],[2409],{"type":71,"value":2410},"8c070b9",{"type":71,"value":255},{"type":66,"tag":116,"props":2413,"children":2414},{},[2415,2417,2428,2429,2436,2437],{"type":71,"value":2416},"fix(dev): optimize supabase deps (",{"type":66,"tag":128,"props":2418,"children":2421},{"href":2419,"rel":2420},"https://github.com/nuxt-modules/supabase/commit/d1da3f6b2f463e7196c69c3a580833438926a6e1",[132],[2422],{"type":66,"tag":312,"props":2423,"children":2425},{"className":2424},[],[2426],{"type":71,"value":2427},"d1da3f6",{"type":71,"value":137},{"type":66,"tag":128,"props":2430,"children":2433},{"href":2431,"rel":2432},"https://github.com/nuxt-modules/supabase/issues/172",[132],[2434],{"type":71,"value":2435},"#172",{"type":71,"value":739},{"type":66,"tag":128,"props":2438,"children":2441},{"href":2439,"rel":2440},"https://github.com/nuxt-modules/supabase/issues/151",[132],[2442],{"type":71,"value":2443},"#151",{"type":66,"tag":116,"props":2445,"children":2446},{},[2447,2449,2460],{"type":71,"value":2448},"chore(deps): transpile websocket lib prod only (",{"type":66,"tag":128,"props":2450,"children":2453},{"href":2451,"rel":2452},"https://github.com/nuxt-modules/supabase/commit/a1ee40c848c9da81aa41acc53dc3555b32bafd86",[132],[2454],{"type":66,"tag":312,"props":2455,"children":2457},{"className":2456},[],[2458],{"type":71,"value":2459},"a1ee40c",{"type":71,"value":255},{"type":66,"tag":116,"props":2462,"children":2463},{},[2464,2466,2477,2478,2483],{"type":71,"value":2465},"fix(deps): transpile gotrue only on client (",{"type":66,"tag":128,"props":2467,"children":2470},{"href":2468,"rel":2469},"https://github.com/nuxt-modules/supabase/commit/fcc6823e248395a513706cf67ab664f84daacb45",[132],[2471],{"type":66,"tag":312,"props":2472,"children":2474},{"className":2473},[],[2475],{"type":71,"value":2476},"fcc6823",{"type":71,"value":137},{"type":66,"tag":128,"props":2479,"children":2481},{"href":2431,"rel":2480},[132],[2482],{"type":71,"value":2435},{"type":71,"value":2484}," on server side",{"type":66,"tag":67,"props":2486,"children":2487},{},[2488,2492,2493],{"type":66,"tag":120,"props":2489,"children":2490},{},[2491],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":2494,"children":2497},{"href":2495,"rel":2496},"https://github.com/nuxt-community/supabase-module/compare/v0.3.1...v0.3.5",[132],[2498],{"type":71,"value":2495},{"type":66,"tag":67,"props":2500,"children":2501},{},[2502,2504,2511,2513,2520,2521,2528,2529],{"type":71,"value":2503},"💚 Thanks for the help from 💚\r\n@",{"type":66,"tag":128,"props":2505,"children":2508},{"href":2506,"rel":2507},"https://github.com/nuxt-modules/supabase/commits?author=kuizuo",[132],[2509],{"type":71,"value":2510},"kuizuo",{"type":71,"value":2512},"\r\n@",{"type":66,"tag":128,"props":2514,"children":2517},{"href":2515,"rel":2516},"https://github.com/nuxt-modules/supabase/commits?author=tnntwister",[132],[2518],{"type":71,"value":2519},"tnntwister",{"type":71,"value":2512},{"type":66,"tag":128,"props":2522,"children":2525},{"href":2523,"rel":2524},"https://github.com/nuxt-modules/supabase/commits?author=yannaufray",[132],[2526],{"type":71,"value":2527},"yannaufray",{"type":71,"value":2512},{"type":66,"tag":128,"props":2530,"children":2533},{"href":2531,"rel":2532},"https://github.com/nuxt-modules/supabase/commits?author=DamianGlowala",[132],[2534],{"type":71,"value":2535},"DamianGlowala",{"title":59,"searchDepth":78,"depth":78,"links":2537},[2538],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.3.5","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.3.5","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.3.5",{"url":2543,"total_count":161,"+1":294,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":294,"rocket":161,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/97822579/reactions",{"name":166,"url":167,"avatar":168},"github:v0.3.5.md",{"name":2547,"tag_name":2547,"date":2548,"body":2549,"v":294,"url":2812,"tarball":2813,"zipball":2814,"prerelease":2815,"reactions":2816,"author":2818,"title":59,"description":59,"_type":80,"_id":2819},"v0.3.3","2023-03-31T21:51:14Z",{"type":63,"children":2550,"toc":2809},[2551,2555,2795],{"type":66,"tag":98,"props":2552,"children":2553},{"id":100},[2554],{"type":71,"value":103},{"type":66,"tag":112,"props":2556,"children":2557},{},[2558,2581,2597,2614,2631,2654,2671,2696,2719,2742,2757,2780],{"type":66,"tag":116,"props":2559,"children":2560},{},[2561,2562,2569,2570,2580],{"type":71,"value":2399},{"type":66,"tag":128,"props":2563,"children":2566},{"href":2564,"rel":2565},"https://github.com/nuxt-modules/supabase/issues/166",[132],[2567],{"type":71,"value":2568},"#166",{"type":71,"value":730},{"type":66,"tag":128,"props":2571,"children":2574},{"href":2572,"rel":2573},"https://github.com/nuxt-modules/supabase/commit/8c070b9",[132],[2575],{"type":66,"tag":312,"props":2576,"children":2578},{"className":2577},[],[2579],{"type":71,"value":2410},{"type":71,"value":255},{"type":66,"tag":116,"props":2582,"children":2583},{},[2584,2586,2596],{"type":71,"value":2585},"feat(demo): add call from server route (",{"type":66,"tag":128,"props":2587,"children":2590},{"href":2588,"rel":2589},"https://github.com/nuxt-modules/supabase/commit/989a91e",[132],[2591],{"type":66,"tag":312,"props":2592,"children":2594},{"className":2593},[],[2595],{"type":71,"value":2393},{"type":71,"value":255},{"type":66,"tag":116,"props":2598,"children":2599},{},[2600,2602,2613],{"type":71,"value":2601},"chore(demo): upgrade deps (",{"type":66,"tag":128,"props":2603,"children":2606},{"href":2604,"rel":2605},"https://github.com/nuxt-modules/supabase/commit/9ebbc77",[132],[2607],{"type":66,"tag":312,"props":2608,"children":2610},{"className":2609},[],[2611],{"type":71,"value":2612},"9ebbc77",{"type":71,"value":255},{"type":66,"tag":116,"props":2615,"children":2616},{},[2617,2619,2630],{"type":71,"value":2618},"chore(deps): upgrade (",{"type":66,"tag":128,"props":2620,"children":2623},{"href":2621,"rel":2622},"https://github.com/nuxt-modules/supabase/commit/e274a5e",[132],[2624],{"type":66,"tag":312,"props":2625,"children":2627},{"className":2626},[],[2628],{"type":71,"value":2629},"e274a5e",{"type":71,"value":255},{"type":66,"tag":116,"props":2632,"children":2633},{},[2634,2635,2642,2643,2653],{"type":71,"value":2365},{"type":66,"tag":128,"props":2636,"children":2639},{"href":2637,"rel":2638},"https://github.com/nuxt-modules/supabase/issues/162",[132],[2640],{"type":71,"value":2641},"#162",{"type":71,"value":730},{"type":66,"tag":128,"props":2644,"children":2647},{"href":2645,"rel":2646},"https://github.com/nuxt-modules/supabase/commit/034d7df",[132],[2648],{"type":66,"tag":312,"props":2649,"children":2651},{"className":2650},[],[2652],{"type":71,"value":2376},{"type":71,"value":255},{"type":66,"tag":116,"props":2655,"children":2656},{},[2657,2659,2670],{"type":71,"value":2658},"docs(readme): add nuxt badge (",{"type":66,"tag":128,"props":2660,"children":2663},{"href":2661,"rel":2662},"https://github.com/nuxt-modules/supabase/commit/68271b8",[132],[2664],{"type":66,"tag":312,"props":2665,"children":2667},{"className":2666},[],[2668],{"type":71,"value":2669},"68271b8",{"type":71,"value":255},{"type":66,"tag":116,"props":2672,"children":2673},{},[2674,2676,2683,2684,2695],{"type":71,"value":2675},"docs(demo): fix typo (",{"type":66,"tag":128,"props":2677,"children":2680},{"href":2678,"rel":2679},"https://github.com/nuxt-modules/supabase/issues/125",[132],[2681],{"type":71,"value":2682},"#125",{"type":71,"value":730},{"type":66,"tag":128,"props":2685,"children":2688},{"href":2686,"rel":2687},"https://github.com/nuxt-modules/supabase/commit/bd33d12",[132],[2689],{"type":66,"tag":312,"props":2690,"children":2692},{"className":2691},[],[2693],{"type":71,"value":2694},"bd33d12",{"type":71,"value":255},{"type":66,"tag":116,"props":2697,"children":2698},{},[2699,2700,2707,2708,2718],{"type":71,"value":2348},{"type":66,"tag":128,"props":2701,"children":2704},{"href":2702,"rel":2703},"https://github.com/nuxt-modules/supabase/issues/154",[132],[2705],{"type":71,"value":2706},"#154",{"type":71,"value":730},{"type":66,"tag":128,"props":2709,"children":2712},{"href":2710,"rel":2711},"https://github.com/nuxt-modules/supabase/commit/ba437a8",[132],[2713],{"type":66,"tag":312,"props":2714,"children":2716},{"className":2715},[],[2717],{"type":71,"value":2359},{"type":71,"value":255},{"type":66,"tag":116,"props":2720,"children":2721},{},[2722,2723,2730,2731,2741],{"type":71,"value":2331},{"type":66,"tag":128,"props":2724,"children":2727},{"href":2725,"rel":2726},"https://github.com/nuxt-modules/supabase/issues/157",[132],[2728],{"type":71,"value":2729},"#157",{"type":71,"value":730},{"type":66,"tag":128,"props":2732,"children":2735},{"href":2733,"rel":2734},"https://github.com/nuxt-modules/supabase/commit/0cad0a5",[132],[2736],{"type":66,"tag":312,"props":2737,"children":2739},{"className":2738},[],[2740],{"type":71,"value":2342},{"type":71,"value":255},{"type":66,"tag":116,"props":2743,"children":2744},{},[2745,2746,2756],{"type":71,"value":2314},{"type":66,"tag":128,"props":2747,"children":2750},{"href":2748,"rel":2749},"https://github.com/nuxt-modules/supabase/commit/94f7e13",[132],[2751],{"type":66,"tag":312,"props":2752,"children":2754},{"className":2753},[],[2755],{"type":71,"value":2325},{"type":71,"value":255},{"type":66,"tag":116,"props":2758,"children":2759},{},[2760,2761,2768,2769,2779],{"type":71,"value":2297},{"type":66,"tag":128,"props":2762,"children":2765},{"href":2763,"rel":2764},"https://github.com/nuxt-modules/supabase/issues/126",[132],[2766],{"type":71,"value":2767},"#126",{"type":71,"value":730},{"type":66,"tag":128,"props":2770,"children":2773},{"href":2771,"rel":2772},"https://github.com/nuxt-modules/supabase/commit/5699dc6",[132],[2774],{"type":66,"tag":312,"props":2775,"children":2777},{"className":2776},[],[2778],{"type":71,"value":2308},{"type":71,"value":255},{"type":66,"tag":116,"props":2781,"children":2782},{},[2783,2784,2794],{"type":71,"value":2280},{"type":66,"tag":128,"props":2785,"children":2788},{"href":2786,"rel":2787},"https://github.com/nuxt-modules/supabase/commit/bca1992",[132],[2789],{"type":66,"tag":312,"props":2790,"children":2792},{"className":2791},[],[2793],{"type":71,"value":2291},{"type":71,"value":255},{"type":66,"tag":67,"props":2796,"children":2797},{},[2798,2802,2803],{"type":66,"tag":120,"props":2799,"children":2800},{},[2801],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":2804,"children":2807},{"href":2805,"rel":2806},"https://github.com/nuxt-community/supabase-module/compare/v0.3.1...v0.3.3",[132],[2808],{"type":71,"value":2805},{"title":59,"searchDepth":78,"depth":78,"links":2810},[2811],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.3.3","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.3.3","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.3.3",true,{"url":2817,"total_count":161,"+1":161,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":294,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/97697076/reactions",{"name":166,"url":167,"avatar":168},"github:v0.3.3.md",{"name":2821,"tag_name":2821,"date":2822,"body":2823,"v":294,"url":2888,"tarball":2889,"zipball":2890,"prerelease":60,"author":2891,"title":59,"description":59,"_type":80,"_id":2892},"v0.3.1","2023-02-07T20:18:04Z",{"type":63,"children":2824,"toc":2885},[2825,2829,2871],{"type":66,"tag":98,"props":2826,"children":2827},{"id":100},[2828],{"type":71,"value":103},{"type":66,"tag":112,"props":2830,"children":2831},{},[2832,2849,2866],{"type":66,"tag":116,"props":2833,"children":2834},{},[2835,2837,2848],{"type":71,"value":2836},"chore(app): upgrade deps and fix lint (",{"type":66,"tag":128,"props":2838,"children":2841},{"href":2839,"rel":2840},"https://github.com/nuxt-modules/supabase/commit/68baf68",[132],[2842],{"type":66,"tag":312,"props":2843,"children":2845},{"className":2844},[],[2846],{"type":71,"value":2847},"68baf68",{"type":71,"value":255},{"type":66,"tag":116,"props":2850,"children":2851},{},[2852,2854,2865],{"type":71,"value":2853},"fix(client): unset user before session on logout (",{"type":66,"tag":128,"props":2855,"children":2858},{"href":2856,"rel":2857},"https://github.com/nuxt-modules/supabase/commit/ab574ef",[132],[2859],{"type":66,"tag":312,"props":2860,"children":2862},{"className":2861},[],[2863],{"type":71,"value":2864},"ab574ef",{"type":71,"value":255},{"type":66,"tag":116,"props":2867,"children":2868},{},[2869],{"type":71,"value":2870},"chore(demo): update with latest and fix logout",{"type":66,"tag":67,"props":2872,"children":2873},{},[2874,2878,2879],{"type":66,"tag":120,"props":2875,"children":2876},{},[2877],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":2880,"children":2883},{"href":2881,"rel":2882},"https://github.com/nuxt-community/supabase-module/compare/v0.3.0...v0.3.1",[132],[2884],{"type":71,"value":2881},{"title":59,"searchDepth":78,"depth":78,"links":2886},[2887],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.3.1","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.3.1","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.3.1",{"name":166,"url":167,"avatar":168},"github:v0.3.1.md",{"name":2894,"tag_name":2894,"date":2895,"body":2896,"v":294,"url":3018,"tarball":3019,"zipball":3020,"prerelease":60,"reactions":3021,"author":3023,"title":59,"description":1823,"_type":80,"_id":3024},"v0.3.0","2022-11-22T15:26:02Z",{"type":63,"children":2897,"toc":3015},[2898,2902,2906,2927,2961,2989,3001],{"type":66,"tag":67,"props":2899,"children":2900},{},[2901],{"type":71,"value":1823},{"type":66,"tag":98,"props":2903,"children":2904},{"id":100},[2905],{"type":71,"value":103},{"type":66,"tag":67,"props":2907,"children":2908},{},[2909,2911,2918,2920,2925],{"type":71,"value":2910},"In order to resolve ",{"type":66,"tag":128,"props":2912,"children":2915},{"href":2913,"rel":2914},"https://github.com/nuxt-modules/supabase/issues/114",[132],[2916],{"type":71,"value":2917},"#114",{"type":71,"value":2919},", I have made the choice to separate the ",{"type":66,"tag":312,"props":2921,"children":2923},{"className":2922},[],[2924],{"type":71,"value":21},{"type":71,"value":2926}," in two other composables:",{"type":66,"tag":112,"props":2928,"children":2929},{},[2930,2950],{"type":66,"tag":116,"props":2931,"children":2932},{},[2933,2935,2940,2942,2948],{"type":71,"value":2934},"The ",{"type":66,"tag":312,"props":2936,"children":2938},{"className":2937},[],[2939],{"type":71,"value":1835},{"type":71,"value":2941}," is dedicated to authentification purpose only. It won't be recreate if your token expires, it is used in the client plugin to listen to ",{"type":66,"tag":312,"props":2943,"children":2945},{"className":2944},[],[2946],{"type":71,"value":2947},"onAuthStateChange",{"type":71,"value":2949}," events.",{"type":66,"tag":116,"props":2951,"children":2952},{},[2953,2954,2959],{"type":71,"value":2934},{"type":66,"tag":312,"props":2955,"children":2957},{"className":2956},[],[2958],{"type":71,"value":21},{"type":71,"value":2960}," is now only useful for data request.",{"type":66,"tag":67,"props":2962,"children":2963},{},[2964,2966,2971,2973,2978,2980,2987],{"type":71,"value":2965},"To avoid regression you just need to use ",{"type":66,"tag":312,"props":2967,"children":2969},{"className":2968},[],[2970],{"type":71,"value":1835},{"type":71,"value":2972}," instead of ",{"type":66,"tag":312,"props":2974,"children":2976},{"className":2975},[],[2977],{"type":71,"value":21},{"type":71,"value":2979}," everywhere you use ",{"type":66,"tag":128,"props":2981,"children":2984},{"href":2982,"rel":2983},"https://supabase.com/docs/reference/javascript/auth-signup",[132],[2985],{"type":71,"value":2986},"Supabase auth methods",{"type":71,"value":2988},".",{"type":66,"tag":67,"props":2990,"children":2991},{},[2992,2999],{"type":66,"tag":128,"props":2993,"children":2996},{"href":2994,"rel":2995},"https://supabase.nuxtjs.org/usage/composables/use-supabase-auth-client",[132],[2997],{"type":71,"value":2998},"Documentation",{"type":71,"value":3000}," has been updated.",{"type":66,"tag":67,"props":3002,"children":3003},{},[3004,3008,3009],{"type":66,"tag":120,"props":3005,"children":3006},{},[3007],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3010,"children":3013},{"href":3011,"rel":3012},"https://github.com/nuxt-community/supabase-module/compare/v0.2.6...v0.3.0",[132],[3014],{"type":71,"value":3011},{"title":59,"searchDepth":78,"depth":78,"links":3016},[3017],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.3.0","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.3.0","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.3.0",{"url":3022,"total_count":1998,"+1":78,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":160,"rocket":160,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/83886320/reactions",{"name":166,"url":167,"avatar":168},"github:v0.3.0.md",{"name":3026,"tag_name":3026,"date":3027,"body":3028,"v":294,"url":3065,"tarball":3066,"zipball":3067,"prerelease":60,"author":3068,"title":59,"description":59,"_type":80,"_id":3069},"v0.2.6","2022-11-22T15:16:16Z",{"type":63,"children":3029,"toc":3062},[3030,3034,3048],{"type":66,"tag":98,"props":3031,"children":3032},{"id":100},[3033],{"type":71,"value":103},{"type":66,"tag":112,"props":3035,"children":3036},{},[3037],{"type":66,"tag":116,"props":3038,"children":3039},{},[3040,3042],{"type":71,"value":3041},"chore: update to Nuxt 3 stable 🚀 ",{"type":66,"tag":128,"props":3043,"children":3046},{"href":3044,"rel":3045},"https://nuxt.com/v3",[132],[3047],{"type":71,"value":3044},{"type":66,"tag":67,"props":3049,"children":3050},{},[3051,3055,3056],{"type":66,"tag":120,"props":3052,"children":3053},{},[3054],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3057,"children":3060},{"href":3058,"rel":3059},"https://github.com/nuxt-community/supabase-module/compare/v0.2.5...v0.2.6",[132],[3061],{"type":71,"value":3058},{"title":59,"searchDepth":78,"depth":78,"links":3063},[3064],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.2.6","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.2.6","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.2.6",{"name":166,"url":167,"avatar":168},"github:v0.2.6.md",{"name":3071,"tag_name":3071,"date":3072,"body":3073,"v":294,"url":3125,"tarball":3126,"zipball":3127,"prerelease":60,"author":3128,"title":59,"description":59,"_type":80,"_id":3129},"v0.2.5","2022-11-22T15:14:51Z",{"type":63,"children":3074,"toc":3122},[3075,3079,3108],{"type":66,"tag":98,"props":3076,"children":3077},{"id":100},[3078],{"type":71,"value":103},{"type":66,"tag":112,"props":3080,"children":3081},{},[3082],{"type":66,"tag":116,"props":3083,"children":3084},{},[3085,3087,3098,3100,3107],{"type":71,"value":3086},"fix: use Router instead of navigateTo for login redirect in ",{"type":66,"tag":128,"props":3088,"children":3091},{"href":3089,"rel":3090},"https://github.com/nuxt-modules/supabase/commit/79fc0e43655d4dee5858acf06cf1979e3ead542b",[132],[3092],{"type":66,"tag":312,"props":3093,"children":3095},{"className":3094},[],[3096],{"type":71,"value":3097},"79fc0e4",{"type":71,"value":3099}," (resolves ",{"type":66,"tag":128,"props":3101,"children":3104},{"href":3102,"rel":3103},"https://github.com/nuxt-modules/supabase/issues/89",[132],[3105],{"type":71,"value":3106},"#89",{"type":71,"value":255},{"type":66,"tag":67,"props":3109,"children":3110},{},[3111,3115,3116],{"type":66,"tag":120,"props":3112,"children":3113},{},[3114],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3117,"children":3120},{"href":3118,"rel":3119},"https://github.com/nuxt-community/supabase-module/compare/v0.2.4...v0.2.5",[132],[3121],{"type":71,"value":3118},{"title":59,"searchDepth":78,"depth":78,"links":3123},[3124],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.2.5","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.2.5","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.2.5",{"name":166,"url":167,"avatar":168},"github:v0.2.5.md",{"name":3131,"tag_name":3131,"date":3132,"body":3133,"v":294,"url":3175,"tarball":3176,"zipball":3177,"prerelease":60,"reactions":3178,"author":3180,"title":59,"description":59,"_type":80,"_id":3181},"v0.2.4","2022-11-13T19:36:18Z",{"type":63,"children":3134,"toc":3172},[3135,3139,3158],{"type":66,"tag":98,"props":3136,"children":3137},{"id":100},[3138],{"type":71,"value":103},{"type":66,"tag":112,"props":3140,"children":3141},{},[3142],{"type":66,"tag":116,"props":3143,"children":3144},{},[3145,3147],{"type":71,"value":3146},"fix: handle TOKEN_REFRESHED session event in ",{"type":66,"tag":128,"props":3148,"children":3151},{"href":3149,"rel":3150},"https://github.com/nuxt-modules/supabase/commit/bf503029b48113b4b66545d0d2065c899209a06a",[132],[3152],{"type":66,"tag":312,"props":3153,"children":3155},{"className":3154},[],[3156],{"type":71,"value":3157},"bf50302",{"type":66,"tag":67,"props":3159,"children":3160},{},[3161,3165,3166],{"type":66,"tag":120,"props":3162,"children":3163},{},[3164],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3167,"children":3170},{"href":3168,"rel":3169},"https://github.com/nuxt-community/supabase-module/compare/v0.2.3...v0.2.4",[132],[3171],{"type":71,"value":3168},{"title":59,"searchDepth":78,"depth":78,"links":3173},[3174],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.2.4","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.2.4","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.2.4",{"url":3179,"total_count":78,"+1":294,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":78,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/82920199/reactions",{"name":166,"url":167,"avatar":168},"github:v0.2.4.md",{"name":3183,"tag_name":3183,"date":3184,"body":3185,"v":294,"url":3322,"tarball":3323,"zipball":3324,"prerelease":60,"reactions":3325,"author":3327,"title":59,"description":59,"_type":80,"_id":3328},"v0.2.3","2022-11-11T17:27:14Z",{"type":63,"children":3186,"toc":3318},[3187,3191,3270,3276,3304],{"type":66,"tag":98,"props":3188,"children":3189},{"id":100},[3190],{"type":71,"value":103},{"type":66,"tag":112,"props":3192,"children":3193},{},[3194,3222,3234,3247],{"type":66,"tag":116,"props":3195,"children":3196},{},[3197,3199,3210,3211],{"type":71,"value":3198},"feat: typed supabase client in ",{"type":66,"tag":128,"props":3200,"children":3203},{"href":3201,"rel":3202},"https://github.com/nuxt-modules/supabase/commit/b59ff1acfbbe2cd36aea1ade2d2b538404909260",[132],[3204],{"type":66,"tag":312,"props":3205,"children":3207},{"className":3206},[],[3208],{"type":71,"value":3209},"b59ff1a",{"type":71,"value":713},{"type":66,"tag":128,"props":3212,"children":3215},{"href":3213,"rel":3214},"https://github.com/nuxt-modules/supabase/commit/fd751d7e50c63c48df9e03763458cc826409ff35",[132],[3216],{"type":66,"tag":312,"props":3217,"children":3219},{"className":3218},[],[3220],{"type":71,"value":3221},"fd751d7",{"type":66,"tag":116,"props":3223,"children":3224},{},[3225,3227],{"type":71,"value":3226},"chore: upgrade to nuxt ",{"type":66,"tag":128,"props":3228,"children":3231},{"href":3229,"rel":3230},"https://github.com/nuxt/framework/releases/tag/v3.0.0-rc.13",[132],[3232],{"type":71,"value":3233},"rc13",{"type":66,"tag":116,"props":3235,"children":3236},{},[3237,3239,3246],{"type":71,"value":3238},"fix: do not apply token if not exists (",{"type":66,"tag":128,"props":3240,"children":3243},{"href":3241,"rel":3242},"https://github.com/nuxt-modules/supabase/issues/107",[132],[3244],{"type":71,"value":3245},"#107",{"type":71,"value":255},{"type":66,"tag":116,"props":3248,"children":3249},{},[3250,3252,3258,3259],{"type":71,"value":3251},"docs: add roadmap board from ",{"type":66,"tag":128,"props":3253,"children":3256},{"href":3254,"rel":3255},"https://volta.net",[132],[3257],{"type":71,"value":3254},{"type":71,"value":619},{"type":66,"tag":128,"props":3260,"children":3263},{"href":3261,"rel":3262},"https://github.com/nuxt-modules/supabase/commit/f8e73b535924f133e479dbc2863bb37856ff4555",[132],[3264],{"type":66,"tag":312,"props":3265,"children":3267},{"className":3266},[],[3268],{"type":71,"value":3269},"f8e73b5",{"type":66,"tag":98,"props":3271,"children":3273},{"id":3272},"contributors",[3274],{"type":71,"value":3275},"Contributors",{"type":66,"tag":67,"props":3277,"children":3278},{},[3279,3281,3291,3292,3302],{"type":71,"value":3280},"Thanks to ",{"type":66,"tag":128,"props":3282,"children":3285},{"href":3283,"rel":3284},"https://github.com/manniL",[132],[3286],{"type":66,"tag":120,"props":3287,"children":3288},{},[3289],{"type":71,"value":3290},"@manniL",{"type":71,"value":713},{"type":66,"tag":128,"props":3293,"children":3296},{"href":3294,"rel":3295},"https://github.com/levibe",[132],[3297],{"type":66,"tag":120,"props":3298,"children":3299},{},[3300],{"type":71,"value":3301},"@levibe",{"type":71,"value":3303}," 💚",{"type":66,"tag":67,"props":3305,"children":3306},{},[3307,3311,3312],{"type":66,"tag":120,"props":3308,"children":3309},{},[3310],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3313,"children":3316},{"href":3314,"rel":3315},"https://github.com/nuxt-community/supabase-module/compare/v0.2.0...v0.2.3",[132],[3317],{"type":71,"value":3314},{"title":59,"searchDepth":78,"depth":78,"links":3319},[3320,3321],{"id":100,"depth":78,"text":103},{"id":3272,"depth":78,"text":3275},"https://github.com/nuxt-modules/supabase/releases/tag/v0.2.3","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.2.3","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.2.3",{"url":3326,"total_count":161,"+1":294,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":161,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/82825289/reactions",{"name":166,"url":167,"avatar":168},"github:v0.2.3.md",{"name":3330,"tag_name":3330,"date":3331,"body":3332,"v":294,"url":3423,"tarball":3424,"zipball":3425,"prerelease":60,"author":3426,"title":59,"description":59,"_type":80,"_id":3427},"v0.2.0","2022-10-17T14:18:31Z",{"type":63,"children":3333,"toc":3420},[3334,3338,3343,3356,3369,3374,3379,3406],{"type":66,"tag":98,"props":3335,"children":3336},{"id":100},[3337],{"type":71,"value":103},{"type":66,"tag":67,"props":3339,"children":3340},{},[3341],{"type":71,"value":3342},"⚠️ Breaking Changes",{"type":66,"tag":67,"props":3344,"children":3345},{},[3346,3348,3355],{"type":71,"value":3347},"Upgrade to supabase-js v2, check Supabase ",{"type":66,"tag":128,"props":3349,"children":3352},{"href":3350,"rel":3351},"https://supabase.com/docs/reference/javascript/release-notes",[132],[3353],{"type":71,"value":3354},"release notes",{"type":71,"value":2988},{"type":66,"tag":67,"props":3357,"children":3358},{},[3359,3361,3367],{"type":71,"value":3360},"Module ",{"type":66,"tag":128,"props":3362,"children":3364},{"href":1785,"rel":3363},[132],[3365],{"type":71,"value":3366},"documentation",{"type":71,"value":3368}," has been updated in favor of supabase v2 syntax.",{"type":66,"tag":67,"props":3370,"children":3371},{},[3372],{"type":71,"value":3373},"Please feel free to make PR if I missed something 🙏",{"type":66,"tag":67,"props":3375,"children":3376},{},[3377],{"type":71,"value":3378},"🚀 Features",{"type":66,"tag":112,"props":3380,"children":3381},{},[3382,3394],{"type":66,"tag":116,"props":3383,"children":3384},{},[3385,3387,3393],{"type":71,"value":3386},"options: redirect user after signout or when user is not authenticated (check ",{"type":66,"tag":128,"props":3388,"children":3391},{"href":3389,"rel":3390},"https://supabase.nuxtjs.org/get-started#redirect",[132],[3392],{"type":71,"value":3366},{"type":71,"value":255},{"type":66,"tag":116,"props":3395,"children":3396},{},[3397,3399],{"type":71,"value":3398},"session: set refresh token ",{"type":66,"tag":128,"props":3400,"children":3403},{"href":3401,"rel":3402},"https://github.com/nuxt-modules/supabase/issues/18",[132],[3404],{"type":71,"value":3405},"#18",{"type":66,"tag":67,"props":3407,"children":3408},{},[3409,3413,3414],{"type":66,"tag":120,"props":3410,"children":3411},{},[3412],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3415,"children":3418},{"href":3416,"rel":3417},"https://github.com/nuxt-community/supabase-module/compare/v0.1.28...v0.2.0",[132],[3419],{"type":71,"value":3416},{"title":59,"searchDepth":78,"depth":78,"links":3421},[3422],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.2.0","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.2.0","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.2.0",{"name":166,"url":167,"avatar":168},"github:v0.2.0.md",{"name":3429,"tag_name":3429,"date":3430,"body":3431,"v":294,"url":3486,"tarball":3487,"zipball":3488,"prerelease":60,"author":3489,"title":59,"description":59,"_type":80,"_id":3490},"v0.1.28","2022-10-07T10:05:52Z",{"type":63,"children":3432,"toc":3483},[3433,3437,3453,3467],{"type":66,"tag":98,"props":3434,"children":3435},{"id":100},[3436],{"type":71,"value":103},{"type":66,"tag":112,"props":3438,"children":3439},{},[3440],{"type":66,"tag":116,"props":3441,"children":3442},{},[3443,3445,3452],{"type":71,"value":3444},"fix: cloudflare workers deployment (",{"type":66,"tag":128,"props":3446,"children":3449},{"href":3447,"rel":3448},"https://github.com/nuxt-modules/supabase/issues/46",[132],[3450],{"type":71,"value":3451},"#46",{"type":71,"value":255},{"type":66,"tag":67,"props":3454,"children":3455},{},[3456,3460,3461],{"type":66,"tag":120,"props":3457,"children":3458},{},[3459],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3462,"children":3465},{"href":3463,"rel":3464},"https://github.com/nuxt-community/supabase-module/compare/v0.1.27...v0.1.28",[132],[3466],{"type":71,"value":3463},{"type":66,"tag":67,"props":3468,"children":3469},{},[3470,3471,3481],{"type":71,"value":3280},{"type":66,"tag":128,"props":3472,"children":3475},{"href":3473,"rel":3474},"https://github.com/kevinmarrec",[132],[3476],{"type":66,"tag":120,"props":3477,"children":3478},{},[3479],{"type":71,"value":3480},"@kevinmarrec",{"type":71,"value":3482}," for the fix 🔥",{"title":59,"searchDepth":78,"depth":78,"links":3484},[3485],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.28","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.28","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.28",{"name":166,"url":167,"avatar":168},"github:v0.1.28.md",{"name":3492,"tag_name":3492,"date":3493,"body":3494,"v":294,"url":3537,"tarball":3538,"zipball":3539,"prerelease":60,"author":3540,"title":59,"description":59,"_type":80,"_id":3541},"v0.1.27","2022-09-23T10:19:42Z",{"type":63,"children":3495,"toc":3534},[3496,3500,3515,3520],{"type":66,"tag":98,"props":3497,"children":3498},{"id":100},[3499],{"type":71,"value":103},{"type":66,"tag":112,"props":3501,"children":3502},{},[3503],{"type":66,"tag":116,"props":3504,"children":3505},{},[3506,3508],{"type":71,"value":3507},"chore: upgrade to Nuxt ",{"type":66,"tag":128,"props":3509,"children":3512},{"href":3510,"rel":3511},"https://github.com/nuxt/framework/releases/tag/v3.0.0-rc.11",[132],[3513],{"type":71,"value":3514},"rc.11",{"type":66,"tag":67,"props":3516,"children":3517},{},[3518],{"type":71,"value":3519},"Stable is coming 🚀",{"type":66,"tag":67,"props":3521,"children":3522},{},[3523,3527,3528],{"type":66,"tag":120,"props":3524,"children":3525},{},[3526],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3529,"children":3532},{"href":3530,"rel":3531},"https://github.com/nuxt-community/supabase-module/compare/v0.1.26...v0.1.27",[132],[3533],{"type":71,"value":3530},{"title":59,"searchDepth":78,"depth":78,"links":3535},[3536],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.27","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.27","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.27",{"name":166,"url":167,"avatar":168},"github:v0.1.27.md",{"name":3330,"tag_name":3543,"date":3544,"body":3545,"v":294,"url":3583,"tarball":3584,"zipball":3585,"prerelease":2815,"author":3586,"title":59,"description":59,"_type":80,"_id":3427},"v0.2.0-16","2022-08-16T14:56:45Z",{"type":63,"children":3546,"toc":3580},[3547,3551,3555,3566],{"type":66,"tag":98,"props":3548,"children":3549},{"id":100},[3550],{"type":71,"value":103},{"type":66,"tag":67,"props":3552,"children":3553},{},[3554],{"type":71,"value":3342},{"type":66,"tag":67,"props":3556,"children":3557},{},[3558,3559,3565],{"type":71,"value":3347},{"type":66,"tag":128,"props":3560,"children":3563},{"href":3561,"rel":3562},"https://supabase.com/docs/reference/javascript/next/release-notes",[132],[3564],{"type":71,"value":3354},{"type":71,"value":2988},{"type":66,"tag":67,"props":3567,"children":3568},{},[3569,3573,3574],{"type":66,"tag":120,"props":3570,"children":3571},{},[3572],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3575,"children":3578},{"href":3576,"rel":3577},"https://github.com/nuxt-community/supabase-module/compare/v0.1.22...v0.2.0",[132],[3579],{"type":71,"value":3576},{"title":59,"searchDepth":78,"depth":78,"links":3581},[3582],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.2.0-16","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.2.0-16","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.2.0-16",{"name":166,"url":167,"avatar":168},{"name":3588,"tag_name":3588,"date":3589,"body":3590,"v":294,"url":3632,"tarball":3633,"zipball":3634,"prerelease":60,"reactions":3635,"author":3637,"title":59,"description":59,"_type":80,"_id":3638},"v0.1.26","2022-09-16T11:17:29Z",{"type":63,"children":3591,"toc":3629},[3592,3596,3610,3615],{"type":66,"tag":98,"props":3593,"children":3594},{"id":100},[3595],{"type":71,"value":103},{"type":66,"tag":112,"props":3597,"children":3598},{},[3599],{"type":66,"tag":116,"props":3600,"children":3601},{},[3602,3603],{"type":71,"value":3507},{"type":66,"tag":128,"props":3604,"children":3607},{"href":3605,"rel":3606},"https://github.com/nuxt/framework/releases/tag/v3.0.0-rc.10",[132],[3608],{"type":71,"value":3609},"rc.10",{"type":66,"tag":67,"props":3611,"children":3612},{},[3613],{"type":71,"value":3614},"Stable in coming 🚀",{"type":66,"tag":67,"props":3616,"children":3617},{},[3618,3622,3623],{"type":66,"tag":120,"props":3619,"children":3620},{},[3621],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3624,"children":3627},{"href":3625,"rel":3626},"https://github.com/nuxt-community/supabase-module/compare/v0.1.25...v0.1.26",[132],[3628],{"type":71,"value":3625},{"title":59,"searchDepth":78,"depth":78,"links":3630},[3631],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.26","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.26","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.26",{"url":3636,"total_count":161,"+1":161,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":294,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/77384555/reactions",{"name":166,"url":167,"avatar":168},"github:v0.1.26.md",{"name":3640,"tag_name":3640,"date":3641,"body":3642,"v":294,"url":3745,"tarball":3746,"zipball":3747,"prerelease":60,"reactions":3748,"author":3750,"title":59,"description":59,"_type":80,"_id":3751},"v0.1.25","2022-09-05T07:28:01Z",{"type":63,"children":3643,"toc":3742},[3644,3648,3728],{"type":66,"tag":98,"props":3645,"children":3646},{"id":100},[3647],{"type":71,"value":103},{"type":66,"tag":112,"props":3649,"children":3650},{},[3651,3687,3715],{"type":66,"tag":116,"props":3652,"children":3653},{},[3654,3656,3667,3668,3679,3681],{"type":71,"value":3655},"docs: new directory architecture + supabase module v2 coming soon in ",{"type":66,"tag":128,"props":3657,"children":3660},{"href":3658,"rel":3659},"https://github.com/nuxt-modules/supabase/commit/d48522a369bcced45dfb3d16793b33f0144ffa50",[132],[3661],{"type":66,"tag":312,"props":3662,"children":3664},{"className":3663},[],[3665],{"type":71,"value":3666},"d48522a",{"type":71,"value":713},{"type":66,"tag":128,"props":3669,"children":3672},{"href":3670,"rel":3671},"https://github.com/nuxt-modules/supabase/commit/e69712b4862a5baa464c01ae32755473358b82d2",[132],[3673],{"type":66,"tag":312,"props":3674,"children":3676},{"className":3675},[],[3677],{"type":71,"value":3678},"e69712b",{"type":71,"value":3680},". Check out ",{"type":66,"tag":128,"props":3682,"children":3685},{"href":3683,"rel":3684},"https://supabase.nuxtjs.org/",[132],[3686],{"type":71,"value":3683},{"type":66,"tag":116,"props":3688,"children":3689},{},[3690,3692,3703,3704],{"type":71,"value":3691},"chore: upgrade to rc9 in ",{"type":66,"tag":128,"props":3693,"children":3696},{"href":3694,"rel":3695},"https://github.com/nuxt-modules/supabase/commit/3c5220bf9569d2e939a466aa4a2814e0dc38622c",[132],[3697],{"type":66,"tag":312,"props":3698,"children":3700},{"className":3699},[],[3701],{"type":71,"value":3702},"3c5220b",{"type":71,"value":713},{"type":66,"tag":128,"props":3705,"children":3708},{"href":3706,"rel":3707},"https://github.com/nuxt-modules/supabase/commit/495e0b705622e9bda28072815c828beedea1082c",[132],[3709],{"type":66,"tag":312,"props":3710,"children":3712},{"className":3711},[],[3713],{"type":71,"value":3714},"495e0b7",{"type":66,"tag":116,"props":3716,"children":3717},{},[3718,3720,3727],{"type":71,"value":3719},"chore: fix nuxt compatibility (",{"type":66,"tag":128,"props":3721,"children":3724},{"href":3722,"rel":3723},"https://github.com/nuxt-modules/supabase/issues/70",[132],[3725],{"type":71,"value":3726},"#70",{"type":71,"value":255},{"type":66,"tag":67,"props":3729,"children":3730},{},[3731,3735,3736],{"type":66,"tag":120,"props":3732,"children":3733},{},[3734],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3737,"children":3740},{"href":3738,"rel":3739},"https://github.com/nuxt-community/supabase-module/compare/v0.1.23...v0.1.25",[132],[3741],{"type":71,"value":3738},{"title":59,"searchDepth":78,"depth":78,"links":3743},[3744],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.25","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.25","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.25",{"url":3749,"total_count":685,"+1":294,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":685,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/76259131/reactions",{"name":166,"url":167,"avatar":168},"github:v0.1.25.md",{"name":3753,"tag_name":3753,"date":3754,"body":3755,"v":294,"url":3823,"tarball":3824,"zipball":3825,"prerelease":60,"author":3826,"title":59,"description":59,"_type":80,"_id":3827},"v0.1.23","2022-08-16T10:12:13Z",{"type":63,"children":3756,"toc":3820},[3757,3761,3806],{"type":66,"tag":98,"props":3758,"children":3759},{"id":100},[3760],{"type":71,"value":103},{"type":66,"tag":112,"props":3762,"children":3763},{},[3764],{"type":66,"tag":116,"props":3765,"children":3766},{},[3767,3769,3782,3784,3796,3798,3805],{"type":71,"value":3768},"fix: transpile supabase packages in ",{"type":66,"tag":128,"props":3770,"children":3773},{"href":3771,"rel":3772},"https://github.com/nuxt-community/supabase-module/commit/66020204e8aad98db94a83964f1bb988642c90f3",[132],[3774,3776],{"type":71,"value":3775},"nuxt-community/supabase-module@",{"type":66,"tag":312,"props":3777,"children":3779},{"className":3778},[],[3780],{"type":71,"value":3781},"6602020",{"type":71,"value":3783}," ",{"type":66,"tag":128,"props":3785,"children":3788},{"href":3786,"rel":3787},"https://github.com/nuxt-community/supabase-module/commit/237ddf2cf83079e39748b6252182ca1d2f62cc54",[132],[3789,3790],{"type":71,"value":3775},{"type":66,"tag":312,"props":3791,"children":3793},{"className":3792},[],[3794],{"type":71,"value":3795},"237ddf2",{"type":71,"value":3797}," and (",{"type":66,"tag":128,"props":3799,"children":3802},{"href":3800,"rel":3801},"https://github.com/nuxt-modules/supabase/issues/62",[132],[3803],{"type":71,"value":3804},"#62",{"type":71,"value":255},{"type":66,"tag":67,"props":3807,"children":3808},{},[3809,3813,3814],{"type":66,"tag":120,"props":3810,"children":3811},{},[3812],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3815,"children":3818},{"href":3816,"rel":3817},"https://github.com/nuxt-community/supabase-module/compare/v0.1.20...v0.1.23",[132],[3819],{"type":71,"value":3816},{"title":59,"searchDepth":78,"depth":78,"links":3821},[3822],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.23","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.23","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.23",{"name":166,"url":167,"avatar":168},"github:v0.1.23.md",{"name":3829,"tag_name":3829,"date":3830,"body":3831,"v":294,"url":3901,"tarball":3902,"zipball":3903,"prerelease":60,"author":3904,"title":59,"description":59,"_type":80,"_id":3905},"v0.1.20","2022-08-16T09:12:14Z",{"type":63,"children":3832,"toc":3897},[3833,3837,3852,3866,3872],{"type":66,"tag":98,"props":3834,"children":3835},{"id":100},[3836],{"type":71,"value":103},{"type":66,"tag":112,"props":3838,"children":3839},{},[3840],{"type":66,"tag":116,"props":3841,"children":3842},{},[3843,3845],{"type":71,"value":3844},"chore: upgrade to ",{"type":66,"tag":128,"props":3846,"children":3849},{"href":3847,"rel":3848},"https://github.com/nuxt/framework/releases/tag/v3.0.0-rc.8",[132],[3850],{"type":71,"value":3851},"nuxt rc.8",{"type":66,"tag":67,"props":3853,"children":3854},{},[3855,3859,3860],{"type":66,"tag":120,"props":3856,"children":3857},{},[3858],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3861,"children":3864},{"href":3862,"rel":3863},"https://github.com/nuxt-community/supabase-module/compare/v0.1.19...v0.1.20",[132],[3865],{"type":71,"value":3862},{"type":66,"tag":98,"props":3867,"children":3869},{"id":3868},"new-contributors",[3870],{"type":71,"value":3871},"New Contributors",{"type":66,"tag":112,"props":3873,"children":3874},{},[3875],{"type":66,"tag":116,"props":3876,"children":3877},{},[3878,3888,3890],{"type":66,"tag":128,"props":3879,"children":3882},{"href":3880,"rel":3881},"https://github.com/josuemartinezz",[132],[3883],{"type":66,"tag":120,"props":3884,"children":3885},{},[3886],{"type":71,"value":3887},"@josuemartinezz",{"type":71,"value":3889}," made his first contribution in ",{"type":66,"tag":128,"props":3891,"children":3894},{"href":3892,"rel":3893},"https://github.com/nuxt-modules/supabase/issues/59",[132],[3895],{"type":71,"value":3896},"#59",{"title":59,"searchDepth":78,"depth":78,"links":3898},[3899,3900],{"id":100,"depth":78,"text":103},{"id":3868,"depth":78,"text":3871},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.20","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.20","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.20",{"name":166,"url":167,"avatar":168},"github:v0.1.20.md",{"name":3907,"tag_name":3907,"date":3908,"body":3909,"v":294,"url":3963,"tarball":3964,"zipball":3965,"prerelease":60,"reactions":3966,"author":3968,"title":59,"description":59,"_type":80,"_id":3969},"v0.1.19","2022-07-18T08:18:42Z",{"type":63,"children":3910,"toc":3960},[3911,3915,3946],{"type":66,"tag":98,"props":3912,"children":3913},{"id":100},[3914],{"type":71,"value":103},{"type":66,"tag":112,"props":3916,"children":3917},{},[3918,3929],{"type":66,"tag":116,"props":3919,"children":3920},{},[3921,3922],{"type":71,"value":3844},{"type":66,"tag":128,"props":3923,"children":3926},{"href":3924,"rel":3925},"https://github.com/nuxt/framework/pull/5825",[132],[3927],{"type":71,"value":3928},"nuxt rc.5",{"type":66,"tag":116,"props":3930,"children":3931},{},[3932,3934],{"type":71,"value":3933},"doc: add supabase icon in ",{"type":66,"tag":128,"props":3935,"children":3938},{"href":3936,"rel":3937},"https://github.com/nuxt-community/supabase-module/commit/c0cce016eae809fd64acc9a503b4807750280b39",[132],[3939,3940],{"type":71,"value":3775},{"type":66,"tag":312,"props":3941,"children":3943},{"className":3942},[],[3944],{"type":71,"value":3945},"c0cce01",{"type":66,"tag":67,"props":3947,"children":3948},{},[3949,3953,3954],{"type":66,"tag":120,"props":3950,"children":3951},{},[3952],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":3955,"children":3958},{"href":3956,"rel":3957},"https://github.com/nuxt-community/supabase-module/compare/v0.1.18...v0.1.19",[132],[3959],{"type":71,"value":3956},{"title":59,"searchDepth":78,"depth":78,"links":3961},[3962],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.19","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.19","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.19",{"url":3967,"total_count":161,"+1":294,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":294,"rocket":161,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/72200550/reactions",{"name":166,"url":167,"avatar":168},"github:v0.1.19.md",{"name":3971,"tag_name":3971,"date":3972,"body":3973,"v":294,"url":4050,"tarball":4051,"zipball":4052,"prerelease":60,"author":4053,"title":59,"description":59,"_type":80,"_id":4054},"v0.1.18","2022-06-29T09:23:26Z",{"type":63,"children":3974,"toc":4047},[3975,3979,4033],{"type":66,"tag":98,"props":3976,"children":3977},{"id":100},[3978],{"type":71,"value":103},{"type":66,"tag":112,"props":3980,"children":3981},{},[3982,4008],{"type":66,"tag":116,"props":3983,"children":3984},{},[3985,3987,3999,4000,4007],{"type":71,"value":3986},"doc: update logo & social preview in ",{"type":66,"tag":128,"props":3988,"children":3991},{"href":3989,"rel":3990},"https://github.com/nuxt-community/supabase-module/commit/9b0b2fbee1f2fed50e903c2b368b817568d7ab1f",[132],[3992,3993],{"type":71,"value":3775},{"type":66,"tag":312,"props":3994,"children":3996},{"className":3995},[],[3997],{"type":71,"value":3998},"9b0b2fb",{"type":71,"value":501},{"type":66,"tag":128,"props":4001,"children":4004},{"href":4002,"rel":4003},"https://github.com/nuxt-modules/supabase/issues/53",[132],[4005],{"type":71,"value":4006},"#53",{"type":71,"value":255},{"type":66,"tag":116,"props":4009,"children":4010},{},[4011,4012,4024,4025,4032],{"type":71,"value":3768},{"type":66,"tag":128,"props":4013,"children":4016},{"href":4014,"rel":4015},"https://github.com/nuxt-community/supabase-module/commit/309c137f7ae23985f0ed9947fb85cb75cbfbfca2",[132],[4017,4018],{"type":71,"value":3775},{"type":66,"tag":312,"props":4019,"children":4021},{"className":4020},[],[4022],{"type":71,"value":4023},"309c137",{"type":71,"value":501},{"type":66,"tag":128,"props":4026,"children":4029},{"href":4027,"rel":4028},"https://github.com/nuxt-modules/supabase/issues/55",[132],[4030],{"type":71,"value":4031},"#55",{"type":71,"value":255},{"type":66,"tag":67,"props":4034,"children":4035},{},[4036,4040,4041],{"type":66,"tag":120,"props":4037,"children":4038},{},[4039],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":4042,"children":4045},{"href":4043,"rel":4044},"https://github.com/nuxt-community/supabase-module/compare/v0.1.17...v0.1.18",[132],[4046],{"type":71,"value":4043},{"title":59,"searchDepth":78,"depth":78,"links":4048},[4049],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.18","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.18","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.18",{"name":166,"url":167,"avatar":168},"github:v0.1.18.md",{"name":4056,"tag_name":4056,"date":4057,"body":4058,"v":294,"url":4150,"tarball":4151,"zipball":4152,"prerelease":60,"reactions":4153,"author":4155,"title":59,"description":59,"_type":80,"_id":4156},"v0.1.17","2022-06-17T07:01:12Z",{"type":63,"children":4059,"toc":4147},[4060,4064,4120,4133],{"type":66,"tag":98,"props":4061,"children":4062},{"id":100},[4063],{"type":71,"value":103},{"type":66,"tag":112,"props":4065,"children":4066},{},[4067,4078,4103],{"type":66,"tag":116,"props":4068,"children":4069},{},[4070,4071],{"type":71,"value":3844},{"type":66,"tag":128,"props":4072,"children":4075},{"href":4073,"rel":4074},"https://github.com/nuxt/framework/discussions/5445",[132],[4076],{"type":71,"value":4077},"nuxt rc.4",{"type":66,"tag":116,"props":4079,"children":4080},{},[4081,4083,4090,4091],{"type":71,"value":4082},"doc: update ",{"type":66,"tag":128,"props":4084,"children":4087},{"href":4085,"rel":4086},"https://docus.com/",[132],[4088],{"type":71,"value":4089},"docus theme",{"type":71,"value":619},{"type":66,"tag":128,"props":4092,"children":4095},{"href":4093,"rel":4094},"https://github.com/nuxt-community/supabase-module/commit/64a5add3db5e0416a8a3b7f9708d27148797e958",[132],[4096,4097],{"type":71,"value":3775},{"type":66,"tag":312,"props":4098,"children":4100},{"className":4099},[],[4101],{"type":71,"value":4102},"64a5add",{"type":66,"tag":116,"props":4104,"children":4105},{},[4106,4108],{"type":71,"value":4107},"doc: add advanced usage with supabase realtime ",{"type":66,"tag":128,"props":4109,"children":4112},{"href":4110,"rel":4111},"https://github.com/nuxt-community/supabase-module/commit/8047e311e5526a4597b81a99dc8045114348172f",[132],[4113,4114],{"type":71,"value":3775},{"type":66,"tag":312,"props":4115,"children":4117},{"className":4116},[],[4118],{"type":71,"value":4119},"8047e31",{"type":66,"tag":67,"props":4121,"children":4122},{},[4123,4125,4131],{"type":71,"value":4124},"Checkout the ",{"type":66,"tag":128,"props":4126,"children":4129},{"href":4127,"rel":4128},"https://supabase.nuxtjs.org/advanced#realtime",[132],[4130],{"type":71,"value":3366},{"type":71,"value":4132}," for supabase realtime!",{"type":66,"tag":67,"props":4134,"children":4135},{},[4136,4140,4141],{"type":66,"tag":120,"props":4137,"children":4138},{},[4139],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":4142,"children":4145},{"href":4143,"rel":4144},"https://github.com/nuxt-community/supabase-module/compare/v0.1.16...v0.1.17",[132],[4146],{"type":71,"value":4143},{"title":59,"searchDepth":78,"depth":78,"links":4148},[4149],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.17","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.17","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.17",{"url":4154,"total_count":161,"+1":294,"-1":294,"laugh":294,"hooray":294,"confused":294,"heart":161,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/69689480/reactions",{"name":166,"url":167,"avatar":168},"github:v0.1.17.md",{"name":4158,"tag_name":4158,"date":4159,"body":4160,"v":294,"url":4258,"tarball":4259,"zipball":4260,"prerelease":60,"author":4261,"title":59,"description":59,"_type":80,"_id":4262},"v0.1.16","2022-06-01T10:51:45Z",{"type":63,"children":4161,"toc":4255},[4162,4166,4229,4241],{"type":66,"tag":98,"props":4163,"children":4164},{"id":100},[4165],{"type":71,"value":103},{"type":66,"tag":112,"props":4167,"children":4168},{},[4169,4203],{"type":66,"tag":116,"props":4170,"children":4171},{},[4172,4174,4181,4182,4194,4195,4202],{"type":71,"value":4173},"doc: use docus theme (public release coming soon) powered by ",{"type":66,"tag":128,"props":4175,"children":4178},{"href":4176,"rel":4177},"https://content.nuxtjs.org/",[132],[4179],{"type":71,"value":4180},"nuxt content v2",{"type":71,"value":619},{"type":66,"tag":128,"props":4183,"children":4186},{"href":4184,"rel":4185},"https://github.com/nuxt-community/supabase-module/commit/c24a16ff0bc94221adc021231a2206b6db8f293c",[132],[4187,4188],{"type":71,"value":3775},{"type":66,"tag":312,"props":4189,"children":4191},{"className":4190},[],[4192],{"type":71,"value":4193},"c24a16f",{"type":71,"value":501},{"type":66,"tag":128,"props":4196,"children":4199},{"href":4197,"rel":4198},"https://github.com/nuxt-modules/supabase/issues/41",[132],[4200],{"type":71,"value":4201},"#41",{"type":71,"value":255},{"type":66,"tag":116,"props":4204,"children":4205},{},[4206,4208,4220,4221,4228],{"type":71,"value":4207},"feat: service role client to bypass RLS in ",{"type":66,"tag":128,"props":4209,"children":4212},{"href":4210,"rel":4211},"https://github.com/nuxt-community/supabase-module/commit/ba70a976be97acb3c438d59e45b789ee917bee6b",[132],[4213,4214],{"type":71,"value":3775},{"type":66,"tag":312,"props":4215,"children":4217},{"className":4216},[],[4218],{"type":71,"value":4219},"ba70a97",{"type":71,"value":501},{"type":66,"tag":128,"props":4222,"children":4225},{"href":4223,"rel":4224},"https://github.com/nuxt-modules/supabase/issues/43",[132],[4226],{"type":71,"value":4227},"#43",{"type":71,"value":255},{"type":66,"tag":67,"props":4230,"children":4231},{},[4232,4234,4239],{"type":71,"value":4233},"Checkout the new ",{"type":66,"tag":128,"props":4235,"children":4237},{"href":1785,"rel":4236},[132],[4238],{"type":71,"value":3366},{"type":71,"value":4240}," !",{"type":66,"tag":67,"props":4242,"children":4243},{},[4244,4248,4249],{"type":66,"tag":120,"props":4245,"children":4246},{},[4247],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":4250,"children":4253},{"href":4251,"rel":4252},"https://github.com/nuxt-community/supabase-module/compare/v0.1.14...v0.1.16",[132],[4254],{"type":71,"value":4251},{"title":59,"searchDepth":78,"depth":78,"links":4256},[4257],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.16","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.16","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.16",{"name":166,"url":167,"avatar":168},"github:v0.1.16.md",{"name":4264,"tag_name":4264,"date":4265,"body":4266,"v":294,"url":4374,"tarball":4375,"zipball":4376,"prerelease":60,"author":4377,"title":59,"description":59,"_type":80,"_id":4378},"v0.1.14","2022-05-13T16:48:40Z",{"type":63,"children":4267,"toc":4371},[4268,4272,4335,4357],{"type":66,"tag":98,"props":4269,"children":4270},{"id":100},[4271],{"type":71,"value":103},{"type":66,"tag":112,"props":4273,"children":4274},{},[4275,4292,4309],{"type":66,"tag":116,"props":4276,"children":4277},{},[4278,4280],{"type":71,"value":4279},"feat: add playground folder in ",{"type":66,"tag":128,"props":4281,"children":4284},{"href":4282,"rel":4283},"https://github.com/nuxt-community/supabase-module/commit/339cf31cf48d4059ba0e4470d6e5e2aa9ef184c7",[132],[4285,4286],{"type":71,"value":3775},{"type":66,"tag":312,"props":4287,"children":4289},{"className":4288},[],[4290],{"type":71,"value":4291},"339cf31",{"type":66,"tag":116,"props":4293,"children":4294},{},[4295,4297],{"type":71,"value":4296},"fix: client options in ",{"type":66,"tag":128,"props":4298,"children":4301},{"href":4299,"rel":4300},"https://github.com/nuxt-community/supabase-module/commit/4c5595c11caf7a55621d297f6a0183a756175473",[132],[4302,4303],{"type":71,"value":3775},{"type":66,"tag":312,"props":4304,"children":4306},{"className":4305},[],[4307],{"type":71,"value":4308},"4c5595c",{"type":66,"tag":116,"props":4310,"children":4311},{},[4312,4314,4326,4327,4334],{"type":71,"value":4313},"feat: add server routes services in ",{"type":66,"tag":128,"props":4315,"children":4318},{"href":4316,"rel":4317},"https://github.com/nuxt-community/supabase-module/commit/696d3e8d19b8db79c85e86b79a3ba4dd31bb2343",[132],[4319,4320],{"type":71,"value":3775},{"type":66,"tag":312,"props":4321,"children":4323},{"className":4322},[],[4324],{"type":71,"value":4325},"696d3e8",{"type":71,"value":501},{"type":66,"tag":128,"props":4328,"children":4331},{"href":4329,"rel":4330},"https://github.com/nuxt-modules/supabase/issues/36",[132],[4332],{"type":71,"value":4333},"#36",{"type":71,"value":255},{"type":66,"tag":67,"props":4336,"children":4337},{},[4338,4340,4347,4349,4355],{"type":71,"value":4339},"You can check the ",{"type":66,"tag":128,"props":4341,"children":4344},{"href":4342,"rel":4343},"https://supabase.nuxtjs.org/usage#server-routes-services",[132],[4345],{"type":71,"value":4346},"documentation updated",{"type":71,"value":4348}," for the use of ",{"type":66,"tag":312,"props":4350,"children":4352},{"className":4351},[],[4353],{"type":71,"value":4354},"services",{"type":71,"value":4356}," in server routes.",{"type":66,"tag":67,"props":4358,"children":4359},{},[4360,4364,4365],{"type":66,"tag":120,"props":4361,"children":4362},{},[4363],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":4366,"children":4369},{"href":4367,"rel":4368},"https://github.com/nuxt-community/supabase-module/compare/v0.1.11...v0.1.14",[132],[4370],{"type":71,"value":4367},{"title":59,"searchDepth":78,"depth":78,"links":4372},[4373],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.14","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.14","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.14",{"name":166,"url":167,"avatar":168},"github:v0.1.14.md",{"name":4380,"tag_name":4380,"date":4381,"body":4382,"v":294,"url":4408,"tarball":4409,"zipball":4410,"prerelease":60,"author":4411,"title":59,"description":59,"_type":80,"_id":4412},"v0.1.11","2022-05-06T08:51:02Z",{"type":63,"children":4383,"toc":4406},[4384,4392],{"type":66,"tag":112,"props":4385,"children":4386},{},[4387],{"type":66,"tag":116,"props":4388,"children":4389},{},[4390],{"type":71,"value":4391},"chore: upgrade deps",{"type":66,"tag":67,"props":4393,"children":4394},{},[4395,4399,4400],{"type":66,"tag":120,"props":4396,"children":4397},{},[4398],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":4401,"children":4404},{"href":4402,"rel":4403},"https://github.com/nuxt-community/supabase-module/compare/v0.1.9...v0.1.11",[132],[4405],{"type":71,"value":4402},{"title":59,"searchDepth":78,"depth":78,"links":4407},[],"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.11","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.11","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.11",{"name":166,"url":167,"avatar":168},"github:v0.1.11.md",{"name":4414,"tag_name":4414,"date":4415,"body":4416,"v":294,"url":4469,"tarball":4470,"zipball":4471,"prerelease":60,"author":4472,"title":59,"description":59,"_type":80,"_id":4476},"v0.1.9","2022-04-20T11:07:23Z",{"type":63,"children":4417,"toc":4467},[4418,4453],{"type":66,"tag":112,"props":4419,"children":4420},{},[4421],{"type":66,"tag":116,"props":4422,"children":4423},{},[4424,4426,4432,4433,4439,4440,4452],{"type":71,"value":4425},"fix: use ",{"type":66,"tag":312,"props":4427,"children":4429},{"className":4428},[],[4430],{"type":71,"value":4431},"#imports",{"type":71,"value":2972},{"type":66,"tag":312,"props":4434,"children":4436},{"className":4435},[],[4437],{"type":71,"value":4438},"#nitro",{"type":71,"value":501},{"type":66,"tag":128,"props":4441,"children":4444},{"href":4442,"rel":4443},"https://github.com/nuxt-community/supabase-module/commit/42af598b7d9f3adf2c577c20e9cfb68bbb17d52b",[132],[4445,4446],{"type":71,"value":3775},{"type":66,"tag":312,"props":4447,"children":4449},{"className":4448},[],[4450],{"type":71,"value":4451},"42af598",{"type":71,"value":255},{"type":66,"tag":67,"props":4454,"children":4455},{},[4456,4460,4461],{"type":66,"tag":120,"props":4457,"children":4458},{},[4459],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":4462,"children":4465},{"href":4463,"rel":4464},"https://github.com/nuxt-community/supabase-module/compare/v0.1.8...v0.1.9",[132],[4466],{"type":71,"value":4463},{"title":59,"searchDepth":78,"depth":78,"links":4468},[],"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.9","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.9","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.9",{"name":4473,"url":4474,"avatar":4475},"atinux","https://github.com/atinux","https://avatars.githubusercontent.com/u/904724?v=4","github:v0.1.9.md",{"name":4478,"tag_name":4478,"date":4479,"body":4480,"v":294,"url":4536,"tarball":4537,"zipball":4538,"prerelease":60,"author":4539,"title":59,"description":59,"_type":80,"_id":4540},"v0.1.8","2022-04-13T12:26:33Z",{"type":63,"children":4481,"toc":4533},[4482,4486],{"type":66,"tag":98,"props":4483,"children":4484},{"id":100},[4485],{"type":71,"value":103},{"type":66,"tag":112,"props":4487,"children":4488},{},[4489,4506],{"type":66,"tag":116,"props":4490,"children":4491},{},[4492,4494],{"type":71,"value":4493},"fix: update runtime config fetch and override in ",{"type":66,"tag":128,"props":4495,"children":4498},{"href":4496,"rel":4497},"https://github.com/nuxt-community/supabase-module/commit/260ebc7be39dfa65902ad4fe6a49639c99a69da8",[132],[4499,4500],{"type":71,"value":3775},{"type":66,"tag":312,"props":4501,"children":4503},{"className":4502},[],[4504],{"type":71,"value":4505},"260ebc7",{"type":66,"tag":116,"props":4507,"children":4508},{},[4509,4511,4523,4525,4532],{"type":71,"value":4510},"feat: handle session with defineEventHandler in ",{"type":66,"tag":128,"props":4512,"children":4515},{"href":4513,"rel":4514},"https://github.com/nuxt-community/supabase-module/commit/e646b1ce03773bf44932824726f280ad15455ec2",[132],[4516,4517],{"type":71,"value":3775},{"type":66,"tag":312,"props":4518,"children":4520},{"className":4519},[],[4521],{"type":71,"value":4522},"e646b1c",{"type":71,"value":4524}," (Check ",{"type":66,"tag":128,"props":4526,"children":4529},{"href":4527,"rel":4528},"https://v3.nuxtjs.org/guide/features/server-routes",[132],[4530],{"type":71,"value":4531},"Nuxt doc",{"type":71,"value":255},{"title":59,"searchDepth":78,"depth":78,"links":4534},[4535],{"id":100,"depth":78,"text":103},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.8","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.8","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.8",{"name":166,"url":167,"avatar":168},"github:v0.1.8.md",{"name":4542,"tag_name":4542,"date":4543,"body":4544,"v":294,"url":4622,"tarball":4623,"zipball":4624,"prerelease":60,"reactions":4625,"author":4627,"title":59,"description":59,"_type":80,"_id":4628},"v0.1.7","2022-04-07T21:31:24Z",{"type":63,"children":4545,"toc":4618},[4546,4550,4593,4597],{"type":66,"tag":98,"props":4547,"children":4548},{"id":100},[4549],{"type":71,"value":103},{"type":66,"tag":112,"props":4551,"children":4552},{},[4553,4570],{"type":66,"tag":116,"props":4554,"children":4555},{},[4556,4558],{"type":71,"value":4557},"fix: assert method and use correct key for server middleware in ",{"type":66,"tag":128,"props":4559,"children":4562},{"href":4560,"rel":4561},"https://github.com/nuxt-community/supabase-module/commit/8a4d63101e6d2bc24563f7944988909ec7dcc6e5",[132],[4563,4564],{"type":71,"value":3775},{"type":66,"tag":312,"props":4565,"children":4567},{"className":4566},[],[4568],{"type":71,"value":4569},"8a4d631",{"type":66,"tag":116,"props":4571,"children":4572},{},[4573,4575,4585,4586],{"type":71,"value":4574},"fix: replace #config with #nitro by ",{"type":66,"tag":128,"props":4576,"children":4579},{"href":4577,"rel":4578},"https://github.com/psto",[132],[4580],{"type":66,"tag":120,"props":4581,"children":4582},{},[4583],{"type":71,"value":4584},"@psto",{"type":71,"value":619},{"type":66,"tag":128,"props":4587,"children":4590},{"href":4588,"rel":4589},"https://github.com/nuxt-community/supabase-module/pull/23",[132],[4591],{"type":71,"value":4592},"nuxt-community/supabase-module#23",{"type":66,"tag":98,"props":4594,"children":4595},{"id":3868},[4596],{"type":71,"value":3871},{"type":66,"tag":112,"props":4598,"children":4599},{},[4600],{"type":66,"tag":116,"props":4601,"children":4602},{},[4603,4611,4613],{"type":66,"tag":128,"props":4604,"children":4606},{"href":4577,"rel":4605},[132],[4607],{"type":66,"tag":120,"props":4608,"children":4609},{},[4610],{"type":71,"value":4584},{"type":71,"value":4612}," made their first contribution in ",{"type":66,"tag":128,"props":4614,"children":4616},{"href":4588,"rel":4615},[132],[4617],{"type":71,"value":4592},{"title":59,"searchDepth":78,"depth":78,"links":4619},[4620,4621],{"id":100,"depth":78,"text":103},{"id":3868,"depth":78,"text":3871},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.7","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.7","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.7",{"url":4626,"total_count":160,"+1":294,"-1":294,"laugh":294,"hooray":160,"confused":294,"heart":294,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/63922233/reactions",{"name":4473,"url":4474,"avatar":4475},"github:v0.1.7.md",{"name":4630,"tag_name":4630,"date":4631,"body":4632,"v":294,"url":4679,"tarball":4680,"zipball":4681,"prerelease":60,"reactions":4682,"author":4685,"title":59,"description":59,"_type":80,"_id":4686},"v0.1.5","2022-04-04T10:15:21Z",{"type":63,"children":4633,"toc":4676},[4634,4638,4662],{"type":66,"tag":105,"props":4635,"children":4636},{"id":107},[4637],{"type":71,"value":110},{"type":66,"tag":112,"props":4639,"children":4640},{},[4641],{"type":66,"tag":116,"props":4642,"children":4643},{},[4644,4646,4653,4655],{"type":71,"value":4645},"remove lodash.clonedeep (",{"type":66,"tag":128,"props":4647,"children":4650},{"href":4648,"rel":4649},"https://github.com/nuxt-community/supabase-module/commit/b5c5c60358ab192b98c8a63185f58a2eb0ab706a",[132],[4651],{"type":71,"value":4652},"b5c5c60",{"type":71,"value":4654},"), resolved ",{"type":66,"tag":128,"props":4656,"children":4659},{"href":4657,"rel":4658},"https://github.com/nuxt-modules/supabase/issues/21",[132],[4660],{"type":71,"value":4661},"#21",{"type":66,"tag":67,"props":4663,"children":4664},{},[4665,4669,4670],{"type":66,"tag":120,"props":4666,"children":4667},{},[4668],{"type":71,"value":1528},{"type":71,"value":1530},{"type":66,"tag":128,"props":4671,"children":4674},{"href":4672,"rel":4673},"https://github.com/nuxt-community/supabase-module/compare/v0.1.4...v0.1.5",[132],[4675],{"type":71,"value":4672},{"title":59,"searchDepth":78,"depth":78,"links":4677},[4678],{"id":107,"depth":160,"text":110},"https://github.com/nuxt-modules/supabase/releases/tag/v0.1.5","https://api.github.com/repos/nuxt-modules/supabase/tarball/v0.1.5","https://api.github.com/repos/nuxt-modules/supabase/zipball/v0.1.5",{"url":4683,"total_count":4684,"+1":294,"-1":294,"laugh":294,"hooray":585,"confused":294,"heart":78,"rocket":294,"eyes":294},"https://api.github.com/repos/nuxt-modules/supabase/releases/63507078/reactions",6,{"name":4473,"url":4474,"avatar":4475},"github:v0.1.5.md",1724942526960] \ No newline at end of file diff --git a/changelog/index.html b/changelog/index.html index 4f0b0375..bf418e34 100644 --- a/changelog/index.html +++ b/changelog/index.html @@ -59,7 +59,7 @@ - + @@ -125,5 +125,5 @@ @tnntwister @yannaufray @DamianGlowala

v0.3.3 March 31, 2023

What's Changed

  • perf(useSupabaseAuthClient): avoid declaring unused variables (#166) (8c070b9)
  • feat(demo): add call from server route (989a91e)
  • chore(demo): upgrade deps (9ebbc77)
  • chore(deps): upgrade (e274a5e)
  • docs(composables): correct grammar errors (#162) (034d7df)
  • docs(readme): add nuxt badge (68271b8)
  • docs(demo): fix typo (#125) (bd33d12)
  • docs(get-started): fix typos (#154) (ba437a8)
  • chore(module): conditionally add redirect plugin (#157) (0cad0a5)
  • chore(app): move to pnpm (94f7e13)
  • docs(links): update nuxt & supabase links and fix typos (#126) (5699dc6)
  • chore(demo): generate database types from supabase cli (bca1992)

Full Changelog: https://github.com/nuxt-community/supabase-module/compare/v0.3.1...v0.3.3

v0.3.1 February 7, 2023

What's Changed

  • chore(app): upgrade deps and fix lint (68baf68)
  • fix(client): unset user before session on logout (ab574ef)
  • chore(demo): update with latest and fix logout

Full Changelog: https://github.com/nuxt-community/supabase-module/compare/v0.3.0...v0.3.1

v0.3.0 November 22, 2022

⚠️ BREAKING CHANGES ⚠️

What's Changed

In order to resolve #114, I have made the choice to separate the useSupabaseClient in two other composables:

  • The useSupabaseAuthClient is dedicated to authentification purpose only. It won't be recreate if your token expires, it is used in the client plugin to listen to onAuthStateChange events.
  • The useSupabaseClient is now only useful for data request.

To avoid regression you just need to use useSupabaseAuthClient instead of useSupabaseClient everywhere you use Supabase auth methods.

Documentation has been updated.

Full Changelog: https://github.com/nuxt-community/supabase-module/compare/v0.2.6...v0.3.0

v0.2.6 November 22, 2022

v0.2.5 November 22, 2022

What's Changed

  • fix: use Router instead of navigateTo for login redirect in 79fc0e4 (resolves #89)

Full Changelog: https://github.com/nuxt-community/supabase-module/compare/v0.2.4...v0.2.5

v0.2.4 November 13, 2022

v0.2.3 November 11, 2022

What's Changed

Contributors

Thanks to @manniL and @levibe 💚

Full Changelog: https://github.com/nuxt-community/supabase-module/compare/v0.2.0...v0.2.3

v0.2.0 October 17, 2022

What's Changed

⚠️ Breaking Changes

Upgrade to supabase-js v2, check Supabase release notes.

Module documentation has been updated in favor of supabase v2 syntax.

Please feel free to make PR if I missed something 🙏

🚀 Features

  • options: redirect user after signout or when user is not authenticated (check documentation)
  • session: set refresh token #18

Full Changelog: https://github.com/nuxt-community/supabase-module/compare/v0.1.28...v0.2.0

v0.1.28 October 7, 2022

What's Changed

  • fix: cloudflare workers deployment (#46)

Full Changelog: https://github.com/nuxt-community/supabase-module/compare/v0.1.27...v0.1.28

Thanks to @kevinmarrec for the fix 🔥

v0.1.27 September 23, 2022

v0.2.0 August 16, 2022

What's Changed

⚠️ Breaking Changes

Upgrade to supabase-js v2, check Supabase release notes.

Full Changelog: https://github.com/nuxt-community/supabase-module/compare/v0.1.22...v0.2.0

v0.1.26 September 16, 2022

v0.1.25 September 5, 2022

What's Changed

Full Changelog: https://github.com/nuxt-community/supabase-module/compare/v0.1.23...v0.1.25

v0.1.23 August 16, 2022

v0.1.20 August 16, 2022

v0.1.19 July 18, 2022

v0.1.18 June 29, 2022

v0.1.17 June 17, 2022

What's Changed

Checkout the documentation for supabase realtime!

Full Changelog: https://github.com/nuxt-community/supabase-module/compare/v0.1.16...v0.1.17

v0.1.16 June 1, 2022

What's Changed

Checkout the new documentation !

Full Changelog: https://github.com/nuxt-community/supabase-module/compare/v0.1.14...v0.1.16

v0.1.14 May 13, 2022

What's Changed

You can check the documentation updated for the use of services in server routes.

Full Changelog: https://github.com/nuxt-community/supabase-module/compare/v0.1.11...v0.1.14

v0.1.11 May 6, 2022

v0.1.9 April 20, 2022

v0.1.8 April 13, 2022

What's Changed

v0.1.7 April 7, 2022

What's Changed

New Contributors

v0.1.5 April 4, 2022


Made with Nuxt Studio
- - \ No newline at end of file + + \ No newline at end of file diff --git a/demo/_payload.json b/demo/_payload.json index 9859fb75..d86e4156 100644 --- a/demo/_payload.json +++ b/demo/_payload.json @@ -1 +1 @@ -[{"data":1,"prerenderedAt":161},["ShallowReactive",2],{"navigation":3,"/demo":58,"/demo-surround":156},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":48,"_dir":59,"_draft":60,"_partial":60,"_locale":59,"title":47,"description":61,"icon":49,"body":62,"_type":150,"_id":151,"_source":152,"_file":153,"_stem":154,"_extension":155},"",false,"Demonstration of using Supabase with Nuxt.",{"type":63,"children":64,"toc":144},"root",[65,72,88,95,106,112,126,132],{"type":66,"tag":67,"props":68,"children":69},"element","p",{},[70],{"type":71,"value":61},"text",{"type":66,"tag":67,"props":73,"children":74},{},[75],{"type":66,"tag":76,"props":77,"children":81},"a",{"href":78,"rel":79},"https://n3-supabase.netlify.app",[80],"nofollow",[82],{"type":66,"tag":83,"props":84,"children":87},"img",{"alt":85,"src":86},"Supabase demo with Nuxt 3","https://user-images.githubusercontent.com/904724/160422461-8f87500a-8dec-4413-86b2-ba04e1b2d17b.png",[],{"type":66,"tag":89,"props":90,"children":92},"h2",{"id":91},"live-demo",[93],{"type":71,"value":94},"Live demo",{"type":66,"tag":67,"props":96,"children":97},{},[98,100],{"type":71,"value":99},"You can play with the demo on ",{"type":66,"tag":76,"props":101,"children":103},{"href":78,"rel":102},[80],[104],{"type":71,"value":105},"n3-supabase.netlify.app",{"type":66,"tag":89,"props":107,"children":109},{"id":108},"running-locally",[110],{"type":71,"value":111},"Running locally",{"type":66,"tag":67,"props":113,"children":114},{},[115,117,124],{"type":71,"value":116},"Follow the instruction in the ",{"type":66,"tag":76,"props":118,"children":121},{"href":119,"rel":120},"https://github.com/nuxt-community/supabase-module/tree/main/demo",[80],[122],{"type":71,"value":123},"demo Readme",{"type":71,"value":125},".",{"type":66,"tag":89,"props":127,"children":129},{"id":128},"source-code",[130],{"type":71,"value":131},"Source code",{"type":66,"tag":67,"props":133,"children":134},{},[135,137,143],{"type":71,"value":136},"The source code is available on Github in the ",{"type":66,"tag":76,"props":138,"children":140},{"href":119,"rel":139},[80],[141],{"type":71,"value":142},"demo/ directory",{"type":71,"value":125},{"title":59,"searchDepth":145,"depth":145,"links":146},2,[147,148,149],{"id":91,"depth":145,"text":94},{"id":108,"depth":145,"text":111},{"id":128,"depth":145,"text":131},"markdown","content:5.demo.md","content","5.demo.md","5.demo","md",[157,159],{"_path":44,"title":43,"description":158},"Get your Supabase user from serverside with the serverSupabaseUser service",{"_path":52,"title":51,"description":160},"Discover the latest updates of the Supabase Module",1724940863153] \ No newline at end of file +[{"data":1,"prerenderedAt":161},["ShallowReactive",2],{"navigation":3,"/demo":58,"/demo-surround":156},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":48,"_dir":59,"_draft":60,"_partial":60,"_locale":59,"title":47,"description":61,"icon":49,"body":62,"_type":150,"_id":151,"_source":152,"_file":153,"_stem":154,"_extension":155},"",false,"Demonstration of using Supabase with Nuxt.",{"type":63,"children":64,"toc":144},"root",[65,72,88,95,106,112,126,132],{"type":66,"tag":67,"props":68,"children":69},"element","p",{},[70],{"type":71,"value":61},"text",{"type":66,"tag":67,"props":73,"children":74},{},[75],{"type":66,"tag":76,"props":77,"children":81},"a",{"href":78,"rel":79},"https://n3-supabase.netlify.app",[80],"nofollow",[82],{"type":66,"tag":83,"props":84,"children":87},"img",{"alt":85,"src":86},"Supabase demo with Nuxt 3","https://user-images.githubusercontent.com/904724/160422461-8f87500a-8dec-4413-86b2-ba04e1b2d17b.png",[],{"type":66,"tag":89,"props":90,"children":92},"h2",{"id":91},"live-demo",[93],{"type":71,"value":94},"Live demo",{"type":66,"tag":67,"props":96,"children":97},{},[98,100],{"type":71,"value":99},"You can play with the demo on ",{"type":66,"tag":76,"props":101,"children":103},{"href":78,"rel":102},[80],[104],{"type":71,"value":105},"n3-supabase.netlify.app",{"type":66,"tag":89,"props":107,"children":109},{"id":108},"running-locally",[110],{"type":71,"value":111},"Running locally",{"type":66,"tag":67,"props":113,"children":114},{},[115,117,124],{"type":71,"value":116},"Follow the instruction in the ",{"type":66,"tag":76,"props":118,"children":121},{"href":119,"rel":120},"https://github.com/nuxt-community/supabase-module/tree/main/demo",[80],[122],{"type":71,"value":123},"demo Readme",{"type":71,"value":125},".",{"type":66,"tag":89,"props":127,"children":129},{"id":128},"source-code",[130],{"type":71,"value":131},"Source code",{"type":66,"tag":67,"props":133,"children":134},{},[135,137,143],{"type":71,"value":136},"The source code is available on Github in the ",{"type":66,"tag":76,"props":138,"children":140},{"href":119,"rel":139},[80],[141],{"type":71,"value":142},"demo/ directory",{"type":71,"value":125},{"title":59,"searchDepth":145,"depth":145,"links":146},2,[147,148,149],{"id":91,"depth":145,"text":94},{"id":108,"depth":145,"text":111},{"id":128,"depth":145,"text":131},"markdown","content:5.demo.md","content","5.demo.md","5.demo","md",[157,159],{"_path":44,"title":43,"description":158},"Get your Supabase user from serverside with the serverSupabaseUser service",{"_path":52,"title":51,"description":160},"Discover the latest updates of the Supabase Module",1724942526954] \ No newline at end of file diff --git a/demo/index.html b/demo/index.html index b4f63fd8..a6465123 100644 --- a/demo/index.html +++ b/demo/index.html @@ -59,7 +59,7 @@ - + @@ -94,5 +94,5 @@
- - \ No newline at end of file + + \ No newline at end of file diff --git a/get-started/_payload.json b/get-started/_payload.json index a6a6ccc8..14f006b9 100644 --- a/get-started/_payload.json +++ b/get-started/_payload.json @@ -1 +1 @@ -[{"data":1,"prerenderedAt":1594},["ShallowReactive",2],{"navigation":3,"/get-started":58,"/get-started-surround":1590},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":6,"_dir":59,"_draft":60,"_partial":60,"_locale":59,"title":5,"description":61,"icon":7,"body":62,"_type":1584,"_id":1585,"_source":1586,"_file":1587,"_stem":1588,"_extension":1589},"",false,"@nuxtjs/supabase is a Nuxt module for first class integration with Supabase.",{"type":63,"children":64,"toc":1569},"root",[65,82,105,125,132,145,188,215,312,338,397,414,420,440,523,533,553,558,567,577,582,592,602,607,616,626,631,641,646,796,932,942,952,978,988,1104,1117,1126,1136,1160,1266,1279,1293,1303,1307,1336,1357,1511,1516,1536,1549,1563],{"type":66,"tag":67,"props":68,"children":69},"element","p",{},[70,80],{"type":66,"tag":71,"props":72,"children":76},"a",{"href":73,"rel":74},"https://github.com/nuxt-modules/supabase",[75],"nofollow",[77],{"type":78,"value":79},"text","@nuxtjs/supabase",{"type":78,"value":81}," is a Nuxt module for first class integration with Supabase.",{"type":66,"tag":67,"props":83,"children":84},{},[85,87,94,96,103],{"type":78,"value":86},"Checkout the ",{"type":66,"tag":71,"props":88,"children":91},{"href":89,"rel":90},"https://v3.nuxtjs.org",[75],[92],{"type":78,"value":93},"Nuxt 3",{"type":78,"value":95}," documentation and ",{"type":66,"tag":71,"props":97,"children":100},{"href":98,"rel":99},"https://supabase.com",[75],[101],{"type":78,"value":102},"Supabase",{"type":78,"value":104}," to learn more.",{"type":66,"tag":106,"props":107,"children":110},"callout",{"icon":108,"color":109},"i-heroicons-exclamation-triangle-20-solid","amber",[111],{"type":66,"tag":67,"props":112,"children":113},{},[114,116,123],{"type":78,"value":115},"For integrating Supabase with Nuxt 2, checkout ",{"type":66,"tag":71,"props":117,"children":120},{"href":118,"rel":119},"https://github.com/supabase-community/nuxt-supabase",[75],[121],{"type":78,"value":122},"supabase-community/nuxt-supabase",{"type":78,"value":124},".",{"type":66,"tag":126,"props":127,"children":129},"h2",{"id":128},"installation",[130],{"type":78,"value":131},"Installation",{"type":66,"tag":67,"props":133,"children":134},{},[135,137,143],{"type":78,"value":136},"Add ",{"type":66,"tag":138,"props":139,"children":141},"code",{"className":140},[],[142],{"type":78,"value":79},{"type":78,"value":144}," dev dependency to your project:",{"type":66,"tag":146,"props":147,"children":151},"pre",{"className":148,"code":149,"language":150,"meta":59,"style":59},"language-bash shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","npx nuxi@latest module add supabase\n","bash",[152],{"type":66,"tag":138,"props":153,"children":154},{"__ignoreMap":59},[155],{"type":66,"tag":156,"props":157,"children":160},"span",{"class":158,"line":159},"line",1,[161,167,173,178,183],{"type":66,"tag":156,"props":162,"children":164},{"style":163},"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B",[165],{"type":78,"value":166},"npx",{"type":66,"tag":156,"props":168,"children":170},{"style":169},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[171],{"type":78,"value":172}," nuxi@latest",{"type":66,"tag":156,"props":174,"children":175},{"style":169},[176],{"type":78,"value":177}," module",{"type":66,"tag":156,"props":179,"children":180},{"style":169},[181],{"type":78,"value":182}," add",{"type":66,"tag":156,"props":184,"children":185},{"style":169},[186],{"type":78,"value":187}," supabase\n",{"type":66,"tag":67,"props":189,"children":190},{},[191,192,197,199,205,207,213],{"type":78,"value":136},{"type":66,"tag":138,"props":193,"children":195},{"className":194},[],[196],{"type":78,"value":79},{"type":78,"value":198}," to the ",{"type":66,"tag":138,"props":200,"children":202},{"className":201},[],[203],{"type":78,"value":204},"modules",{"type":78,"value":206}," section of ",{"type":66,"tag":138,"props":208,"children":210},{"className":209},[],[211],{"type":78,"value":212},"nuxt.config.ts",{"type":78,"value":214},":",{"type":66,"tag":146,"props":216,"children":220},{"className":217,"code":218,"filename":212,"language":219,"meta":59,"style":59},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","export default defineNuxtConfig({\n modules: ['@nuxtjs/supabase'],\n})\n","ts",[221],{"type":66,"tag":138,"props":222,"children":223},{"__ignoreMap":59},[224,256,298],{"type":66,"tag":156,"props":225,"children":226},{"class":158,"line":159},[227,233,238,244,250],{"type":66,"tag":156,"props":228,"children":230},{"style":229},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[231],{"type":78,"value":232},"export",{"type":66,"tag":156,"props":234,"children":235},{"style":229},[236],{"type":78,"value":237}," default",{"type":66,"tag":156,"props":239,"children":241},{"style":240},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[242],{"type":78,"value":243}," defineNuxtConfig",{"type":66,"tag":156,"props":245,"children":247},{"style":246},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[248],{"type":78,"value":249},"(",{"type":66,"tag":156,"props":251,"children":253},{"style":252},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[254],{"type":78,"value":255},"{\n",{"type":66,"tag":156,"props":257,"children":259},{"class":158,"line":258},2,[260,266,270,275,280,284,288,293],{"type":66,"tag":156,"props":261,"children":263},{"style":262},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[264],{"type":78,"value":265}," modules",{"type":66,"tag":156,"props":267,"children":268},{"style":252},[269],{"type":78,"value":214},{"type":66,"tag":156,"props":271,"children":272},{"style":246},[273],{"type":78,"value":274}," [",{"type":66,"tag":156,"props":276,"children":277},{"style":252},[278],{"type":78,"value":279},"'",{"type":66,"tag":156,"props":281,"children":282},{"style":169},[283],{"type":78,"value":79},{"type":66,"tag":156,"props":285,"children":286},{"style":252},[287],{"type":78,"value":279},{"type":66,"tag":156,"props":289,"children":290},{"style":246},[291],{"type":78,"value":292},"]",{"type":66,"tag":156,"props":294,"children":295},{"style":252},[296],{"type":78,"value":297},",\n",{"type":66,"tag":156,"props":299,"children":301},{"class":158,"line":300},3,[302,307],{"type":66,"tag":156,"props":303,"children":304},{"style":252},[305],{"type":78,"value":306},"}",{"type":66,"tag":156,"props":308,"children":309},{"style":246},[310],{"type":78,"value":311},")\n",{"type":66,"tag":67,"props":313,"children":314},{},[315,316,322,324,330,331,337],{"type":78,"value":136},{"type":66,"tag":138,"props":317,"children":319},{"className":318},[],[320],{"type":78,"value":321},"SUPABASE_URL",{"type":78,"value":323}," and ",{"type":66,"tag":138,"props":325,"children":327},{"className":326},[],[328],{"type":78,"value":329},"SUPABASE_KEY",{"type":78,"value":198},{"type":66,"tag":138,"props":332,"children":334},{"className":333},[],[335],{"type":78,"value":336},".env",{"type":78,"value":214},{"type":66,"tag":146,"props":339,"children":342},{"className":148,"code":340,"filename":341,"language":150,"meta":59,"style":59},"SUPABASE_URL=\"https://example.supabase.co\"\nSUPABASE_KEY=\"\u003Cyour_key>\"\n","env",[343],{"type":66,"tag":138,"props":344,"children":345},{"__ignoreMap":59},[346,373],{"type":66,"tag":156,"props":347,"children":348},{"class":158,"line":159},[349,353,358,363,368],{"type":66,"tag":156,"props":350,"children":351},{"style":246},[352],{"type":78,"value":321},{"type":66,"tag":156,"props":354,"children":355},{"style":252},[356],{"type":78,"value":357},"=",{"type":66,"tag":156,"props":359,"children":360},{"style":252},[361],{"type":78,"value":362},"\"",{"type":66,"tag":156,"props":364,"children":365},{"style":169},[366],{"type":78,"value":367},"https://example.supabase.co",{"type":66,"tag":156,"props":369,"children":370},{"style":252},[371],{"type":78,"value":372},"\"\n",{"type":66,"tag":156,"props":374,"children":375},{"class":158,"line":258},[376,380,384,388,393],{"type":66,"tag":156,"props":377,"children":378},{"style":246},[379],{"type":78,"value":329},{"type":66,"tag":156,"props":381,"children":382},{"style":252},[383],{"type":78,"value":357},{"type":66,"tag":156,"props":385,"children":386},{"style":252},[387],{"type":78,"value":362},{"type":66,"tag":156,"props":389,"children":390},{"style":169},[391],{"type":78,"value":392},"\u003Cyour_key>",{"type":66,"tag":156,"props":394,"children":395},{"style":252},[396],{"type":78,"value":372},{"type":66,"tag":106,"props":398,"children":400},{"icon":399},"i-heroicons-light-bulb",[401],{"type":66,"tag":67,"props":402,"children":403},{},[404,406,412],{"type":78,"value":405},"Alternatively, you can prefix the env variables with ",{"type":66,"tag":138,"props":407,"children":409},{"className":408},[],[410],{"type":78,"value":411},"NUXT_PUBLIC_",{"type":78,"value":413}," in order to use runtimeConfig.",{"type":66,"tag":126,"props":415,"children":417},{"id":416},"options",[418],{"type":78,"value":419},"Options",{"type":66,"tag":67,"props":421,"children":422},{},[423,425,431,433,439],{"type":78,"value":424},"You can configure the supabase module by using the ",{"type":66,"tag":138,"props":426,"children":428},{"className":427},[],[429],{"type":78,"value":430},"supabase",{"type":78,"value":432}," key in ",{"type":66,"tag":138,"props":434,"children":436},{"className":435},[],[437],{"type":78,"value":438},"nuxt.config",{"type":78,"value":214},{"type":66,"tag":146,"props":441,"children":443},{"className":217,"code":442,"filename":212,"language":219,"meta":59,"style":59},"export default defineNuxtConfig({\n // ...\n supabase: {\n // Options\n }\n}\n",[444],{"type":66,"tag":138,"props":445,"children":446},{"__ignoreMap":59},[447,470,479,496,505,514],{"type":66,"tag":156,"props":448,"children":449},{"class":158,"line":159},[450,454,458,462,466],{"type":66,"tag":156,"props":451,"children":452},{"style":229},[453],{"type":78,"value":232},{"type":66,"tag":156,"props":455,"children":456},{"style":229},[457],{"type":78,"value":237},{"type":66,"tag":156,"props":459,"children":460},{"style":240},[461],{"type":78,"value":243},{"type":66,"tag":156,"props":463,"children":464},{"style":246},[465],{"type":78,"value":249},{"type":66,"tag":156,"props":467,"children":468},{"style":252},[469],{"type":78,"value":255},{"type":66,"tag":156,"props":471,"children":472},{"class":158,"line":258},[473],{"type":66,"tag":156,"props":474,"children":476},{"style":475},"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[477],{"type":78,"value":478}," // ...\n",{"type":66,"tag":156,"props":480,"children":481},{"class":158,"line":300},[482,487,491],{"type":66,"tag":156,"props":483,"children":484},{"style":262},[485],{"type":78,"value":486}," supabase",{"type":66,"tag":156,"props":488,"children":489},{"style":252},[490],{"type":78,"value":214},{"type":66,"tag":156,"props":492,"children":493},{"style":252},[494],{"type":78,"value":495}," {\n",{"type":66,"tag":156,"props":497,"children":499},{"class":158,"line":498},4,[500],{"type":66,"tag":156,"props":501,"children":502},{"style":475},[503],{"type":78,"value":504}," // Options\n",{"type":66,"tag":156,"props":506,"children":508},{"class":158,"line":507},5,[509],{"type":66,"tag":156,"props":510,"children":511},{"style":252},[512],{"type":78,"value":513}," }\n",{"type":66,"tag":156,"props":515,"children":517},{"class":158,"line":516},6,[518],{"type":66,"tag":156,"props":519,"children":520},{"style":252},[521],{"type":78,"value":522},"}\n",{"type":66,"tag":524,"props":525,"children":527},"h3",{"id":526},"url",[528],{"type":66,"tag":138,"props":529,"children":531},{"className":530},[],[532],{"type":78,"value":526},{"type":66,"tag":67,"props":534,"children":535},{},[536,538,544,546,551],{"type":78,"value":537},"Default: ",{"type":66,"tag":138,"props":539,"children":541},{"className":540},[],[542],{"type":78,"value":543},"process.env.SUPABASE_URL",{"type":78,"value":545}," (ex: ",{"type":66,"tag":71,"props":547,"children":549},{"href":367,"rel":548},[75],[550],{"type":78,"value":367},{"type":78,"value":552},")",{"type":66,"tag":67,"props":554,"children":555},{},[556],{"type":78,"value":557},"The unique Supabase URL which is supplied when you create a new project in your project dashboard.",{"type":66,"tag":524,"props":559,"children":561},{"id":560},"key",[562],{"type":66,"tag":138,"props":563,"children":565},{"className":564},[],[566],{"type":78,"value":560},{"type":66,"tag":67,"props":568,"children":569},{},[570,571],{"type":78,"value":537},{"type":66,"tag":138,"props":572,"children":574},{"className":573},[],[575],{"type":78,"value":576},"process.env.SUPABASE_KEY",{"type":66,"tag":67,"props":578,"children":579},{},[580],{"type":78,"value":581},"Supabase 'anon key', used to bypass the Supabase API gateway and interact with your Supabase database making use of user JWT to apply RLS Policies.",{"type":66,"tag":524,"props":583,"children":585},{"id":584},"servicekey",[586],{"type":66,"tag":138,"props":587,"children":589},{"className":588},[],[590],{"type":78,"value":591},"serviceKey",{"type":66,"tag":67,"props":593,"children":594},{},[595,596],{"type":78,"value":537},{"type":66,"tag":138,"props":597,"children":599},{"className":598},[],[600],{"type":78,"value":601},"process.env.SUPABASE_SERVICE_KEY",{"type":66,"tag":67,"props":603,"children":604},{},[605],{"type":78,"value":606},"Supabase 'service role key', has super admin rights and can bypass your Row Level Security.",{"type":66,"tag":524,"props":608,"children":610},{"id":609},"redirect",[611],{"type":66,"tag":138,"props":612,"children":614},{"className":613},[],[615],{"type":78,"value":609},{"type":66,"tag":67,"props":617,"children":618},{},[619,620],{"type":78,"value":537},{"type":66,"tag":138,"props":621,"children":623},{"className":622},[],[624],{"type":78,"value":625},"true",{"type":66,"tag":67,"props":627,"children":628},{},[629],{"type":78,"value":630},"Redirect automatically to the configured login page if a non authenticated user is trying to access a guarded. You can disable all redirects by setting this option to false.",{"type":66,"tag":524,"props":632,"children":634},{"id":633},"redirectoptions",[635],{"type":66,"tag":138,"props":636,"children":638},{"className":637},[],[639],{"type":78,"value":640},"redirectOptions",{"type":66,"tag":67,"props":642,"children":643},{},[644],{"type":78,"value":645},"Default:",{"type":66,"tag":146,"props":647,"children":649},{"className":217,"code":648,"filename":212,"language":219,"meta":59,"style":59}," redirectOptions: {\n login: '/login',\n callback: '/confirm',\n include: undefined,\n exclude: [],\n cookieRedirect: false,\n }\n",[650],{"type":66,"tag":138,"props":651,"children":652},{"__ignoreMap":59},[653,669,699,728,745,766,788],{"type":66,"tag":156,"props":654,"children":655},{"class":158,"line":159},[656,661,665],{"type":66,"tag":156,"props":657,"children":658},{"style":163},[659],{"type":78,"value":660}," redirectOptions",{"type":66,"tag":156,"props":662,"children":663},{"style":252},[664],{"type":78,"value":214},{"type":66,"tag":156,"props":666,"children":667},{"style":252},[668],{"type":78,"value":495},{"type":66,"tag":156,"props":670,"children":671},{"class":158,"line":258},[672,677,681,686,691,695],{"type":66,"tag":156,"props":673,"children":674},{"style":163},[675],{"type":78,"value":676}," login",{"type":66,"tag":156,"props":678,"children":679},{"style":252},[680],{"type":78,"value":214},{"type":66,"tag":156,"props":682,"children":683},{"style":252},[684],{"type":78,"value":685}," '",{"type":66,"tag":156,"props":687,"children":688},{"style":169},[689],{"type":78,"value":690},"/login",{"type":66,"tag":156,"props":692,"children":693},{"style":252},[694],{"type":78,"value":279},{"type":66,"tag":156,"props":696,"children":697},{"style":252},[698],{"type":78,"value":297},{"type":66,"tag":156,"props":700,"children":701},{"class":158,"line":300},[702,707,711,715,720,724],{"type":66,"tag":156,"props":703,"children":704},{"style":163},[705],{"type":78,"value":706}," callback",{"type":66,"tag":156,"props":708,"children":709},{"style":252},[710],{"type":78,"value":214},{"type":66,"tag":156,"props":712,"children":713},{"style":252},[714],{"type":78,"value":685},{"type":66,"tag":156,"props":716,"children":717},{"style":169},[718],{"type":78,"value":719},"/confirm",{"type":66,"tag":156,"props":721,"children":722},{"style":252},[723],{"type":78,"value":279},{"type":66,"tag":156,"props":725,"children":726},{"style":252},[727],{"type":78,"value":297},{"type":66,"tag":156,"props":729,"children":730},{"class":158,"line":498},[731,736,740],{"type":66,"tag":156,"props":732,"children":733},{"style":163},[734],{"type":78,"value":735}," include",{"type":66,"tag":156,"props":737,"children":738},{"style":252},[739],{"type":78,"value":214},{"type":66,"tag":156,"props":741,"children":742},{"style":252},[743],{"type":78,"value":744}," undefined,\n",{"type":66,"tag":156,"props":746,"children":747},{"class":158,"line":507},[748,753,757,762],{"type":66,"tag":156,"props":749,"children":750},{"style":163},[751],{"type":78,"value":752}," exclude",{"type":66,"tag":156,"props":754,"children":755},{"style":252},[756],{"type":78,"value":214},{"type":66,"tag":156,"props":758,"children":759},{"style":262},[760],{"type":78,"value":761}," []",{"type":66,"tag":156,"props":763,"children":764},{"style":252},[765],{"type":78,"value":297},{"type":66,"tag":156,"props":767,"children":768},{"class":158,"line":516},[769,774,778,784],{"type":66,"tag":156,"props":770,"children":771},{"style":163},[772],{"type":78,"value":773}," cookieRedirect",{"type":66,"tag":156,"props":775,"children":776},{"style":252},[777],{"type":78,"value":214},{"type":66,"tag":156,"props":779,"children":781},{"style":780},"--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC",[782],{"type":78,"value":783}," false",{"type":66,"tag":156,"props":785,"children":786},{"style":252},[787],{"type":78,"value":297},{"type":66,"tag":156,"props":789,"children":791},{"class":158,"line":790},7,[792],{"type":66,"tag":156,"props":793,"children":794},{"style":252},[795],{"type":78,"value":513},{"type":66,"tag":797,"props":798,"children":799},"ul",{},[800,812,847,874,909],{"type":66,"tag":801,"props":802,"children":803},"li",{},[804,810],{"type":66,"tag":138,"props":805,"children":807},{"className":806},[],[808],{"type":78,"value":809},"login",{"type":78,"value":811},": User will be redirected to this path if not authenticated or after logout.",{"type":66,"tag":801,"props":813,"children":814},{},[815,821,823,829,831,838,840,846],{"type":66,"tag":138,"props":816,"children":818},{"className":817},[],[819],{"type":78,"value":820},"callback",{"type":78,"value":822},": This is the path the user will be redirect to after supabase login redirection. Should match configured ",{"type":66,"tag":138,"props":824,"children":826},{"className":825},[],[827],{"type":78,"value":828},"redirectTo",{"type":78,"value":830}," option of your ",{"type":66,"tag":71,"props":832,"children":835},{"href":833,"rel":834},"https://supabase.com/docs/reference/javascript/auth-signinwithoauth",[75],[836],{"type":78,"value":837},"signIn method",{"type":78,"value":839},". Should also be configured in your Supabase dashboard under ",{"type":66,"tag":138,"props":841,"children":843},{"className":842},[],[844],{"type":78,"value":845},"Authentication -> URL Configuration -> Redirect URLs",{"type":78,"value":124},{"type":66,"tag":801,"props":848,"children":849},{},[850,856,858,864,866,872],{"type":66,"tag":138,"props":851,"children":853},{"className":852},[],[854],{"type":78,"value":855},"include",{"type":78,"value":857},": Routes to include in the redirect. ",{"type":66,"tag":138,"props":859,"children":861},{"className":860},[],[862],{"type":78,"value":863},"['/admin(/*)?']",{"type":78,"value":865}," will enable the redirect only for the ",{"type":66,"tag":138,"props":867,"children":869},{"className":868},[],[870],{"type":78,"value":871},"admin",{"type":78,"value":873}," page and all sub-pages.",{"type":66,"tag":801,"props":875,"children":876},{},[877,883,885,891,893,899,901,907],{"type":66,"tag":138,"props":878,"children":880},{"className":879},[],[881],{"type":78,"value":882},"exclude",{"type":78,"value":884},": Routes to exclude from the redirect. ",{"type":66,"tag":138,"props":886,"children":888},{"className":887},[],[889],{"type":78,"value":890},"['/foo', '/bar/*']",{"type":78,"value":892}," will exclude the ",{"type":66,"tag":138,"props":894,"children":896},{"className":895},[],[897],{"type":78,"value":898},"foo",{"type":78,"value":900}," page and all pages in your ",{"type":66,"tag":138,"props":902,"children":904},{"className":903},[],[905],{"type":78,"value":906},"bar",{"type":78,"value":908}," folder.",{"type":66,"tag":801,"props":910,"children":911},{},[912,918,920,930],{"type":66,"tag":138,"props":913,"children":915},{"className":914},[],[916],{"type":78,"value":917},"cookieRedirect",{"type":78,"value":919},": Sets a cookie containing the path an unauthenticated user tried to access. The cookie can then be used on the ",{"type":66,"tag":71,"props":921,"children":924},{"href":922,"rel":923},"https://supabase.nuxtjs.org/authentication#confirm-page-confirm",[75],[925],{"type":66,"tag":138,"props":926,"children":928},{"className":927},[],[929],{"type":78,"value":719},{"type":78,"value":931}," page to redirect the user to the page they previously tried to visit.",{"type":66,"tag":524,"props":933,"children":935},{"id":934},"cookiename",[936],{"type":66,"tag":138,"props":937,"children":939},{"className":938},[],[940],{"type":78,"value":941},"cookieName",{"type":66,"tag":67,"props":943,"children":944},{},[945,946],{"type":78,"value":537},{"type":66,"tag":138,"props":947,"children":949},{"className":948},[],[950],{"type":78,"value":951},"sb",{"type":66,"tag":67,"props":953,"children":954},{},[955,957,962,964,970,972],{"type":78,"value":956},"Cookie name used for storing the redirect path when using the ",{"type":66,"tag":138,"props":958,"children":960},{"className":959},[],[961],{"type":78,"value":609},{"type":78,"value":963}," option, added in front of ",{"type":66,"tag":138,"props":965,"children":967},{"className":966},[],[968],{"type":78,"value":969},"-redirect-path",{"type":78,"value":971}," to form the full cookie name e.g. ",{"type":66,"tag":138,"props":973,"children":975},{"className":974},[],[976],{"type":78,"value":977},"sb-redirect-path",{"type":66,"tag":524,"props":979,"children":981},{"id":980},"cookieoptions",[982],{"type":66,"tag":138,"props":983,"children":985},{"className":984},[],[986],{"type":78,"value":987},"cookieOptions",{"type":66,"tag":146,"props":989,"children":991},{"className":217,"code":990,"language":219,"meta":59,"style":59}," cookieOptions: {\n maxAge: 60 * 60 * 8,\n sameSite: 'lax',\n secure: true\n }\n",[992],{"type":66,"tag":138,"props":993,"children":994},{"__ignoreMap":59},[995,1011,1051,1080,1097],{"type":66,"tag":156,"props":996,"children":997},{"class":158,"line":159},[998,1003,1007],{"type":66,"tag":156,"props":999,"children":1000},{"style":163},[1001],{"type":78,"value":1002}," cookieOptions",{"type":66,"tag":156,"props":1004,"children":1005},{"style":252},[1006],{"type":78,"value":214},{"type":66,"tag":156,"props":1008,"children":1009},{"style":252},[1010],{"type":78,"value":495},{"type":66,"tag":156,"props":1012,"children":1013},{"class":158,"line":258},[1014,1019,1023,1029,1034,1038,1042,1047],{"type":66,"tag":156,"props":1015,"children":1016},{"style":163},[1017],{"type":78,"value":1018}," maxAge",{"type":66,"tag":156,"props":1020,"children":1021},{"style":252},[1022],{"type":78,"value":214},{"type":66,"tag":156,"props":1024,"children":1026},{"style":1025},"--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C",[1027],{"type":78,"value":1028}," 60",{"type":66,"tag":156,"props":1030,"children":1031},{"style":252},[1032],{"type":78,"value":1033}," *",{"type":66,"tag":156,"props":1035,"children":1036},{"style":1025},[1037],{"type":78,"value":1028},{"type":66,"tag":156,"props":1039,"children":1040},{"style":252},[1041],{"type":78,"value":1033},{"type":66,"tag":156,"props":1043,"children":1044},{"style":1025},[1045],{"type":78,"value":1046}," 8",{"type":66,"tag":156,"props":1048,"children":1049},{"style":252},[1050],{"type":78,"value":297},{"type":66,"tag":156,"props":1052,"children":1053},{"class":158,"line":300},[1054,1059,1063,1067,1072,1076],{"type":66,"tag":156,"props":1055,"children":1056},{"style":163},[1057],{"type":78,"value":1058}," sameSite",{"type":66,"tag":156,"props":1060,"children":1061},{"style":252},[1062],{"type":78,"value":214},{"type":66,"tag":156,"props":1064,"children":1065},{"style":252},[1066],{"type":78,"value":685},{"type":66,"tag":156,"props":1068,"children":1069},{"style":169},[1070],{"type":78,"value":1071},"lax",{"type":66,"tag":156,"props":1073,"children":1074},{"style":252},[1075],{"type":78,"value":279},{"type":66,"tag":156,"props":1077,"children":1078},{"style":252},[1079],{"type":78,"value":297},{"type":66,"tag":156,"props":1081,"children":1082},{"class":158,"line":498},[1083,1088,1092],{"type":66,"tag":156,"props":1084,"children":1085},{"style":163},[1086],{"type":78,"value":1087}," secure",{"type":66,"tag":156,"props":1089,"children":1090},{"style":252},[1091],{"type":78,"value":214},{"type":66,"tag":156,"props":1093,"children":1094},{"style":780},[1095],{"type":78,"value":1096}," true\n",{"type":66,"tag":156,"props":1098,"children":1099},{"class":158,"line":507},[1100],{"type":66,"tag":156,"props":1101,"children":1102},{"style":252},[1103],{"type":78,"value":513},{"type":66,"tag":67,"props":1105,"children":1106},{},[1107,1109,1115],{"type":78,"value":1108},"Options for cookies used to share tokens between server and client, refer to ",{"type":66,"tag":71,"props":1110,"children":1113},{"href":1111,"rel":1112},"https://nuxt.com/docs/api/composables/use-cookie#options",[75],[1114],{"type":78,"value":987},{"type":78,"value":1116}," for available settings. Please note that the lifetime set here does not determine the Supabase session lifetime.",{"type":66,"tag":524,"props":1118,"children":1120},{"id":1119},"types",[1121],{"type":66,"tag":138,"props":1122,"children":1124},{"className":1123},[],[1125],{"type":78,"value":1119},{"type":66,"tag":67,"props":1127,"children":1128},{},[1129,1130],{"type":78,"value":537},{"type":66,"tag":138,"props":1131,"children":1133},{"className":1132},[],[1134],{"type":78,"value":1135},"./types/database.types.ts",{"type":66,"tag":67,"props":1137,"children":1138},{},[1139,1141,1146,1148,1153,1154,1159],{"type":78,"value":1140},"The path for the generated Supabase TypeScript definitions. The database definitions will be automatically passed to all clients: ",{"type":66,"tag":138,"props":1142,"children":1144},{"className":1143},[],[1145],{"type":78,"value":21},{"type":78,"value":1147},", ",{"type":66,"tag":138,"props":1149,"children":1151},{"className":1150},[],[1152],{"type":78,"value":34},{"type":78,"value":323},{"type":66,"tag":138,"props":1155,"children":1157},{"className":1156},[],[1158],{"type":78,"value":37},{"type":78,"value":124},{"type":66,"tag":146,"props":1161,"children":1163},{"className":148,"code":1162,"language":150,"meta":59,"style":59},"## Generate types from live database\nsupabase gen types --lang=typescript --project-id YourProjectId > types/database.types.ts\n\n## Generate types when using local environment\nsupabase gen types --lang=typescript --local > types/database.types.ts\n",[1164],{"type":66,"tag":138,"props":1165,"children":1166},{"__ignoreMap":59},[1167,1175,1217,1226,1234],{"type":66,"tag":156,"props":1168,"children":1169},{"class":158,"line":159},[1170],{"type":66,"tag":156,"props":1171,"children":1172},{"style":475},[1173],{"type":78,"value":1174},"## Generate types from live database\n",{"type":66,"tag":156,"props":1176,"children":1177},{"class":158,"line":258},[1178,1182,1187,1192,1197,1202,1207,1212],{"type":66,"tag":156,"props":1179,"children":1180},{"style":163},[1181],{"type":78,"value":430},{"type":66,"tag":156,"props":1183,"children":1184},{"style":169},[1185],{"type":78,"value":1186}," gen",{"type":66,"tag":156,"props":1188,"children":1189},{"style":169},[1190],{"type":78,"value":1191}," types",{"type":66,"tag":156,"props":1193,"children":1194},{"style":169},[1195],{"type":78,"value":1196}," --lang=typescript",{"type":66,"tag":156,"props":1198,"children":1199},{"style":169},[1200],{"type":78,"value":1201}," --project-id",{"type":66,"tag":156,"props":1203,"children":1204},{"style":169},[1205],{"type":78,"value":1206}," YourProjectId",{"type":66,"tag":156,"props":1208,"children":1209},{"style":252},[1210],{"type":78,"value":1211}," >",{"type":66,"tag":156,"props":1213,"children":1214},{"style":169},[1215],{"type":78,"value":1216}," types/database.types.ts\n",{"type":66,"tag":156,"props":1218,"children":1219},{"class":158,"line":300},[1220],{"type":66,"tag":156,"props":1221,"children":1223},{"emptyLinePlaceholder":1222},true,[1224],{"type":78,"value":1225},"\n",{"type":66,"tag":156,"props":1227,"children":1228},{"class":158,"line":498},[1229],{"type":66,"tag":156,"props":1230,"children":1231},{"style":475},[1232],{"type":78,"value":1233},"## Generate types when using local environment\n",{"type":66,"tag":156,"props":1235,"children":1236},{"class":158,"line":507},[1237,1241,1245,1249,1253,1258,1262],{"type":66,"tag":156,"props":1238,"children":1239},{"style":163},[1240],{"type":78,"value":430},{"type":66,"tag":156,"props":1242,"children":1243},{"style":169},[1244],{"type":78,"value":1186},{"type":66,"tag":156,"props":1246,"children":1247},{"style":169},[1248],{"type":78,"value":1191},{"type":66,"tag":156,"props":1250,"children":1251},{"style":169},[1252],{"type":78,"value":1196},{"type":66,"tag":156,"props":1254,"children":1255},{"style":169},[1256],{"type":78,"value":1257}," --local",{"type":66,"tag":156,"props":1259,"children":1260},{"style":252},[1261],{"type":78,"value":1211},{"type":66,"tag":156,"props":1263,"children":1264},{"style":169},[1265],{"type":78,"value":1216},{"type":66,"tag":67,"props":1267,"children":1268},{},[1269,1271,1277],{"type":78,"value":1270},"Set to ",{"type":66,"tag":138,"props":1272,"children":1274},{"className":1273},[],[1275],{"type":78,"value":1276},"false",{"type":78,"value":1278}," to disable.",{"type":66,"tag":67,"props":1280,"children":1281},{},[1282,1284,1291],{"type":78,"value":1283},"Check Supabase ",{"type":66,"tag":71,"props":1285,"children":1288},{"href":1286,"rel":1287},"https://supabase.com/docs/reference/javascript/release-notes#typescript-support",[75],[1289],{"type":78,"value":1290},"documentation",{"type":78,"value":1292}," for further information.",{"type":66,"tag":524,"props":1294,"children":1296},{"id":1295},"clientoptions",[1297],{"type":66,"tag":138,"props":1298,"children":1300},{"className":1299},[],[1301],{"type":78,"value":1302},"clientOptions",{"type":66,"tag":67,"props":1304,"children":1305},{},[1306],{"type":78,"value":645},{"type":66,"tag":146,"props":1308,"children":1310},{"className":217,"code":1309,"language":219,"meta":59,"style":59}," clientOptions: { }\n",[1311],{"type":66,"tag":138,"props":1312,"children":1313},{"__ignoreMap":59},[1314],{"type":66,"tag":156,"props":1315,"children":1316},{"class":158,"line":159},[1317,1322,1326,1331],{"type":66,"tag":156,"props":1318,"children":1319},{"style":163},[1320],{"type":78,"value":1321}," clientOptions",{"type":66,"tag":156,"props":1323,"children":1324},{"style":252},[1325],{"type":78,"value":214},{"type":66,"tag":156,"props":1327,"children":1328},{"style":252},[1329],{"type":78,"value":1330}," {",{"type":66,"tag":156,"props":1332,"children":1333},{"style":252},[1334],{"type":78,"value":1335}," }\n",{"type":66,"tag":67,"props":1337,"children":1338},{},[1339,1341,1348,1350,1356],{"type":78,"value":1340},"Supabase client options ",{"type":66,"tag":71,"props":1342,"children":1345},{"href":1343,"rel":1344},"https://supabase.com/docs/reference/javascript/initializing#parameters",[75],[1346],{"type":78,"value":1347},"available here",{"type":78,"value":1349}," merged with default values from ",{"type":66,"tag":138,"props":1351,"children":1353},{"className":1352},[],[1354],{"type":78,"value":1355},"@supabase/ssr",{"type":78,"value":214},{"type":66,"tag":146,"props":1358,"children":1360},{"className":217,"code":1359,"language":219,"meta":59,"style":59}," clientOptions: {\n auth: {\n flowType: 'pkce',\n autoRefreshToken: isBrowser(),\n detectSessionInUrl: isBrowser(),\n persistSession: true,\n },\n }\n",[1361],{"type":66,"tag":138,"props":1362,"children":1363},{"__ignoreMap":59},[1364,1379,1395,1424,1450,1474,1495,1503],{"type":66,"tag":156,"props":1365,"children":1366},{"class":158,"line":159},[1367,1371,1375],{"type":66,"tag":156,"props":1368,"children":1369},{"style":163},[1370],{"type":78,"value":1321},{"type":66,"tag":156,"props":1372,"children":1373},{"style":252},[1374],{"type":78,"value":214},{"type":66,"tag":156,"props":1376,"children":1377},{"style":252},[1378],{"type":78,"value":495},{"type":66,"tag":156,"props":1380,"children":1381},{"class":158,"line":258},[1382,1387,1391],{"type":66,"tag":156,"props":1383,"children":1384},{"style":163},[1385],{"type":78,"value":1386}," auth",{"type":66,"tag":156,"props":1388,"children":1389},{"style":252},[1390],{"type":78,"value":214},{"type":66,"tag":156,"props":1392,"children":1393},{"style":252},[1394],{"type":78,"value":495},{"type":66,"tag":156,"props":1396,"children":1397},{"class":158,"line":300},[1398,1403,1407,1411,1416,1420],{"type":66,"tag":156,"props":1399,"children":1400},{"style":163},[1401],{"type":78,"value":1402}," flowType",{"type":66,"tag":156,"props":1404,"children":1405},{"style":252},[1406],{"type":78,"value":214},{"type":66,"tag":156,"props":1408,"children":1409},{"style":252},[1410],{"type":78,"value":685},{"type":66,"tag":156,"props":1412,"children":1413},{"style":169},[1414],{"type":78,"value":1415},"pkce",{"type":66,"tag":156,"props":1417,"children":1418},{"style":252},[1419],{"type":78,"value":279},{"type":66,"tag":156,"props":1421,"children":1422},{"style":252},[1423],{"type":78,"value":297},{"type":66,"tag":156,"props":1425,"children":1426},{"class":158,"line":498},[1427,1432,1436,1441,1446],{"type":66,"tag":156,"props":1428,"children":1429},{"style":163},[1430],{"type":78,"value":1431}," autoRefreshToken",{"type":66,"tag":156,"props":1433,"children":1434},{"style":252},[1435],{"type":78,"value":214},{"type":66,"tag":156,"props":1437,"children":1438},{"style":240},[1439],{"type":78,"value":1440}," isBrowser",{"type":66,"tag":156,"props":1442,"children":1443},{"style":262},[1444],{"type":78,"value":1445},"()",{"type":66,"tag":156,"props":1447,"children":1448},{"style":252},[1449],{"type":78,"value":297},{"type":66,"tag":156,"props":1451,"children":1452},{"class":158,"line":507},[1453,1458,1462,1466,1470],{"type":66,"tag":156,"props":1454,"children":1455},{"style":163},[1456],{"type":78,"value":1457}," detectSessionInUrl",{"type":66,"tag":156,"props":1459,"children":1460},{"style":252},[1461],{"type":78,"value":214},{"type":66,"tag":156,"props":1463,"children":1464},{"style":240},[1465],{"type":78,"value":1440},{"type":66,"tag":156,"props":1467,"children":1468},{"style":262},[1469],{"type":78,"value":1445},{"type":66,"tag":156,"props":1471,"children":1472},{"style":252},[1473],{"type":78,"value":297},{"type":66,"tag":156,"props":1475,"children":1476},{"class":158,"line":516},[1477,1482,1486,1491],{"type":66,"tag":156,"props":1478,"children":1479},{"style":163},[1480],{"type":78,"value":1481}," persistSession",{"type":66,"tag":156,"props":1483,"children":1484},{"style":252},[1485],{"type":78,"value":214},{"type":66,"tag":156,"props":1487,"children":1488},{"style":780},[1489],{"type":78,"value":1490}," true",{"type":66,"tag":156,"props":1492,"children":1493},{"style":252},[1494],{"type":78,"value":297},{"type":66,"tag":156,"props":1496,"children":1497},{"class":158,"line":790},[1498],{"type":66,"tag":156,"props":1499,"children":1500},{"style":252},[1501],{"type":78,"value":1502}," },\n",{"type":66,"tag":156,"props":1504,"children":1506},{"class":158,"line":1505},8,[1507],{"type":66,"tag":156,"props":1508,"children":1509},{"style":252},[1510],{"type":78,"value":513},{"type":66,"tag":126,"props":1512,"children":1514},{"id":1513},"demo",[1515],{"type":78,"value":47},{"type":66,"tag":67,"props":1517,"children":1518},{},[1519,1521,1528,1530,1535],{"type":78,"value":1520},"A live demo is made for see this module in action on ",{"type":66,"tag":71,"props":1522,"children":1525},{"href":1523,"rel":1524},"https://n3-supabase.netlify.app",[75],[1526],{"type":78,"value":1527},"n3-supabase.netlify.app",{"type":78,"value":1529},", read more in the ",{"type":66,"tag":71,"props":1531,"children":1532},{"href":48},[1533],{"type":78,"value":1534},"demo section",{"type":78,"value":124},{"type":66,"tag":67,"props":1537,"children":1538},{},[1539],{"type":66,"tag":71,"props":1540,"children":1542},{"href":1523,"rel":1541},[75],[1543],{"type":66,"tag":1544,"props":1545,"children":1548},"img",{"alt":1546,"src":1547},"Supabase demo with Nuxt 3","https://user-images.githubusercontent.com/904724/160422461-8f87500a-8dec-4413-86b2-ba04e1b2d17b.png",[],{"type":66,"tag":67,"props":1550,"children":1551},{},[1552,1554,1561],{"type":78,"value":1553},"Also checkout the ",{"type":66,"tag":71,"props":1555,"children":1558},{"href":1556,"rel":1557},"https://www.youtube.com/watch?v=jIyiRT6zT8Q",[75],[1559],{"type":78,"value":1560},"YouTube video",{"type":78,"value":1562}," about its usage in a live demo.",{"type":66,"tag":1564,"props":1565,"children":1566},"style",{},[1567],{"type":78,"value":1568},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":59,"searchDepth":258,"depth":258,"links":1570},[1571,1572,1583],{"id":128,"depth":258,"text":131},{"id":416,"depth":258,"text":419,"children":1573},[1574,1575,1576,1577,1578,1579,1580,1581,1582],{"id":526,"depth":300,"text":526},{"id":560,"depth":300,"text":560},{"id":584,"depth":300,"text":591},{"id":609,"depth":300,"text":609},{"id":633,"depth":300,"text":640},{"id":934,"depth":300,"text":941},{"id":980,"depth":300,"text":987},{"id":1119,"depth":300,"text":1119},{"id":1295,"depth":300,"text":1302},{"id":1513,"depth":258,"text":47},"markdown","content:2.get-started.md","content","2.get-started.md","2.get-started","md",[1591,1592],null,{"_path":10,"title":9,"description":1593},"Authenticate your user thanks to the PKCE Oauth protocol that enables secure exchange of refresh and access tokens between an application and the authorization server",1724940862186] \ No newline at end of file +[{"data":1,"prerenderedAt":1594},["ShallowReactive",2],{"navigation":3,"/get-started":58,"/get-started-surround":1590},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":6,"_dir":59,"_draft":60,"_partial":60,"_locale":59,"title":5,"description":61,"icon":7,"body":62,"_type":1584,"_id":1585,"_source":1586,"_file":1587,"_stem":1588,"_extension":1589},"",false,"@nuxtjs/supabase is a Nuxt module for first class integration with Supabase.",{"type":63,"children":64,"toc":1569},"root",[65,82,105,125,132,145,188,215,312,338,397,414,420,440,523,533,553,558,567,577,582,592,602,607,616,626,631,641,646,796,932,942,952,978,988,1104,1117,1126,1136,1160,1266,1279,1293,1303,1307,1336,1357,1511,1516,1536,1549,1563],{"type":66,"tag":67,"props":68,"children":69},"element","p",{},[70,80],{"type":66,"tag":71,"props":72,"children":76},"a",{"href":73,"rel":74},"https://github.com/nuxt-modules/supabase",[75],"nofollow",[77],{"type":78,"value":79},"text","@nuxtjs/supabase",{"type":78,"value":81}," is a Nuxt module for first class integration with Supabase.",{"type":66,"tag":67,"props":83,"children":84},{},[85,87,94,96,103],{"type":78,"value":86},"Checkout the ",{"type":66,"tag":71,"props":88,"children":91},{"href":89,"rel":90},"https://v3.nuxtjs.org",[75],[92],{"type":78,"value":93},"Nuxt 3",{"type":78,"value":95}," documentation and ",{"type":66,"tag":71,"props":97,"children":100},{"href":98,"rel":99},"https://supabase.com",[75],[101],{"type":78,"value":102},"Supabase",{"type":78,"value":104}," to learn more.",{"type":66,"tag":106,"props":107,"children":110},"callout",{"icon":108,"color":109},"i-heroicons-exclamation-triangle-20-solid","amber",[111],{"type":66,"tag":67,"props":112,"children":113},{},[114,116,123],{"type":78,"value":115},"For integrating Supabase with Nuxt 2, checkout ",{"type":66,"tag":71,"props":117,"children":120},{"href":118,"rel":119},"https://github.com/supabase-community/nuxt-supabase",[75],[121],{"type":78,"value":122},"supabase-community/nuxt-supabase",{"type":78,"value":124},".",{"type":66,"tag":126,"props":127,"children":129},"h2",{"id":128},"installation",[130],{"type":78,"value":131},"Installation",{"type":66,"tag":67,"props":133,"children":134},{},[135,137,143],{"type":78,"value":136},"Add ",{"type":66,"tag":138,"props":139,"children":141},"code",{"className":140},[],[142],{"type":78,"value":79},{"type":78,"value":144}," dev dependency to your project:",{"type":66,"tag":146,"props":147,"children":151},"pre",{"className":148,"code":149,"language":150,"meta":59,"style":59},"language-bash shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","npx nuxi@latest module add supabase\n","bash",[152],{"type":66,"tag":138,"props":153,"children":154},{"__ignoreMap":59},[155],{"type":66,"tag":156,"props":157,"children":160},"span",{"class":158,"line":159},"line",1,[161,167,173,178,183],{"type":66,"tag":156,"props":162,"children":164},{"style":163},"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B",[165],{"type":78,"value":166},"npx",{"type":66,"tag":156,"props":168,"children":170},{"style":169},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[171],{"type":78,"value":172}," nuxi@latest",{"type":66,"tag":156,"props":174,"children":175},{"style":169},[176],{"type":78,"value":177}," module",{"type":66,"tag":156,"props":179,"children":180},{"style":169},[181],{"type":78,"value":182}," add",{"type":66,"tag":156,"props":184,"children":185},{"style":169},[186],{"type":78,"value":187}," supabase\n",{"type":66,"tag":67,"props":189,"children":190},{},[191,192,197,199,205,207,213],{"type":78,"value":136},{"type":66,"tag":138,"props":193,"children":195},{"className":194},[],[196],{"type":78,"value":79},{"type":78,"value":198}," to the ",{"type":66,"tag":138,"props":200,"children":202},{"className":201},[],[203],{"type":78,"value":204},"modules",{"type":78,"value":206}," section of ",{"type":66,"tag":138,"props":208,"children":210},{"className":209},[],[211],{"type":78,"value":212},"nuxt.config.ts",{"type":78,"value":214},":",{"type":66,"tag":146,"props":216,"children":220},{"className":217,"code":218,"filename":212,"language":219,"meta":59,"style":59},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","export default defineNuxtConfig({\n modules: ['@nuxtjs/supabase'],\n})\n","ts",[221],{"type":66,"tag":138,"props":222,"children":223},{"__ignoreMap":59},[224,256,298],{"type":66,"tag":156,"props":225,"children":226},{"class":158,"line":159},[227,233,238,244,250],{"type":66,"tag":156,"props":228,"children":230},{"style":229},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[231],{"type":78,"value":232},"export",{"type":66,"tag":156,"props":234,"children":235},{"style":229},[236],{"type":78,"value":237}," default",{"type":66,"tag":156,"props":239,"children":241},{"style":240},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[242],{"type":78,"value":243}," defineNuxtConfig",{"type":66,"tag":156,"props":245,"children":247},{"style":246},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[248],{"type":78,"value":249},"(",{"type":66,"tag":156,"props":251,"children":253},{"style":252},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[254],{"type":78,"value":255},"{\n",{"type":66,"tag":156,"props":257,"children":259},{"class":158,"line":258},2,[260,266,270,275,280,284,288,293],{"type":66,"tag":156,"props":261,"children":263},{"style":262},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[264],{"type":78,"value":265}," modules",{"type":66,"tag":156,"props":267,"children":268},{"style":252},[269],{"type":78,"value":214},{"type":66,"tag":156,"props":271,"children":272},{"style":246},[273],{"type":78,"value":274}," [",{"type":66,"tag":156,"props":276,"children":277},{"style":252},[278],{"type":78,"value":279},"'",{"type":66,"tag":156,"props":281,"children":282},{"style":169},[283],{"type":78,"value":79},{"type":66,"tag":156,"props":285,"children":286},{"style":252},[287],{"type":78,"value":279},{"type":66,"tag":156,"props":289,"children":290},{"style":246},[291],{"type":78,"value":292},"]",{"type":66,"tag":156,"props":294,"children":295},{"style":252},[296],{"type":78,"value":297},",\n",{"type":66,"tag":156,"props":299,"children":301},{"class":158,"line":300},3,[302,307],{"type":66,"tag":156,"props":303,"children":304},{"style":252},[305],{"type":78,"value":306},"}",{"type":66,"tag":156,"props":308,"children":309},{"style":246},[310],{"type":78,"value":311},")\n",{"type":66,"tag":67,"props":313,"children":314},{},[315,316,322,324,330,331,337],{"type":78,"value":136},{"type":66,"tag":138,"props":317,"children":319},{"className":318},[],[320],{"type":78,"value":321},"SUPABASE_URL",{"type":78,"value":323}," and ",{"type":66,"tag":138,"props":325,"children":327},{"className":326},[],[328],{"type":78,"value":329},"SUPABASE_KEY",{"type":78,"value":198},{"type":66,"tag":138,"props":332,"children":334},{"className":333},[],[335],{"type":78,"value":336},".env",{"type":78,"value":214},{"type":66,"tag":146,"props":339,"children":342},{"className":148,"code":340,"filename":341,"language":150,"meta":59,"style":59},"SUPABASE_URL=\"https://example.supabase.co\"\nSUPABASE_KEY=\"\u003Cyour_key>\"\n","env",[343],{"type":66,"tag":138,"props":344,"children":345},{"__ignoreMap":59},[346,373],{"type":66,"tag":156,"props":347,"children":348},{"class":158,"line":159},[349,353,358,363,368],{"type":66,"tag":156,"props":350,"children":351},{"style":246},[352],{"type":78,"value":321},{"type":66,"tag":156,"props":354,"children":355},{"style":252},[356],{"type":78,"value":357},"=",{"type":66,"tag":156,"props":359,"children":360},{"style":252},[361],{"type":78,"value":362},"\"",{"type":66,"tag":156,"props":364,"children":365},{"style":169},[366],{"type":78,"value":367},"https://example.supabase.co",{"type":66,"tag":156,"props":369,"children":370},{"style":252},[371],{"type":78,"value":372},"\"\n",{"type":66,"tag":156,"props":374,"children":375},{"class":158,"line":258},[376,380,384,388,393],{"type":66,"tag":156,"props":377,"children":378},{"style":246},[379],{"type":78,"value":329},{"type":66,"tag":156,"props":381,"children":382},{"style":252},[383],{"type":78,"value":357},{"type":66,"tag":156,"props":385,"children":386},{"style":252},[387],{"type":78,"value":362},{"type":66,"tag":156,"props":389,"children":390},{"style":169},[391],{"type":78,"value":392},"\u003Cyour_key>",{"type":66,"tag":156,"props":394,"children":395},{"style":252},[396],{"type":78,"value":372},{"type":66,"tag":106,"props":398,"children":400},{"icon":399},"i-heroicons-light-bulb",[401],{"type":66,"tag":67,"props":402,"children":403},{},[404,406,412],{"type":78,"value":405},"Alternatively, you can prefix the env variables with ",{"type":66,"tag":138,"props":407,"children":409},{"className":408},[],[410],{"type":78,"value":411},"NUXT_PUBLIC_",{"type":78,"value":413}," in order to use runtimeConfig.",{"type":66,"tag":126,"props":415,"children":417},{"id":416},"options",[418],{"type":78,"value":419},"Options",{"type":66,"tag":67,"props":421,"children":422},{},[423,425,431,433,439],{"type":78,"value":424},"You can configure the supabase module by using the ",{"type":66,"tag":138,"props":426,"children":428},{"className":427},[],[429],{"type":78,"value":430},"supabase",{"type":78,"value":432}," key in ",{"type":66,"tag":138,"props":434,"children":436},{"className":435},[],[437],{"type":78,"value":438},"nuxt.config",{"type":78,"value":214},{"type":66,"tag":146,"props":441,"children":443},{"className":217,"code":442,"filename":212,"language":219,"meta":59,"style":59},"export default defineNuxtConfig({\n // ...\n supabase: {\n // Options\n }\n}\n",[444],{"type":66,"tag":138,"props":445,"children":446},{"__ignoreMap":59},[447,470,479,496,505,514],{"type":66,"tag":156,"props":448,"children":449},{"class":158,"line":159},[450,454,458,462,466],{"type":66,"tag":156,"props":451,"children":452},{"style":229},[453],{"type":78,"value":232},{"type":66,"tag":156,"props":455,"children":456},{"style":229},[457],{"type":78,"value":237},{"type":66,"tag":156,"props":459,"children":460},{"style":240},[461],{"type":78,"value":243},{"type":66,"tag":156,"props":463,"children":464},{"style":246},[465],{"type":78,"value":249},{"type":66,"tag":156,"props":467,"children":468},{"style":252},[469],{"type":78,"value":255},{"type":66,"tag":156,"props":471,"children":472},{"class":158,"line":258},[473],{"type":66,"tag":156,"props":474,"children":476},{"style":475},"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[477],{"type":78,"value":478}," // ...\n",{"type":66,"tag":156,"props":480,"children":481},{"class":158,"line":300},[482,487,491],{"type":66,"tag":156,"props":483,"children":484},{"style":262},[485],{"type":78,"value":486}," supabase",{"type":66,"tag":156,"props":488,"children":489},{"style":252},[490],{"type":78,"value":214},{"type":66,"tag":156,"props":492,"children":493},{"style":252},[494],{"type":78,"value":495}," {\n",{"type":66,"tag":156,"props":497,"children":499},{"class":158,"line":498},4,[500],{"type":66,"tag":156,"props":501,"children":502},{"style":475},[503],{"type":78,"value":504}," // Options\n",{"type":66,"tag":156,"props":506,"children":508},{"class":158,"line":507},5,[509],{"type":66,"tag":156,"props":510,"children":511},{"style":252},[512],{"type":78,"value":513}," }\n",{"type":66,"tag":156,"props":515,"children":517},{"class":158,"line":516},6,[518],{"type":66,"tag":156,"props":519,"children":520},{"style":252},[521],{"type":78,"value":522},"}\n",{"type":66,"tag":524,"props":525,"children":527},"h3",{"id":526},"url",[528],{"type":66,"tag":138,"props":529,"children":531},{"className":530},[],[532],{"type":78,"value":526},{"type":66,"tag":67,"props":534,"children":535},{},[536,538,544,546,551],{"type":78,"value":537},"Default: ",{"type":66,"tag":138,"props":539,"children":541},{"className":540},[],[542],{"type":78,"value":543},"process.env.SUPABASE_URL",{"type":78,"value":545}," (ex: ",{"type":66,"tag":71,"props":547,"children":549},{"href":367,"rel":548},[75],[550],{"type":78,"value":367},{"type":78,"value":552},")",{"type":66,"tag":67,"props":554,"children":555},{},[556],{"type":78,"value":557},"The unique Supabase URL which is supplied when you create a new project in your project dashboard.",{"type":66,"tag":524,"props":559,"children":561},{"id":560},"key",[562],{"type":66,"tag":138,"props":563,"children":565},{"className":564},[],[566],{"type":78,"value":560},{"type":66,"tag":67,"props":568,"children":569},{},[570,571],{"type":78,"value":537},{"type":66,"tag":138,"props":572,"children":574},{"className":573},[],[575],{"type":78,"value":576},"process.env.SUPABASE_KEY",{"type":66,"tag":67,"props":578,"children":579},{},[580],{"type":78,"value":581},"Supabase 'anon key', used to bypass the Supabase API gateway and interact with your Supabase database making use of user JWT to apply RLS Policies.",{"type":66,"tag":524,"props":583,"children":585},{"id":584},"servicekey",[586],{"type":66,"tag":138,"props":587,"children":589},{"className":588},[],[590],{"type":78,"value":591},"serviceKey",{"type":66,"tag":67,"props":593,"children":594},{},[595,596],{"type":78,"value":537},{"type":66,"tag":138,"props":597,"children":599},{"className":598},[],[600],{"type":78,"value":601},"process.env.SUPABASE_SERVICE_KEY",{"type":66,"tag":67,"props":603,"children":604},{},[605],{"type":78,"value":606},"Supabase 'service role key', has super admin rights and can bypass your Row Level Security.",{"type":66,"tag":524,"props":608,"children":610},{"id":609},"redirect",[611],{"type":66,"tag":138,"props":612,"children":614},{"className":613},[],[615],{"type":78,"value":609},{"type":66,"tag":67,"props":617,"children":618},{},[619,620],{"type":78,"value":537},{"type":66,"tag":138,"props":621,"children":623},{"className":622},[],[624],{"type":78,"value":625},"true",{"type":66,"tag":67,"props":627,"children":628},{},[629],{"type":78,"value":630},"Redirect automatically to the configured login page if a non authenticated user is trying to access a guarded. You can disable all redirects by setting this option to false.",{"type":66,"tag":524,"props":632,"children":634},{"id":633},"redirectoptions",[635],{"type":66,"tag":138,"props":636,"children":638},{"className":637},[],[639],{"type":78,"value":640},"redirectOptions",{"type":66,"tag":67,"props":642,"children":643},{},[644],{"type":78,"value":645},"Default:",{"type":66,"tag":146,"props":647,"children":649},{"className":217,"code":648,"filename":212,"language":219,"meta":59,"style":59}," redirectOptions: {\n login: '/login',\n callback: '/confirm',\n include: undefined,\n exclude: [],\n cookieRedirect: false,\n }\n",[650],{"type":66,"tag":138,"props":651,"children":652},{"__ignoreMap":59},[653,669,699,728,745,766,788],{"type":66,"tag":156,"props":654,"children":655},{"class":158,"line":159},[656,661,665],{"type":66,"tag":156,"props":657,"children":658},{"style":163},[659],{"type":78,"value":660}," redirectOptions",{"type":66,"tag":156,"props":662,"children":663},{"style":252},[664],{"type":78,"value":214},{"type":66,"tag":156,"props":666,"children":667},{"style":252},[668],{"type":78,"value":495},{"type":66,"tag":156,"props":670,"children":671},{"class":158,"line":258},[672,677,681,686,691,695],{"type":66,"tag":156,"props":673,"children":674},{"style":163},[675],{"type":78,"value":676}," login",{"type":66,"tag":156,"props":678,"children":679},{"style":252},[680],{"type":78,"value":214},{"type":66,"tag":156,"props":682,"children":683},{"style":252},[684],{"type":78,"value":685}," '",{"type":66,"tag":156,"props":687,"children":688},{"style":169},[689],{"type":78,"value":690},"/login",{"type":66,"tag":156,"props":692,"children":693},{"style":252},[694],{"type":78,"value":279},{"type":66,"tag":156,"props":696,"children":697},{"style":252},[698],{"type":78,"value":297},{"type":66,"tag":156,"props":700,"children":701},{"class":158,"line":300},[702,707,711,715,720,724],{"type":66,"tag":156,"props":703,"children":704},{"style":163},[705],{"type":78,"value":706}," callback",{"type":66,"tag":156,"props":708,"children":709},{"style":252},[710],{"type":78,"value":214},{"type":66,"tag":156,"props":712,"children":713},{"style":252},[714],{"type":78,"value":685},{"type":66,"tag":156,"props":716,"children":717},{"style":169},[718],{"type":78,"value":719},"/confirm",{"type":66,"tag":156,"props":721,"children":722},{"style":252},[723],{"type":78,"value":279},{"type":66,"tag":156,"props":725,"children":726},{"style":252},[727],{"type":78,"value":297},{"type":66,"tag":156,"props":729,"children":730},{"class":158,"line":498},[731,736,740],{"type":66,"tag":156,"props":732,"children":733},{"style":163},[734],{"type":78,"value":735}," include",{"type":66,"tag":156,"props":737,"children":738},{"style":252},[739],{"type":78,"value":214},{"type":66,"tag":156,"props":741,"children":742},{"style":252},[743],{"type":78,"value":744}," undefined,\n",{"type":66,"tag":156,"props":746,"children":747},{"class":158,"line":507},[748,753,757,762],{"type":66,"tag":156,"props":749,"children":750},{"style":163},[751],{"type":78,"value":752}," exclude",{"type":66,"tag":156,"props":754,"children":755},{"style":252},[756],{"type":78,"value":214},{"type":66,"tag":156,"props":758,"children":759},{"style":262},[760],{"type":78,"value":761}," []",{"type":66,"tag":156,"props":763,"children":764},{"style":252},[765],{"type":78,"value":297},{"type":66,"tag":156,"props":767,"children":768},{"class":158,"line":516},[769,774,778,784],{"type":66,"tag":156,"props":770,"children":771},{"style":163},[772],{"type":78,"value":773}," cookieRedirect",{"type":66,"tag":156,"props":775,"children":776},{"style":252},[777],{"type":78,"value":214},{"type":66,"tag":156,"props":779,"children":781},{"style":780},"--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC",[782],{"type":78,"value":783}," false",{"type":66,"tag":156,"props":785,"children":786},{"style":252},[787],{"type":78,"value":297},{"type":66,"tag":156,"props":789,"children":791},{"class":158,"line":790},7,[792],{"type":66,"tag":156,"props":793,"children":794},{"style":252},[795],{"type":78,"value":513},{"type":66,"tag":797,"props":798,"children":799},"ul",{},[800,812,847,874,909],{"type":66,"tag":801,"props":802,"children":803},"li",{},[804,810],{"type":66,"tag":138,"props":805,"children":807},{"className":806},[],[808],{"type":78,"value":809},"login",{"type":78,"value":811},": User will be redirected to this path if not authenticated or after logout.",{"type":66,"tag":801,"props":813,"children":814},{},[815,821,823,829,831,838,840,846],{"type":66,"tag":138,"props":816,"children":818},{"className":817},[],[819],{"type":78,"value":820},"callback",{"type":78,"value":822},": This is the path the user will be redirect to after supabase login redirection. Should match configured ",{"type":66,"tag":138,"props":824,"children":826},{"className":825},[],[827],{"type":78,"value":828},"redirectTo",{"type":78,"value":830}," option of your ",{"type":66,"tag":71,"props":832,"children":835},{"href":833,"rel":834},"https://supabase.com/docs/reference/javascript/auth-signinwithoauth",[75],[836],{"type":78,"value":837},"signIn method",{"type":78,"value":839},". Should also be configured in your Supabase dashboard under ",{"type":66,"tag":138,"props":841,"children":843},{"className":842},[],[844],{"type":78,"value":845},"Authentication -> URL Configuration -> Redirect URLs",{"type":78,"value":124},{"type":66,"tag":801,"props":848,"children":849},{},[850,856,858,864,866,872],{"type":66,"tag":138,"props":851,"children":853},{"className":852},[],[854],{"type":78,"value":855},"include",{"type":78,"value":857},": Routes to include in the redirect. ",{"type":66,"tag":138,"props":859,"children":861},{"className":860},[],[862],{"type":78,"value":863},"['/admin(/*)?']",{"type":78,"value":865}," will enable the redirect only for the ",{"type":66,"tag":138,"props":867,"children":869},{"className":868},[],[870],{"type":78,"value":871},"admin",{"type":78,"value":873}," page and all sub-pages.",{"type":66,"tag":801,"props":875,"children":876},{},[877,883,885,891,893,899,901,907],{"type":66,"tag":138,"props":878,"children":880},{"className":879},[],[881],{"type":78,"value":882},"exclude",{"type":78,"value":884},": Routes to exclude from the redirect. ",{"type":66,"tag":138,"props":886,"children":888},{"className":887},[],[889],{"type":78,"value":890},"['/foo', '/bar/*']",{"type":78,"value":892}," will exclude the ",{"type":66,"tag":138,"props":894,"children":896},{"className":895},[],[897],{"type":78,"value":898},"foo",{"type":78,"value":900}," page and all pages in your ",{"type":66,"tag":138,"props":902,"children":904},{"className":903},[],[905],{"type":78,"value":906},"bar",{"type":78,"value":908}," folder.",{"type":66,"tag":801,"props":910,"children":911},{},[912,918,920,930],{"type":66,"tag":138,"props":913,"children":915},{"className":914},[],[916],{"type":78,"value":917},"cookieRedirect",{"type":78,"value":919},": Sets a cookie containing the path an unauthenticated user tried to access. The cookie can then be used on the ",{"type":66,"tag":71,"props":921,"children":924},{"href":922,"rel":923},"https://supabase.nuxtjs.org/authentication#confirm-page-confirm",[75],[925],{"type":66,"tag":138,"props":926,"children":928},{"className":927},[],[929],{"type":78,"value":719},{"type":78,"value":931}," page to redirect the user to the page they previously tried to visit.",{"type":66,"tag":524,"props":933,"children":935},{"id":934},"cookiename",[936],{"type":66,"tag":138,"props":937,"children":939},{"className":938},[],[940],{"type":78,"value":941},"cookieName",{"type":66,"tag":67,"props":943,"children":944},{},[945,946],{"type":78,"value":537},{"type":66,"tag":138,"props":947,"children":949},{"className":948},[],[950],{"type":78,"value":951},"sb",{"type":66,"tag":67,"props":953,"children":954},{},[955,957,962,964,970,972],{"type":78,"value":956},"Cookie name used for storing the redirect path when using the ",{"type":66,"tag":138,"props":958,"children":960},{"className":959},[],[961],{"type":78,"value":609},{"type":78,"value":963}," option, added in front of ",{"type":66,"tag":138,"props":965,"children":967},{"className":966},[],[968],{"type":78,"value":969},"-redirect-path",{"type":78,"value":971}," to form the full cookie name e.g. ",{"type":66,"tag":138,"props":973,"children":975},{"className":974},[],[976],{"type":78,"value":977},"sb-redirect-path",{"type":66,"tag":524,"props":979,"children":981},{"id":980},"cookieoptions",[982],{"type":66,"tag":138,"props":983,"children":985},{"className":984},[],[986],{"type":78,"value":987},"cookieOptions",{"type":66,"tag":146,"props":989,"children":991},{"className":217,"code":990,"language":219,"meta":59,"style":59}," cookieOptions: {\n maxAge: 60 * 60 * 8,\n sameSite: 'lax',\n secure: true\n }\n",[992],{"type":66,"tag":138,"props":993,"children":994},{"__ignoreMap":59},[995,1011,1051,1080,1097],{"type":66,"tag":156,"props":996,"children":997},{"class":158,"line":159},[998,1003,1007],{"type":66,"tag":156,"props":999,"children":1000},{"style":163},[1001],{"type":78,"value":1002}," cookieOptions",{"type":66,"tag":156,"props":1004,"children":1005},{"style":252},[1006],{"type":78,"value":214},{"type":66,"tag":156,"props":1008,"children":1009},{"style":252},[1010],{"type":78,"value":495},{"type":66,"tag":156,"props":1012,"children":1013},{"class":158,"line":258},[1014,1019,1023,1029,1034,1038,1042,1047],{"type":66,"tag":156,"props":1015,"children":1016},{"style":163},[1017],{"type":78,"value":1018}," maxAge",{"type":66,"tag":156,"props":1020,"children":1021},{"style":252},[1022],{"type":78,"value":214},{"type":66,"tag":156,"props":1024,"children":1026},{"style":1025},"--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C",[1027],{"type":78,"value":1028}," 60",{"type":66,"tag":156,"props":1030,"children":1031},{"style":252},[1032],{"type":78,"value":1033}," *",{"type":66,"tag":156,"props":1035,"children":1036},{"style":1025},[1037],{"type":78,"value":1028},{"type":66,"tag":156,"props":1039,"children":1040},{"style":252},[1041],{"type":78,"value":1033},{"type":66,"tag":156,"props":1043,"children":1044},{"style":1025},[1045],{"type":78,"value":1046}," 8",{"type":66,"tag":156,"props":1048,"children":1049},{"style":252},[1050],{"type":78,"value":297},{"type":66,"tag":156,"props":1052,"children":1053},{"class":158,"line":300},[1054,1059,1063,1067,1072,1076],{"type":66,"tag":156,"props":1055,"children":1056},{"style":163},[1057],{"type":78,"value":1058}," sameSite",{"type":66,"tag":156,"props":1060,"children":1061},{"style":252},[1062],{"type":78,"value":214},{"type":66,"tag":156,"props":1064,"children":1065},{"style":252},[1066],{"type":78,"value":685},{"type":66,"tag":156,"props":1068,"children":1069},{"style":169},[1070],{"type":78,"value":1071},"lax",{"type":66,"tag":156,"props":1073,"children":1074},{"style":252},[1075],{"type":78,"value":279},{"type":66,"tag":156,"props":1077,"children":1078},{"style":252},[1079],{"type":78,"value":297},{"type":66,"tag":156,"props":1081,"children":1082},{"class":158,"line":498},[1083,1088,1092],{"type":66,"tag":156,"props":1084,"children":1085},{"style":163},[1086],{"type":78,"value":1087}," secure",{"type":66,"tag":156,"props":1089,"children":1090},{"style":252},[1091],{"type":78,"value":214},{"type":66,"tag":156,"props":1093,"children":1094},{"style":780},[1095],{"type":78,"value":1096}," true\n",{"type":66,"tag":156,"props":1098,"children":1099},{"class":158,"line":507},[1100],{"type":66,"tag":156,"props":1101,"children":1102},{"style":252},[1103],{"type":78,"value":513},{"type":66,"tag":67,"props":1105,"children":1106},{},[1107,1109,1115],{"type":78,"value":1108},"Options for cookies used to share tokens between server and client, refer to ",{"type":66,"tag":71,"props":1110,"children":1113},{"href":1111,"rel":1112},"https://nuxt.com/docs/api/composables/use-cookie#options",[75],[1114],{"type":78,"value":987},{"type":78,"value":1116}," for available settings. Please note that the lifetime set here does not determine the Supabase session lifetime.",{"type":66,"tag":524,"props":1118,"children":1120},{"id":1119},"types",[1121],{"type":66,"tag":138,"props":1122,"children":1124},{"className":1123},[],[1125],{"type":78,"value":1119},{"type":66,"tag":67,"props":1127,"children":1128},{},[1129,1130],{"type":78,"value":537},{"type":66,"tag":138,"props":1131,"children":1133},{"className":1132},[],[1134],{"type":78,"value":1135},"./types/database.types.ts",{"type":66,"tag":67,"props":1137,"children":1138},{},[1139,1141,1146,1148,1153,1154,1159],{"type":78,"value":1140},"The path for the generated Supabase TypeScript definitions. The database definitions will be automatically passed to all clients: ",{"type":66,"tag":138,"props":1142,"children":1144},{"className":1143},[],[1145],{"type":78,"value":21},{"type":78,"value":1147},", ",{"type":66,"tag":138,"props":1149,"children":1151},{"className":1150},[],[1152],{"type":78,"value":34},{"type":78,"value":323},{"type":66,"tag":138,"props":1155,"children":1157},{"className":1156},[],[1158],{"type":78,"value":37},{"type":78,"value":124},{"type":66,"tag":146,"props":1161,"children":1163},{"className":148,"code":1162,"language":150,"meta":59,"style":59},"## Generate types from live database\nsupabase gen types --lang=typescript --project-id YourProjectId > types/database.types.ts\n\n## Generate types when using local environment\nsupabase gen types --lang=typescript --local > types/database.types.ts\n",[1164],{"type":66,"tag":138,"props":1165,"children":1166},{"__ignoreMap":59},[1167,1175,1217,1226,1234],{"type":66,"tag":156,"props":1168,"children":1169},{"class":158,"line":159},[1170],{"type":66,"tag":156,"props":1171,"children":1172},{"style":475},[1173],{"type":78,"value":1174},"## Generate types from live database\n",{"type":66,"tag":156,"props":1176,"children":1177},{"class":158,"line":258},[1178,1182,1187,1192,1197,1202,1207,1212],{"type":66,"tag":156,"props":1179,"children":1180},{"style":163},[1181],{"type":78,"value":430},{"type":66,"tag":156,"props":1183,"children":1184},{"style":169},[1185],{"type":78,"value":1186}," gen",{"type":66,"tag":156,"props":1188,"children":1189},{"style":169},[1190],{"type":78,"value":1191}," types",{"type":66,"tag":156,"props":1193,"children":1194},{"style":169},[1195],{"type":78,"value":1196}," --lang=typescript",{"type":66,"tag":156,"props":1198,"children":1199},{"style":169},[1200],{"type":78,"value":1201}," --project-id",{"type":66,"tag":156,"props":1203,"children":1204},{"style":169},[1205],{"type":78,"value":1206}," YourProjectId",{"type":66,"tag":156,"props":1208,"children":1209},{"style":252},[1210],{"type":78,"value":1211}," >",{"type":66,"tag":156,"props":1213,"children":1214},{"style":169},[1215],{"type":78,"value":1216}," types/database.types.ts\n",{"type":66,"tag":156,"props":1218,"children":1219},{"class":158,"line":300},[1220],{"type":66,"tag":156,"props":1221,"children":1223},{"emptyLinePlaceholder":1222},true,[1224],{"type":78,"value":1225},"\n",{"type":66,"tag":156,"props":1227,"children":1228},{"class":158,"line":498},[1229],{"type":66,"tag":156,"props":1230,"children":1231},{"style":475},[1232],{"type":78,"value":1233},"## Generate types when using local environment\n",{"type":66,"tag":156,"props":1235,"children":1236},{"class":158,"line":507},[1237,1241,1245,1249,1253,1258,1262],{"type":66,"tag":156,"props":1238,"children":1239},{"style":163},[1240],{"type":78,"value":430},{"type":66,"tag":156,"props":1242,"children":1243},{"style":169},[1244],{"type":78,"value":1186},{"type":66,"tag":156,"props":1246,"children":1247},{"style":169},[1248],{"type":78,"value":1191},{"type":66,"tag":156,"props":1250,"children":1251},{"style":169},[1252],{"type":78,"value":1196},{"type":66,"tag":156,"props":1254,"children":1255},{"style":169},[1256],{"type":78,"value":1257}," --local",{"type":66,"tag":156,"props":1259,"children":1260},{"style":252},[1261],{"type":78,"value":1211},{"type":66,"tag":156,"props":1263,"children":1264},{"style":169},[1265],{"type":78,"value":1216},{"type":66,"tag":67,"props":1267,"children":1268},{},[1269,1271,1277],{"type":78,"value":1270},"Set to ",{"type":66,"tag":138,"props":1272,"children":1274},{"className":1273},[],[1275],{"type":78,"value":1276},"false",{"type":78,"value":1278}," to disable.",{"type":66,"tag":67,"props":1280,"children":1281},{},[1282,1284,1291],{"type":78,"value":1283},"Check Supabase ",{"type":66,"tag":71,"props":1285,"children":1288},{"href":1286,"rel":1287},"https://supabase.com/docs/reference/javascript/release-notes#typescript-support",[75],[1289],{"type":78,"value":1290},"documentation",{"type":78,"value":1292}," for further information.",{"type":66,"tag":524,"props":1294,"children":1296},{"id":1295},"clientoptions",[1297],{"type":66,"tag":138,"props":1298,"children":1300},{"className":1299},[],[1301],{"type":78,"value":1302},"clientOptions",{"type":66,"tag":67,"props":1304,"children":1305},{},[1306],{"type":78,"value":645},{"type":66,"tag":146,"props":1308,"children":1310},{"className":217,"code":1309,"language":219,"meta":59,"style":59}," clientOptions: { }\n",[1311],{"type":66,"tag":138,"props":1312,"children":1313},{"__ignoreMap":59},[1314],{"type":66,"tag":156,"props":1315,"children":1316},{"class":158,"line":159},[1317,1322,1326,1331],{"type":66,"tag":156,"props":1318,"children":1319},{"style":163},[1320],{"type":78,"value":1321}," clientOptions",{"type":66,"tag":156,"props":1323,"children":1324},{"style":252},[1325],{"type":78,"value":214},{"type":66,"tag":156,"props":1327,"children":1328},{"style":252},[1329],{"type":78,"value":1330}," {",{"type":66,"tag":156,"props":1332,"children":1333},{"style":252},[1334],{"type":78,"value":1335}," }\n",{"type":66,"tag":67,"props":1337,"children":1338},{},[1339,1341,1348,1350,1356],{"type":78,"value":1340},"Supabase client options ",{"type":66,"tag":71,"props":1342,"children":1345},{"href":1343,"rel":1344},"https://supabase.com/docs/reference/javascript/initializing#parameters",[75],[1346],{"type":78,"value":1347},"available here",{"type":78,"value":1349}," merged with default values from ",{"type":66,"tag":138,"props":1351,"children":1353},{"className":1352},[],[1354],{"type":78,"value":1355},"@supabase/ssr",{"type":78,"value":214},{"type":66,"tag":146,"props":1358,"children":1360},{"className":217,"code":1359,"language":219,"meta":59,"style":59}," clientOptions: {\n auth: {\n flowType: 'pkce',\n autoRefreshToken: isBrowser(),\n detectSessionInUrl: isBrowser(),\n persistSession: true,\n },\n }\n",[1361],{"type":66,"tag":138,"props":1362,"children":1363},{"__ignoreMap":59},[1364,1379,1395,1424,1450,1474,1495,1503],{"type":66,"tag":156,"props":1365,"children":1366},{"class":158,"line":159},[1367,1371,1375],{"type":66,"tag":156,"props":1368,"children":1369},{"style":163},[1370],{"type":78,"value":1321},{"type":66,"tag":156,"props":1372,"children":1373},{"style":252},[1374],{"type":78,"value":214},{"type":66,"tag":156,"props":1376,"children":1377},{"style":252},[1378],{"type":78,"value":495},{"type":66,"tag":156,"props":1380,"children":1381},{"class":158,"line":258},[1382,1387,1391],{"type":66,"tag":156,"props":1383,"children":1384},{"style":163},[1385],{"type":78,"value":1386}," auth",{"type":66,"tag":156,"props":1388,"children":1389},{"style":252},[1390],{"type":78,"value":214},{"type":66,"tag":156,"props":1392,"children":1393},{"style":252},[1394],{"type":78,"value":495},{"type":66,"tag":156,"props":1396,"children":1397},{"class":158,"line":300},[1398,1403,1407,1411,1416,1420],{"type":66,"tag":156,"props":1399,"children":1400},{"style":163},[1401],{"type":78,"value":1402}," flowType",{"type":66,"tag":156,"props":1404,"children":1405},{"style":252},[1406],{"type":78,"value":214},{"type":66,"tag":156,"props":1408,"children":1409},{"style":252},[1410],{"type":78,"value":685},{"type":66,"tag":156,"props":1412,"children":1413},{"style":169},[1414],{"type":78,"value":1415},"pkce",{"type":66,"tag":156,"props":1417,"children":1418},{"style":252},[1419],{"type":78,"value":279},{"type":66,"tag":156,"props":1421,"children":1422},{"style":252},[1423],{"type":78,"value":297},{"type":66,"tag":156,"props":1425,"children":1426},{"class":158,"line":498},[1427,1432,1436,1441,1446],{"type":66,"tag":156,"props":1428,"children":1429},{"style":163},[1430],{"type":78,"value":1431}," autoRefreshToken",{"type":66,"tag":156,"props":1433,"children":1434},{"style":252},[1435],{"type":78,"value":214},{"type":66,"tag":156,"props":1437,"children":1438},{"style":240},[1439],{"type":78,"value":1440}," isBrowser",{"type":66,"tag":156,"props":1442,"children":1443},{"style":262},[1444],{"type":78,"value":1445},"()",{"type":66,"tag":156,"props":1447,"children":1448},{"style":252},[1449],{"type":78,"value":297},{"type":66,"tag":156,"props":1451,"children":1452},{"class":158,"line":507},[1453,1458,1462,1466,1470],{"type":66,"tag":156,"props":1454,"children":1455},{"style":163},[1456],{"type":78,"value":1457}," detectSessionInUrl",{"type":66,"tag":156,"props":1459,"children":1460},{"style":252},[1461],{"type":78,"value":214},{"type":66,"tag":156,"props":1463,"children":1464},{"style":240},[1465],{"type":78,"value":1440},{"type":66,"tag":156,"props":1467,"children":1468},{"style":262},[1469],{"type":78,"value":1445},{"type":66,"tag":156,"props":1471,"children":1472},{"style":252},[1473],{"type":78,"value":297},{"type":66,"tag":156,"props":1475,"children":1476},{"class":158,"line":516},[1477,1482,1486,1491],{"type":66,"tag":156,"props":1478,"children":1479},{"style":163},[1480],{"type":78,"value":1481}," persistSession",{"type":66,"tag":156,"props":1483,"children":1484},{"style":252},[1485],{"type":78,"value":214},{"type":66,"tag":156,"props":1487,"children":1488},{"style":780},[1489],{"type":78,"value":1490}," true",{"type":66,"tag":156,"props":1492,"children":1493},{"style":252},[1494],{"type":78,"value":297},{"type":66,"tag":156,"props":1496,"children":1497},{"class":158,"line":790},[1498],{"type":66,"tag":156,"props":1499,"children":1500},{"style":252},[1501],{"type":78,"value":1502}," },\n",{"type":66,"tag":156,"props":1504,"children":1506},{"class":158,"line":1505},8,[1507],{"type":66,"tag":156,"props":1508,"children":1509},{"style":252},[1510],{"type":78,"value":513},{"type":66,"tag":126,"props":1512,"children":1514},{"id":1513},"demo",[1515],{"type":78,"value":47},{"type":66,"tag":67,"props":1517,"children":1518},{},[1519,1521,1528,1530,1535],{"type":78,"value":1520},"A live demo is made for see this module in action on ",{"type":66,"tag":71,"props":1522,"children":1525},{"href":1523,"rel":1524},"https://n3-supabase.netlify.app",[75],[1526],{"type":78,"value":1527},"n3-supabase.netlify.app",{"type":78,"value":1529},", read more in the ",{"type":66,"tag":71,"props":1531,"children":1532},{"href":48},[1533],{"type":78,"value":1534},"demo section",{"type":78,"value":124},{"type":66,"tag":67,"props":1537,"children":1538},{},[1539],{"type":66,"tag":71,"props":1540,"children":1542},{"href":1523,"rel":1541},[75],[1543],{"type":66,"tag":1544,"props":1545,"children":1548},"img",{"alt":1546,"src":1547},"Supabase demo with Nuxt 3","https://user-images.githubusercontent.com/904724/160422461-8f87500a-8dec-4413-86b2-ba04e1b2d17b.png",[],{"type":66,"tag":67,"props":1550,"children":1551},{},[1552,1554,1561],{"type":78,"value":1553},"Also checkout the ",{"type":66,"tag":71,"props":1555,"children":1558},{"href":1556,"rel":1557},"https://www.youtube.com/watch?v=jIyiRT6zT8Q",[75],[1559],{"type":78,"value":1560},"YouTube video",{"type":78,"value":1562}," about its usage in a live demo.",{"type":66,"tag":1564,"props":1565,"children":1566},"style",{},[1567],{"type":78,"value":1568},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":59,"searchDepth":258,"depth":258,"links":1570},[1571,1572,1583],{"id":128,"depth":258,"text":131},{"id":416,"depth":258,"text":419,"children":1573},[1574,1575,1576,1577,1578,1579,1580,1581,1582],{"id":526,"depth":300,"text":526},{"id":560,"depth":300,"text":560},{"id":584,"depth":300,"text":591},{"id":609,"depth":300,"text":609},{"id":633,"depth":300,"text":640},{"id":934,"depth":300,"text":941},{"id":980,"depth":300,"text":987},{"id":1119,"depth":300,"text":1119},{"id":1295,"depth":300,"text":1302},{"id":1513,"depth":258,"text":47},"markdown","content:2.get-started.md","content","2.get-started.md","2.get-started","md",[1591,1592],null,{"_path":10,"title":9,"description":1593},"Authenticate your user thanks to the PKCE Oauth protocol that enables secure exchange of refresh and access tokens between an application and the authorization server",1724942526478] \ No newline at end of file diff --git a/get-started/index.html b/get-started/index.html index 4596a776..8dc9a415 100644 --- a/get-started/index.html +++ b/get-started/index.html @@ -61,7 +61,7 @@ - + @@ -148,5 +148,5 @@ }, }

Demo

A live demo is made for see this module in action on n3-supabase.netlify.app, read more in the demo section.

Supabase demo with Nuxt 3

Also checkout the YouTube video about its usage in a live demo.


Made with Nuxt Studio
- - \ No newline at end of file + + \ No newline at end of file diff --git a/index.html b/index.html index 178fcc68..7359cfd6 100644 --- a/index.html +++ b/index.html @@ -54,7 +54,7 @@ - + @@ -107,5 +107,5 @@ email: email.value, }) } -

Shipped with many features

Nuxt 3 ready

Vue 3 composables

Supabase-js V2

Usage in API server routes

Authentication support

TypeScript support

Made with Nuxt Studio
- \ No newline at end of file +

Shipped with many features

Nuxt 3 ready

Vue 3 composables

Supabase-js V2

Usage in API server routes

Authentication support

TypeScript support

Made with Nuxt Studio
+ \ No newline at end of file diff --git a/roadmap/_payload.json b/roadmap/_payload.json index fcbb7591..9b4b129d 100644 --- a/roadmap/_payload.json +++ b/roadmap/_payload.json @@ -1 +1 @@ -[{"data":1,"prerenderedAt":84},["ShallowReactive",2],{"navigation":3,"/roadmap":58,"/roadmap-surround":80},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":56,"_dir":59,"_draft":60,"_partial":60,"_locale":59,"title":55,"description":61,"icon":57,"body":62,"_type":74,"_id":75,"_source":76,"_file":77,"_stem":78,"_extension":79},"",false,"Discover our kaban board for the next release of the Supabase module.",{"type":63,"children":64,"toc":71},"root",[65],{"type":66,"tag":67,"props":68,"children":70},"element","volta-board",{"token":69},"eyJzdGF0dXNlcyI6WyJ0cmlhZ2UiLCJiYWNrbG9nIiwidG9kbyIsImluX3Byb2dyZXNzIiwiaW5fcmV2aWV3IiwiZG9uZSIsInJlbGVhc2VkIiwiY2FuY2VsbGVkIl0sImZpbHRlcnMiOnt9LCJvd25lciI6Im51eHQtbW9kdWxlcyIsIm5hbWUiOiJzdXBhYmFzZSJ9",[],{"title":59,"searchDepth":72,"depth":72,"links":73},2,[],"markdown","content:7.roadmap.md","content","7.roadmap.md","7.roadmap","md",[81,83],{"_path":52,"title":51,"description":82},"Discover the latest updates of the Supabase Module",null,1724940863165] \ No newline at end of file +[{"data":1,"prerenderedAt":84},["ShallowReactive",2],{"navigation":3,"/roadmap":58,"/roadmap-surround":80},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":56,"_dir":59,"_draft":60,"_partial":60,"_locale":59,"title":55,"description":61,"icon":57,"body":62,"_type":74,"_id":75,"_source":76,"_file":77,"_stem":78,"_extension":79},"",false,"Discover our kaban board for the next release of the Supabase module.",{"type":63,"children":64,"toc":71},"root",[65],{"type":66,"tag":67,"props":68,"children":70},"element","volta-board",{"token":69},"eyJzdGF0dXNlcyI6WyJ0cmlhZ2UiLCJiYWNrbG9nIiwidG9kbyIsImluX3Byb2dyZXNzIiwiaW5fcmV2aWV3IiwiZG9uZSIsInJlbGVhc2VkIiwiY2FuY2VsbGVkIl0sImZpbHRlcnMiOnt9LCJvd25lciI6Im51eHQtbW9kdWxlcyIsIm5hbWUiOiJzdXBhYmFzZSJ9",[],{"title":59,"searchDepth":72,"depth":72,"links":73},2,[],"markdown","content:7.roadmap.md","content","7.roadmap.md","7.roadmap","md",[81,83],{"_path":52,"title":51,"description":82},"Discover the latest updates of the Supabase Module",null,1724942526966] \ No newline at end of file diff --git a/roadmap/index.html b/roadmap/index.html index 64534b02..4310150e 100644 --- a/roadmap/index.html +++ b/roadmap/index.html @@ -59,7 +59,7 @@ - + @@ -90,5 +90,5 @@
- - \ No newline at end of file + + \ No newline at end of file diff --git a/usage/composables/usesupabaseclient/_payload.json b/usage/composables/usesupabaseclient/_payload.json index b69c98e8..a57ec639 100644 --- a/usage/composables/usesupabaseclient/_payload.json +++ b/usage/composables/usesupabaseclient/_payload.json @@ -1 +1 @@ -[{"data":1,"prerenderedAt":2238},["ShallowReactive",2],{"navigation":3,"/usage/composables/usesupabaseclient":58,"/usage/composables/usesupabaseclient-surround":2233},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":22,"_dir":59,"_draft":60,"_partial":60,"_locale":61,"title":21,"description":62,"body":63,"_type":2227,"_id":2228,"_source":2229,"_file":2230,"_stem":2231,"_extension":2232},"composables",false,"","Make requests to the Supabase API with the useSupabaseClient composable",{"type":64,"children":65,"toc":2221},"root",[66,83,106,146,152,174,191,716,727,733,747,769,1129,1135,1149,1163,1168,1928,1934,1964,2071,2076,2215],{"type":67,"tag":68,"props":69,"children":70},"element","p",{},[71,81],{"type":67,"tag":72,"props":73,"children":77},"a",{"href":74,"rel":75},"https://nuxt.com/docs/guide/directory-structure/composables",[76],"nofollow",[78],{"type":79,"value":80},"text","Auto-import",{"type":79,"value":82}," your client inside your vue files.",{"type":67,"tag":68,"props":84,"children":85},{},[86,88,95,97,104],{"type":79,"value":87},"This composable is using ",{"type":67,"tag":72,"props":89,"children":92},{"href":90,"rel":91},"https://github.com/supabase/supabase-js/",[76],[93],{"type":79,"value":94},"supabase-js",{"type":79,"value":96}," under the hood, it gives access to the ",{"type":67,"tag":72,"props":98,"children":101},{"href":99,"rel":100},"https://supabase.com/docs/reference/javascript/initializing",[76],[102],{"type":79,"value":103},"Supabase client",{"type":79,"value":105},".",{"type":67,"tag":107,"props":108,"children":109},"blockquote",{},[110],{"type":67,"tag":68,"props":111,"children":112},{},[113,115,122,124,130,132,139,141,145],{"type":79,"value":114},"The client is initialized with the ",{"type":67,"tag":116,"props":117,"children":119},"code",{"className":118},[],[120],{"type":79,"value":121},"SUPABASE_KEY",{"type":79,"value":123}," you must have in your ",{"type":67,"tag":116,"props":125,"children":127},{"className":126},[],[128],{"type":79,"value":129},".env",{"type":79,"value":131}," file. It establishes the connection with the database and make use of user JWT to apply ",{"type":67,"tag":72,"props":133,"children":136},{"href":134,"rel":135},"https://supabase.com/docs/learn/auth-deep-dive/auth-row-level-security",[76],[137],{"type":79,"value":138},"RLS Policies",{"type":79,"value":140}," implemented in Supabase. If you want to bypass policies, you can use the ",{"type":67,"tag":72,"props":142,"children":143},{"href":38},[144],{"type":79,"value":37},{"type":79,"value":105},{"type":67,"tag":147,"props":148,"children":150},"h2",{"id":149},"authentication",[151],{"type":79,"value":9},{"type":67,"tag":68,"props":153,"children":154},{},[155,157,163,165,172],{"type":79,"value":156},"The useSupabaseClient composable is providing all methods to manage authorization under ",{"type":67,"tag":116,"props":158,"children":160},{"className":159},[],[161],{"type":79,"value":162},"useSupabaseClient().auth",{"type":79,"value":164},". For more details please see the ",{"type":67,"tag":72,"props":166,"children":169},{"href":167,"rel":168},"https://supabase.com/docs/reference/javascript/auth-api",[76],[170],{"type":79,"value":171},"supabase-js auth documentation",{"type":79,"value":173},". Here is an example for signing in and out:",{"type":67,"tag":175,"props":176,"children":178},"callout",{"icon":177},"i-heroicons-light-bulb",[179],{"type":67,"tag":68,"props":180,"children":181},{},[182,184,190],{"type":79,"value":183},"If you want a full explanation on how to handle the authentication process, please read this ",{"type":67,"tag":72,"props":185,"children":187},{"href":186},"/get-started#handle-authentication",[188],{"type":79,"value":189},"section",{"type":79,"value":105},{"type":67,"tag":192,"props":193,"children":197},"pre",{"className":194,"code":195,"language":196,"meta":61,"style":61},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","\u003Cscript setup lang=\"ts\">\nconst supabase = useSupabaseClient()\n\nconst signInWithOAuth = async () => {\n const { error } = await supabase.auth.signInWithOAuth({\n provider: 'github',\n options: {\n redirectTo: 'http://localhost:3000/confirm',\n },\n })\n if (error) console.log(error)\n}\n\nconst signOut = async () => {\n const { error } = await supabase.auth.signOut()\n if (error) console.log(error)\n}\n\u003C/script>\n","ts",[198],{"type":67,"tag":116,"props":199,"children":200},{"__ignoreMap":61},[201,243,273,283,320,389,423,440,470,479,493,543,552,560,593,646,690,698],{"type":67,"tag":202,"props":203,"children":206},"span",{"class":204,"line":205},"line",1,[207,213,219,224,229,234,238],{"type":67,"tag":202,"props":208,"children":210},{"style":209},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[211],{"type":79,"value":212},"\u003C",{"type":67,"tag":202,"props":214,"children":216},{"style":215},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[217],{"type":79,"value":218},"script setup lang",{"type":67,"tag":202,"props":220,"children":221},{"style":209},[222],{"type":79,"value":223},"=",{"type":67,"tag":202,"props":225,"children":226},{"style":209},[227],{"type":79,"value":228},"\"",{"type":67,"tag":202,"props":230,"children":232},{"style":231},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[233],{"type":79,"value":196},{"type":67,"tag":202,"props":235,"children":236},{"style":209},[237],{"type":79,"value":228},{"type":67,"tag":202,"props":239,"children":240},{"style":209},[241],{"type":79,"value":242},">\n",{"type":67,"tag":202,"props":244,"children":246},{"class":204,"line":245},2,[247,253,258,262,268],{"type":67,"tag":202,"props":248,"children":250},{"style":249},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[251],{"type":79,"value":252},"const",{"type":67,"tag":202,"props":254,"children":255},{"style":215},[256],{"type":79,"value":257}," supabase ",{"type":67,"tag":202,"props":259,"children":260},{"style":209},[261],{"type":79,"value":223},{"type":67,"tag":202,"props":263,"children":265},{"style":264},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[266],{"type":79,"value":267}," useSupabaseClient",{"type":67,"tag":202,"props":269,"children":270},{"style":215},[271],{"type":79,"value":272},"()\n",{"type":67,"tag":202,"props":274,"children":276},{"class":204,"line":275},3,[277],{"type":67,"tag":202,"props":278,"children":280},{"emptyLinePlaceholder":279},true,[281],{"type":79,"value":282},"\n",{"type":67,"tag":202,"props":284,"children":286},{"class":204,"line":285},4,[287,291,296,300,305,310,315],{"type":67,"tag":202,"props":288,"children":289},{"style":249},[290],{"type":79,"value":252},{"type":67,"tag":202,"props":292,"children":293},{"style":215},[294],{"type":79,"value":295}," signInWithOAuth ",{"type":67,"tag":202,"props":297,"children":298},{"style":209},[299],{"type":79,"value":223},{"type":67,"tag":202,"props":301,"children":302},{"style":249},[303],{"type":79,"value":304}," async",{"type":67,"tag":202,"props":306,"children":307},{"style":209},[308],{"type":79,"value":309}," ()",{"type":67,"tag":202,"props":311,"children":312},{"style":249},[313],{"type":79,"value":314}," =>",{"type":67,"tag":202,"props":316,"children":317},{"style":209},[318],{"type":79,"value":319}," {\n",{"type":67,"tag":202,"props":321,"children":323},{"class":204,"line":322},5,[324,329,334,339,344,349,355,360,364,369,373,378,384],{"type":67,"tag":202,"props":325,"children":326},{"style":249},[327],{"type":79,"value":328}," const",{"type":67,"tag":202,"props":330,"children":331},{"style":209},[332],{"type":79,"value":333}," {",{"type":67,"tag":202,"props":335,"children":336},{"style":215},[337],{"type":79,"value":338}," error",{"type":67,"tag":202,"props":340,"children":341},{"style":209},[342],{"type":79,"value":343}," }",{"type":67,"tag":202,"props":345,"children":346},{"style":209},[347],{"type":79,"value":348}," =",{"type":67,"tag":202,"props":350,"children":352},{"style":351},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[353],{"type":79,"value":354}," await",{"type":67,"tag":202,"props":356,"children":357},{"style":215},[358],{"type":79,"value":359}," supabase",{"type":67,"tag":202,"props":361,"children":362},{"style":209},[363],{"type":79,"value":105},{"type":67,"tag":202,"props":365,"children":366},{"style":215},[367],{"type":79,"value":368},"auth",{"type":67,"tag":202,"props":370,"children":371},{"style":209},[372],{"type":79,"value":105},{"type":67,"tag":202,"props":374,"children":375},{"style":264},[376],{"type":79,"value":377},"signInWithOAuth",{"type":67,"tag":202,"props":379,"children":381},{"style":380},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[382],{"type":79,"value":383},"(",{"type":67,"tag":202,"props":385,"children":386},{"style":209},[387],{"type":79,"value":388},"{\n",{"type":67,"tag":202,"props":390,"children":392},{"class":204,"line":391},6,[393,398,403,408,413,418],{"type":67,"tag":202,"props":394,"children":395},{"style":380},[396],{"type":79,"value":397}," provider",{"type":67,"tag":202,"props":399,"children":400},{"style":209},[401],{"type":79,"value":402},":",{"type":67,"tag":202,"props":404,"children":405},{"style":209},[406],{"type":79,"value":407}," '",{"type":67,"tag":202,"props":409,"children":410},{"style":231},[411],{"type":79,"value":412},"github",{"type":67,"tag":202,"props":414,"children":415},{"style":209},[416],{"type":79,"value":417},"'",{"type":67,"tag":202,"props":419,"children":420},{"style":209},[421],{"type":79,"value":422},",\n",{"type":67,"tag":202,"props":424,"children":426},{"class":204,"line":425},7,[427,432,436],{"type":67,"tag":202,"props":428,"children":429},{"style":380},[430],{"type":79,"value":431}," options",{"type":67,"tag":202,"props":433,"children":434},{"style":209},[435],{"type":79,"value":402},{"type":67,"tag":202,"props":437,"children":438},{"style":209},[439],{"type":79,"value":319},{"type":67,"tag":202,"props":441,"children":443},{"class":204,"line":442},8,[444,449,453,457,462,466],{"type":67,"tag":202,"props":445,"children":446},{"style":380},[447],{"type":79,"value":448}," redirectTo",{"type":67,"tag":202,"props":450,"children":451},{"style":209},[452],{"type":79,"value":402},{"type":67,"tag":202,"props":454,"children":455},{"style":209},[456],{"type":79,"value":407},{"type":67,"tag":202,"props":458,"children":459},{"style":231},[460],{"type":79,"value":461},"http://localhost:3000/confirm",{"type":67,"tag":202,"props":463,"children":464},{"style":209},[465],{"type":79,"value":417},{"type":67,"tag":202,"props":467,"children":468},{"style":209},[469],{"type":79,"value":422},{"type":67,"tag":202,"props":471,"children":473},{"class":204,"line":472},9,[474],{"type":67,"tag":202,"props":475,"children":476},{"style":209},[477],{"type":79,"value":478}," },\n",{"type":67,"tag":202,"props":480,"children":482},{"class":204,"line":481},10,[483,488],{"type":67,"tag":202,"props":484,"children":485},{"style":209},[486],{"type":79,"value":487}," }",{"type":67,"tag":202,"props":489,"children":490},{"style":380},[491],{"type":79,"value":492},")\n",{"type":67,"tag":202,"props":494,"children":496},{"class":204,"line":495},11,[497,502,507,512,517,522,526,531,535,539],{"type":67,"tag":202,"props":498,"children":499},{"style":351},[500],{"type":79,"value":501}," if",{"type":67,"tag":202,"props":503,"children":504},{"style":380},[505],{"type":79,"value":506}," (",{"type":67,"tag":202,"props":508,"children":509},{"style":215},[510],{"type":79,"value":511},"error",{"type":67,"tag":202,"props":513,"children":514},{"style":380},[515],{"type":79,"value":516},") ",{"type":67,"tag":202,"props":518,"children":519},{"style":215},[520],{"type":79,"value":521},"console",{"type":67,"tag":202,"props":523,"children":524},{"style":209},[525],{"type":79,"value":105},{"type":67,"tag":202,"props":527,"children":528},{"style":264},[529],{"type":79,"value":530},"log",{"type":67,"tag":202,"props":532,"children":533},{"style":380},[534],{"type":79,"value":383},{"type":67,"tag":202,"props":536,"children":537},{"style":215},[538],{"type":79,"value":511},{"type":67,"tag":202,"props":540,"children":541},{"style":380},[542],{"type":79,"value":492},{"type":67,"tag":202,"props":544,"children":546},{"class":204,"line":545},12,[547],{"type":67,"tag":202,"props":548,"children":549},{"style":209},[550],{"type":79,"value":551},"}\n",{"type":67,"tag":202,"props":553,"children":555},{"class":204,"line":554},13,[556],{"type":67,"tag":202,"props":557,"children":558},{"emptyLinePlaceholder":279},[559],{"type":79,"value":282},{"type":67,"tag":202,"props":561,"children":563},{"class":204,"line":562},14,[564,568,573,577,581,585,589],{"type":67,"tag":202,"props":565,"children":566},{"style":249},[567],{"type":79,"value":252},{"type":67,"tag":202,"props":569,"children":570},{"style":215},[571],{"type":79,"value":572}," signOut ",{"type":67,"tag":202,"props":574,"children":575},{"style":209},[576],{"type":79,"value":223},{"type":67,"tag":202,"props":578,"children":579},{"style":249},[580],{"type":79,"value":304},{"type":67,"tag":202,"props":582,"children":583},{"style":209},[584],{"type":79,"value":309},{"type":67,"tag":202,"props":586,"children":587},{"style":249},[588],{"type":79,"value":314},{"type":67,"tag":202,"props":590,"children":591},{"style":209},[592],{"type":79,"value":319},{"type":67,"tag":202,"props":594,"children":596},{"class":204,"line":595},15,[597,601,605,609,613,617,621,625,629,633,637,642],{"type":67,"tag":202,"props":598,"children":599},{"style":249},[600],{"type":79,"value":328},{"type":67,"tag":202,"props":602,"children":603},{"style":209},[604],{"type":79,"value":333},{"type":67,"tag":202,"props":606,"children":607},{"style":215},[608],{"type":79,"value":338},{"type":67,"tag":202,"props":610,"children":611},{"style":209},[612],{"type":79,"value":343},{"type":67,"tag":202,"props":614,"children":615},{"style":209},[616],{"type":79,"value":348},{"type":67,"tag":202,"props":618,"children":619},{"style":351},[620],{"type":79,"value":354},{"type":67,"tag":202,"props":622,"children":623},{"style":215},[624],{"type":79,"value":359},{"type":67,"tag":202,"props":626,"children":627},{"style":209},[628],{"type":79,"value":105},{"type":67,"tag":202,"props":630,"children":631},{"style":215},[632],{"type":79,"value":368},{"type":67,"tag":202,"props":634,"children":635},{"style":209},[636],{"type":79,"value":105},{"type":67,"tag":202,"props":638,"children":639},{"style":264},[640],{"type":79,"value":641},"signOut",{"type":67,"tag":202,"props":643,"children":644},{"style":380},[645],{"type":79,"value":272},{"type":67,"tag":202,"props":647,"children":649},{"class":204,"line":648},16,[650,654,658,662,666,670,674,678,682,686],{"type":67,"tag":202,"props":651,"children":652},{"style":351},[653],{"type":79,"value":501},{"type":67,"tag":202,"props":655,"children":656},{"style":380},[657],{"type":79,"value":506},{"type":67,"tag":202,"props":659,"children":660},{"style":215},[661],{"type":79,"value":511},{"type":67,"tag":202,"props":663,"children":664},{"style":380},[665],{"type":79,"value":516},{"type":67,"tag":202,"props":667,"children":668},{"style":215},[669],{"type":79,"value":521},{"type":67,"tag":202,"props":671,"children":672},{"style":209},[673],{"type":79,"value":105},{"type":67,"tag":202,"props":675,"children":676},{"style":264},[677],{"type":79,"value":530},{"type":67,"tag":202,"props":679,"children":680},{"style":380},[681],{"type":79,"value":383},{"type":67,"tag":202,"props":683,"children":684},{"style":215},[685],{"type":79,"value":511},{"type":67,"tag":202,"props":687,"children":688},{"style":380},[689],{"type":79,"value":492},{"type":67,"tag":202,"props":691,"children":693},{"class":204,"line":692},17,[694],{"type":67,"tag":202,"props":695,"children":696},{"style":209},[697],{"type":79,"value":551},{"type":67,"tag":202,"props":699,"children":701},{"class":204,"line":700},18,[702,707,712],{"type":67,"tag":202,"props":703,"children":704},{"style":209},[705],{"type":79,"value":706},"\u003C/",{"type":67,"tag":202,"props":708,"children":709},{"style":215},[710],{"type":79,"value":711},"script",{"type":67,"tag":202,"props":713,"children":714},{"style":209},[715],{"type":79,"value":242},{"type":67,"tag":68,"props":717,"children":718},{},[719,721,725],{"type":79,"value":720},"Please also take a look at ",{"type":67,"tag":72,"props":722,"children":723},{"href":6},[724],{"type":79,"value":5},{"type":79,"value":726}," for the authorization flow.",{"type":67,"tag":147,"props":728,"children":730},{"id":729},"database-request",[731],{"type":79,"value":732},"Database Request",{"type":67,"tag":68,"props":734,"children":735},{},[736,738,745],{"type":79,"value":737},"Please check ",{"type":67,"tag":72,"props":739,"children":742},{"href":740,"rel":741},"https://supabase.com/docs/reference/javascript/select",[76],[743],{"type":79,"value":744},"Supabase",{"type":79,"value":746}," documentation to fully use the power of Supabase client.",{"type":67,"tag":68,"props":748,"children":749},{},[750,752,758,760,767],{"type":79,"value":751},"Here is an example of a fetch using the ",{"type":67,"tag":116,"props":753,"children":755},{"className":754},[],[756],{"type":79,"value":757},"select",{"type":79,"value":759}," method with Nuxt 3 ",{"type":67,"tag":72,"props":761,"children":764},{"href":762,"rel":763},"https://nuxt.com/docs/getting-started/data-fetching#useasyncdata",[76],[765],{"type":79,"value":766},"useAsyncData",{"type":79,"value":768}," composable.",{"type":67,"tag":192,"props":770,"children":774},{"className":771,"code":772,"language":773,"meta":61,"style":61},"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","\u003Cscript setup lang=\"ts\">\nconst client = useSupabaseClient()\n\nconst { data: restaurant } = await useAsyncData('restaurant', async () => {\n const { data } = await client.from('restaurants').select('name, location').eq('name', 'My Restaurant Name').single()\n\n return data\n})\n\u003C/script>\n","vue",[775],{"type":67,"tag":116,"props":776,"children":777},{"__ignoreMap":61},[778,819,843,850,931,1083,1090,1103,1114],{"type":67,"tag":202,"props":779,"children":780},{"class":204,"line":205},[781,785,789,794,799,803,807,811,815],{"type":67,"tag":202,"props":782,"children":783},{"style":209},[784],{"type":79,"value":212},{"type":67,"tag":202,"props":786,"children":787},{"style":380},[788],{"type":79,"value":711},{"type":67,"tag":202,"props":790,"children":791},{"style":249},[792],{"type":79,"value":793}," setup",{"type":67,"tag":202,"props":795,"children":796},{"style":249},[797],{"type":79,"value":798}," lang",{"type":67,"tag":202,"props":800,"children":801},{"style":209},[802],{"type":79,"value":223},{"type":67,"tag":202,"props":804,"children":805},{"style":209},[806],{"type":79,"value":228},{"type":67,"tag":202,"props":808,"children":809},{"style":231},[810],{"type":79,"value":196},{"type":67,"tag":202,"props":812,"children":813},{"style":209},[814],{"type":79,"value":228},{"type":67,"tag":202,"props":816,"children":817},{"style":209},[818],{"type":79,"value":242},{"type":67,"tag":202,"props":820,"children":821},{"class":204,"line":245},[822,826,831,835,839],{"type":67,"tag":202,"props":823,"children":824},{"style":249},[825],{"type":79,"value":252},{"type":67,"tag":202,"props":827,"children":828},{"style":215},[829],{"type":79,"value":830}," client ",{"type":67,"tag":202,"props":832,"children":833},{"style":209},[834],{"type":79,"value":223},{"type":67,"tag":202,"props":836,"children":837},{"style":264},[838],{"type":79,"value":267},{"type":67,"tag":202,"props":840,"children":841},{"style":215},[842],{"type":79,"value":272},{"type":67,"tag":202,"props":844,"children":845},{"class":204,"line":275},[846],{"type":67,"tag":202,"props":847,"children":848},{"emptyLinePlaceholder":279},[849],{"type":79,"value":282},{"type":67,"tag":202,"props":851,"children":852},{"class":204,"line":285},[853,857,861,866,870,875,880,884,888,893,897,901,906,910,915,919,923,927],{"type":67,"tag":202,"props":854,"children":855},{"style":249},[856],{"type":79,"value":252},{"type":67,"tag":202,"props":858,"children":859},{"style":209},[860],{"type":79,"value":333},{"type":67,"tag":202,"props":862,"children":863},{"style":380},[864],{"type":79,"value":865}," data",{"type":67,"tag":202,"props":867,"children":868},{"style":209},[869],{"type":79,"value":402},{"type":67,"tag":202,"props":871,"children":872},{"style":215},[873],{"type":79,"value":874}," restaurant ",{"type":67,"tag":202,"props":876,"children":877},{"style":209},[878],{"type":79,"value":879},"}",{"type":67,"tag":202,"props":881,"children":882},{"style":209},[883],{"type":79,"value":348},{"type":67,"tag":202,"props":885,"children":886},{"style":351},[887],{"type":79,"value":354},{"type":67,"tag":202,"props":889,"children":890},{"style":264},[891],{"type":79,"value":892}," useAsyncData",{"type":67,"tag":202,"props":894,"children":895},{"style":215},[896],{"type":79,"value":383},{"type":67,"tag":202,"props":898,"children":899},{"style":209},[900],{"type":79,"value":417},{"type":67,"tag":202,"props":902,"children":903},{"style":231},[904],{"type":79,"value":905},"restaurant",{"type":67,"tag":202,"props":907,"children":908},{"style":209},[909],{"type":79,"value":417},{"type":67,"tag":202,"props":911,"children":912},{"style":209},[913],{"type":79,"value":914},",",{"type":67,"tag":202,"props":916,"children":917},{"style":249},[918],{"type":79,"value":304},{"type":67,"tag":202,"props":920,"children":921},{"style":209},[922],{"type":79,"value":309},{"type":67,"tag":202,"props":924,"children":925},{"style":249},[926],{"type":79,"value":314},{"type":67,"tag":202,"props":928,"children":929},{"style":209},[930],{"type":79,"value":319},{"type":67,"tag":202,"props":932,"children":933},{"class":204,"line":322},[934,938,942,946,950,954,958,963,967,972,976,980,985,989,994,998,1002,1006,1010,1015,1019,1023,1027,1032,1036,1040,1045,1049,1053,1057,1062,1066,1070,1074,1079],{"type":67,"tag":202,"props":935,"children":936},{"style":249},[937],{"type":79,"value":328},{"type":67,"tag":202,"props":939,"children":940},{"style":209},[941],{"type":79,"value":333},{"type":67,"tag":202,"props":943,"children":944},{"style":215},[945],{"type":79,"value":865},{"type":67,"tag":202,"props":947,"children":948},{"style":209},[949],{"type":79,"value":343},{"type":67,"tag":202,"props":951,"children":952},{"style":209},[953],{"type":79,"value":348},{"type":67,"tag":202,"props":955,"children":956},{"style":351},[957],{"type":79,"value":354},{"type":67,"tag":202,"props":959,"children":960},{"style":215},[961],{"type":79,"value":962}," client",{"type":67,"tag":202,"props":964,"children":965},{"style":209},[966],{"type":79,"value":105},{"type":67,"tag":202,"props":968,"children":969},{"style":264},[970],{"type":79,"value":971},"from",{"type":67,"tag":202,"props":973,"children":974},{"style":380},[975],{"type":79,"value":383},{"type":67,"tag":202,"props":977,"children":978},{"style":209},[979],{"type":79,"value":417},{"type":67,"tag":202,"props":981,"children":982},{"style":231},[983],{"type":79,"value":984},"restaurants",{"type":67,"tag":202,"props":986,"children":987},{"style":209},[988],{"type":79,"value":417},{"type":67,"tag":202,"props":990,"children":991},{"style":380},[992],{"type":79,"value":993},")",{"type":67,"tag":202,"props":995,"children":996},{"style":209},[997],{"type":79,"value":105},{"type":67,"tag":202,"props":999,"children":1000},{"style":264},[1001],{"type":79,"value":757},{"type":67,"tag":202,"props":1003,"children":1004},{"style":380},[1005],{"type":79,"value":383},{"type":67,"tag":202,"props":1007,"children":1008},{"style":209},[1009],{"type":79,"value":417},{"type":67,"tag":202,"props":1011,"children":1012},{"style":231},[1013],{"type":79,"value":1014},"name, location",{"type":67,"tag":202,"props":1016,"children":1017},{"style":209},[1018],{"type":79,"value":417},{"type":67,"tag":202,"props":1020,"children":1021},{"style":380},[1022],{"type":79,"value":993},{"type":67,"tag":202,"props":1024,"children":1025},{"style":209},[1026],{"type":79,"value":105},{"type":67,"tag":202,"props":1028,"children":1029},{"style":264},[1030],{"type":79,"value":1031},"eq",{"type":67,"tag":202,"props":1033,"children":1034},{"style":380},[1035],{"type":79,"value":383},{"type":67,"tag":202,"props":1037,"children":1038},{"style":209},[1039],{"type":79,"value":417},{"type":67,"tag":202,"props":1041,"children":1042},{"style":231},[1043],{"type":79,"value":1044},"name",{"type":67,"tag":202,"props":1046,"children":1047},{"style":209},[1048],{"type":79,"value":417},{"type":67,"tag":202,"props":1050,"children":1051},{"style":209},[1052],{"type":79,"value":914},{"type":67,"tag":202,"props":1054,"children":1055},{"style":209},[1056],{"type":79,"value":407},{"type":67,"tag":202,"props":1058,"children":1059},{"style":231},[1060],{"type":79,"value":1061},"My Restaurant Name",{"type":67,"tag":202,"props":1063,"children":1064},{"style":209},[1065],{"type":79,"value":417},{"type":67,"tag":202,"props":1067,"children":1068},{"style":380},[1069],{"type":79,"value":993},{"type":67,"tag":202,"props":1071,"children":1072},{"style":209},[1073],{"type":79,"value":105},{"type":67,"tag":202,"props":1075,"children":1076},{"style":264},[1077],{"type":79,"value":1078},"single",{"type":67,"tag":202,"props":1080,"children":1081},{"style":380},[1082],{"type":79,"value":272},{"type":67,"tag":202,"props":1084,"children":1085},{"class":204,"line":391},[1086],{"type":67,"tag":202,"props":1087,"children":1088},{"emptyLinePlaceholder":279},[1089],{"type":79,"value":282},{"type":67,"tag":202,"props":1091,"children":1092},{"class":204,"line":425},[1093,1098],{"type":67,"tag":202,"props":1094,"children":1095},{"style":351},[1096],{"type":79,"value":1097}," return",{"type":67,"tag":202,"props":1099,"children":1100},{"style":215},[1101],{"type":79,"value":1102}," data\n",{"type":67,"tag":202,"props":1104,"children":1105},{"class":204,"line":442},[1106,1110],{"type":67,"tag":202,"props":1107,"children":1108},{"style":209},[1109],{"type":79,"value":879},{"type":67,"tag":202,"props":1111,"children":1112},{"style":215},[1113],{"type":79,"value":492},{"type":67,"tag":202,"props":1115,"children":1116},{"class":204,"line":472},[1117,1121,1125],{"type":67,"tag":202,"props":1118,"children":1119},{"style":209},[1120],{"type":79,"value":706},{"type":67,"tag":202,"props":1122,"children":1123},{"style":380},[1124],{"type":79,"value":711},{"type":67,"tag":202,"props":1126,"children":1127},{"style":209},[1128],{"type":79,"value":242},{"type":67,"tag":147,"props":1130,"children":1132},{"id":1131},"realtime",[1133],{"type":79,"value":1134},"Realtime",{"type":67,"tag":68,"props":1136,"children":1137},{},[1138,1140,1147],{"type":79,"value":1139},"Based on ",{"type":67,"tag":72,"props":1141,"children":1144},{"href":1142,"rel":1143},"https://github.com/supabase/realtime",[76],[1145],{"type":79,"value":1146},"Supabase Realtime",{"type":79,"value":1148},", listen to changes in your PostgreSQL Database and broadcasts them over WebSockets.",{"type":67,"tag":68,"props":1150,"children":1151},{},[1152,1154,1161],{"type":79,"value":1153},"To enable it, make sure you have turned on the ",{"type":67,"tag":72,"props":1155,"children":1158},{"href":1156,"rel":1157},"https://supabase.com/docs/guides/api#realtime-api",[76],[1159],{"type":79,"value":1160},"Realtime API",{"type":79,"value":1162}," for your table.",{"type":67,"tag":68,"props":1164,"children":1165},{},[1166],{"type":79,"value":1167},"Then, listen to changes directly in your vue page / component:",{"type":67,"tag":192,"props":1169,"children":1171},{"className":771,"code":1170,"language":773,"meta":61,"style":61},"\u003Cscript setup lang=\"ts\">\nimport type { RealtimeChannel } from '@supabase/supabase-js'\n\nconst client = useSupabaseClient()\n\nlet realtimeChannel: RealtimeChannel\n\n// Fetch collaborators and get the refresh method provided by useAsyncData\nconst { data: collaborators, refresh: refreshCollaborators } = await useAsyncData('collaborators', async () => {\n const { data } = await client.from('collaborators').select('name')\n return data\n})\n\n// Once page is mounted, listen to changes on the `collaborators` table and refresh collaborators when receiving event\nonMounted(() => {\n // Real time listener for new workouts\n realtimeChannel = client.channel('public:collaborators').on(\n 'postgres_changes',\n { event: '*', schema: 'public', table: 'collaborators' },\n () => refreshCollaborators()\n )\n\n realtimeChannel.subscribe()\n})\n\n // Don't forget to unsubscribe when user left the page\nonUnmounted(() => {\n client.removeChannel(realtimeChannel)\n})\n\u003C/script>\n",[1172],{"type":67,"tag":116,"props":1173,"children":1174},{"__ignoreMap":61},[1175,1214,1259,1266,1289,1296,1319,1326,1335,1430,1517,1528,1539,1546,1554,1579,1587,1647,1668,1755,1777,1786,1794,1815,1827,1835,1844,1869,1900,1912],{"type":67,"tag":202,"props":1176,"children":1177},{"class":204,"line":205},[1178,1182,1186,1190,1194,1198,1202,1206,1210],{"type":67,"tag":202,"props":1179,"children":1180},{"style":209},[1181],{"type":79,"value":212},{"type":67,"tag":202,"props":1183,"children":1184},{"style":380},[1185],{"type":79,"value":711},{"type":67,"tag":202,"props":1187,"children":1188},{"style":249},[1189],{"type":79,"value":793},{"type":67,"tag":202,"props":1191,"children":1192},{"style":249},[1193],{"type":79,"value":798},{"type":67,"tag":202,"props":1195,"children":1196},{"style":209},[1197],{"type":79,"value":223},{"type":67,"tag":202,"props":1199,"children":1200},{"style":209},[1201],{"type":79,"value":228},{"type":67,"tag":202,"props":1203,"children":1204},{"style":231},[1205],{"type":79,"value":196},{"type":67,"tag":202,"props":1207,"children":1208},{"style":209},[1209],{"type":79,"value":228},{"type":67,"tag":202,"props":1211,"children":1212},{"style":209},[1213],{"type":79,"value":242},{"type":67,"tag":202,"props":1215,"children":1216},{"class":204,"line":245},[1217,1222,1227,1231,1236,1240,1245,1249,1254],{"type":67,"tag":202,"props":1218,"children":1219},{"style":351},[1220],{"type":79,"value":1221},"import",{"type":67,"tag":202,"props":1223,"children":1224},{"style":351},[1225],{"type":79,"value":1226}," type",{"type":67,"tag":202,"props":1228,"children":1229},{"style":209},[1230],{"type":79,"value":333},{"type":67,"tag":202,"props":1232,"children":1233},{"style":215},[1234],{"type":79,"value":1235}," RealtimeChannel",{"type":67,"tag":202,"props":1237,"children":1238},{"style":209},[1239],{"type":79,"value":343},{"type":67,"tag":202,"props":1241,"children":1242},{"style":351},[1243],{"type":79,"value":1244}," from",{"type":67,"tag":202,"props":1246,"children":1247},{"style":209},[1248],{"type":79,"value":407},{"type":67,"tag":202,"props":1250,"children":1251},{"style":231},[1252],{"type":79,"value":1253},"@supabase/supabase-js",{"type":67,"tag":202,"props":1255,"children":1256},{"style":209},[1257],{"type":79,"value":1258},"'\n",{"type":67,"tag":202,"props":1260,"children":1261},{"class":204,"line":275},[1262],{"type":67,"tag":202,"props":1263,"children":1264},{"emptyLinePlaceholder":279},[1265],{"type":79,"value":282},{"type":67,"tag":202,"props":1267,"children":1268},{"class":204,"line":285},[1269,1273,1277,1281,1285],{"type":67,"tag":202,"props":1270,"children":1271},{"style":249},[1272],{"type":79,"value":252},{"type":67,"tag":202,"props":1274,"children":1275},{"style":215},[1276],{"type":79,"value":830},{"type":67,"tag":202,"props":1278,"children":1279},{"style":209},[1280],{"type":79,"value":223},{"type":67,"tag":202,"props":1282,"children":1283},{"style":264},[1284],{"type":79,"value":267},{"type":67,"tag":202,"props":1286,"children":1287},{"style":215},[1288],{"type":79,"value":272},{"type":67,"tag":202,"props":1290,"children":1291},{"class":204,"line":322},[1292],{"type":67,"tag":202,"props":1293,"children":1294},{"emptyLinePlaceholder":279},[1295],{"type":79,"value":282},{"type":67,"tag":202,"props":1297,"children":1298},{"class":204,"line":391},[1299,1304,1309,1313],{"type":67,"tag":202,"props":1300,"children":1301},{"style":249},[1302],{"type":79,"value":1303},"let",{"type":67,"tag":202,"props":1305,"children":1306},{"style":215},[1307],{"type":79,"value":1308}," realtimeChannel",{"type":67,"tag":202,"props":1310,"children":1311},{"style":209},[1312],{"type":79,"value":402},{"type":67,"tag":202,"props":1314,"children":1316},{"style":1315},"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B",[1317],{"type":79,"value":1318}," RealtimeChannel\n",{"type":67,"tag":202,"props":1320,"children":1321},{"class":204,"line":425},[1322],{"type":67,"tag":202,"props":1323,"children":1324},{"emptyLinePlaceholder":279},[1325],{"type":79,"value":282},{"type":67,"tag":202,"props":1327,"children":1328},{"class":204,"line":442},[1329],{"type":67,"tag":202,"props":1330,"children":1332},{"style":1331},"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[1333],{"type":79,"value":1334},"// Fetch collaborators and get the refresh method provided by useAsyncData\n",{"type":67,"tag":202,"props":1336,"children":1337},{"class":204,"line":472},[1338,1342,1346,1350,1354,1359,1363,1368,1372,1377,1381,1385,1389,1393,1397,1401,1406,1410,1414,1418,1422,1426],{"type":67,"tag":202,"props":1339,"children":1340},{"style":249},[1341],{"type":79,"value":252},{"type":67,"tag":202,"props":1343,"children":1344},{"style":209},[1345],{"type":79,"value":333},{"type":67,"tag":202,"props":1347,"children":1348},{"style":380},[1349],{"type":79,"value":865},{"type":67,"tag":202,"props":1351,"children":1352},{"style":209},[1353],{"type":79,"value":402},{"type":67,"tag":202,"props":1355,"children":1356},{"style":215},[1357],{"type":79,"value":1358}," collaborators",{"type":67,"tag":202,"props":1360,"children":1361},{"style":209},[1362],{"type":79,"value":914},{"type":67,"tag":202,"props":1364,"children":1365},{"style":380},[1366],{"type":79,"value":1367}," refresh",{"type":67,"tag":202,"props":1369,"children":1370},{"style":209},[1371],{"type":79,"value":402},{"type":67,"tag":202,"props":1373,"children":1374},{"style":215},[1375],{"type":79,"value":1376}," refreshCollaborators ",{"type":67,"tag":202,"props":1378,"children":1379},{"style":209},[1380],{"type":79,"value":879},{"type":67,"tag":202,"props":1382,"children":1383},{"style":209},[1384],{"type":79,"value":348},{"type":67,"tag":202,"props":1386,"children":1387},{"style":351},[1388],{"type":79,"value":354},{"type":67,"tag":202,"props":1390,"children":1391},{"style":264},[1392],{"type":79,"value":892},{"type":67,"tag":202,"props":1394,"children":1395},{"style":215},[1396],{"type":79,"value":383},{"type":67,"tag":202,"props":1398,"children":1399},{"style":209},[1400],{"type":79,"value":417},{"type":67,"tag":202,"props":1402,"children":1403},{"style":231},[1404],{"type":79,"value":1405},"collaborators",{"type":67,"tag":202,"props":1407,"children":1408},{"style":209},[1409],{"type":79,"value":417},{"type":67,"tag":202,"props":1411,"children":1412},{"style":209},[1413],{"type":79,"value":914},{"type":67,"tag":202,"props":1415,"children":1416},{"style":249},[1417],{"type":79,"value":304},{"type":67,"tag":202,"props":1419,"children":1420},{"style":209},[1421],{"type":79,"value":309},{"type":67,"tag":202,"props":1423,"children":1424},{"style":249},[1425],{"type":79,"value":314},{"type":67,"tag":202,"props":1427,"children":1428},{"style":209},[1429],{"type":79,"value":319},{"type":67,"tag":202,"props":1431,"children":1432},{"class":204,"line":481},[1433,1437,1441,1445,1449,1453,1457,1461,1465,1469,1473,1477,1481,1485,1489,1493,1497,1501,1505,1509,1513],{"type":67,"tag":202,"props":1434,"children":1435},{"style":249},[1436],{"type":79,"value":328},{"type":67,"tag":202,"props":1438,"children":1439},{"style":209},[1440],{"type":79,"value":333},{"type":67,"tag":202,"props":1442,"children":1443},{"style":215},[1444],{"type":79,"value":865},{"type":67,"tag":202,"props":1446,"children":1447},{"style":209},[1448],{"type":79,"value":343},{"type":67,"tag":202,"props":1450,"children":1451},{"style":209},[1452],{"type":79,"value":348},{"type":67,"tag":202,"props":1454,"children":1455},{"style":351},[1456],{"type":79,"value":354},{"type":67,"tag":202,"props":1458,"children":1459},{"style":215},[1460],{"type":79,"value":962},{"type":67,"tag":202,"props":1462,"children":1463},{"style":209},[1464],{"type":79,"value":105},{"type":67,"tag":202,"props":1466,"children":1467},{"style":264},[1468],{"type":79,"value":971},{"type":67,"tag":202,"props":1470,"children":1471},{"style":380},[1472],{"type":79,"value":383},{"type":67,"tag":202,"props":1474,"children":1475},{"style":209},[1476],{"type":79,"value":417},{"type":67,"tag":202,"props":1478,"children":1479},{"style":231},[1480],{"type":79,"value":1405},{"type":67,"tag":202,"props":1482,"children":1483},{"style":209},[1484],{"type":79,"value":417},{"type":67,"tag":202,"props":1486,"children":1487},{"style":380},[1488],{"type":79,"value":993},{"type":67,"tag":202,"props":1490,"children":1491},{"style":209},[1492],{"type":79,"value":105},{"type":67,"tag":202,"props":1494,"children":1495},{"style":264},[1496],{"type":79,"value":757},{"type":67,"tag":202,"props":1498,"children":1499},{"style":380},[1500],{"type":79,"value":383},{"type":67,"tag":202,"props":1502,"children":1503},{"style":209},[1504],{"type":79,"value":417},{"type":67,"tag":202,"props":1506,"children":1507},{"style":231},[1508],{"type":79,"value":1044},{"type":67,"tag":202,"props":1510,"children":1511},{"style":209},[1512],{"type":79,"value":417},{"type":67,"tag":202,"props":1514,"children":1515},{"style":380},[1516],{"type":79,"value":492},{"type":67,"tag":202,"props":1518,"children":1519},{"class":204,"line":495},[1520,1524],{"type":67,"tag":202,"props":1521,"children":1522},{"style":351},[1523],{"type":79,"value":1097},{"type":67,"tag":202,"props":1525,"children":1526},{"style":215},[1527],{"type":79,"value":1102},{"type":67,"tag":202,"props":1529,"children":1530},{"class":204,"line":545},[1531,1535],{"type":67,"tag":202,"props":1532,"children":1533},{"style":209},[1534],{"type":79,"value":879},{"type":67,"tag":202,"props":1536,"children":1537},{"style":215},[1538],{"type":79,"value":492},{"type":67,"tag":202,"props":1540,"children":1541},{"class":204,"line":554},[1542],{"type":67,"tag":202,"props":1543,"children":1544},{"emptyLinePlaceholder":279},[1545],{"type":79,"value":282},{"type":67,"tag":202,"props":1547,"children":1548},{"class":204,"line":562},[1549],{"type":67,"tag":202,"props":1550,"children":1551},{"style":1331},[1552],{"type":79,"value":1553},"// Once page is mounted, listen to changes on the `collaborators` table and refresh collaborators when receiving event\n",{"type":67,"tag":202,"props":1555,"children":1556},{"class":204,"line":595},[1557,1562,1566,1571,1575],{"type":67,"tag":202,"props":1558,"children":1559},{"style":264},[1560],{"type":79,"value":1561},"onMounted",{"type":67,"tag":202,"props":1563,"children":1564},{"style":215},[1565],{"type":79,"value":383},{"type":67,"tag":202,"props":1567,"children":1568},{"style":209},[1569],{"type":79,"value":1570},"()",{"type":67,"tag":202,"props":1572,"children":1573},{"style":249},[1574],{"type":79,"value":314},{"type":67,"tag":202,"props":1576,"children":1577},{"style":209},[1578],{"type":79,"value":319},{"type":67,"tag":202,"props":1580,"children":1581},{"class":204,"line":648},[1582],{"type":67,"tag":202,"props":1583,"children":1584},{"style":1331},[1585],{"type":79,"value":1586}," // Real time listener for new workouts\n",{"type":67,"tag":202,"props":1588,"children":1589},{"class":204,"line":692},[1590,1595,1599,1603,1607,1612,1616,1620,1625,1629,1633,1637,1642],{"type":67,"tag":202,"props":1591,"children":1592},{"style":215},[1593],{"type":79,"value":1594}," realtimeChannel",{"type":67,"tag":202,"props":1596,"children":1597},{"style":209},[1598],{"type":79,"value":348},{"type":67,"tag":202,"props":1600,"children":1601},{"style":215},[1602],{"type":79,"value":962},{"type":67,"tag":202,"props":1604,"children":1605},{"style":209},[1606],{"type":79,"value":105},{"type":67,"tag":202,"props":1608,"children":1609},{"style":264},[1610],{"type":79,"value":1611},"channel",{"type":67,"tag":202,"props":1613,"children":1614},{"style":380},[1615],{"type":79,"value":383},{"type":67,"tag":202,"props":1617,"children":1618},{"style":209},[1619],{"type":79,"value":417},{"type":67,"tag":202,"props":1621,"children":1622},{"style":231},[1623],{"type":79,"value":1624},"public:collaborators",{"type":67,"tag":202,"props":1626,"children":1627},{"style":209},[1628],{"type":79,"value":417},{"type":67,"tag":202,"props":1630,"children":1631},{"style":380},[1632],{"type":79,"value":993},{"type":67,"tag":202,"props":1634,"children":1635},{"style":209},[1636],{"type":79,"value":105},{"type":67,"tag":202,"props":1638,"children":1639},{"style":264},[1640],{"type":79,"value":1641},"on",{"type":67,"tag":202,"props":1643,"children":1644},{"style":380},[1645],{"type":79,"value":1646},"(\n",{"type":67,"tag":202,"props":1648,"children":1649},{"class":204,"line":700},[1650,1655,1660,1664],{"type":67,"tag":202,"props":1651,"children":1652},{"style":209},[1653],{"type":79,"value":1654}," '",{"type":67,"tag":202,"props":1656,"children":1657},{"style":231},[1658],{"type":79,"value":1659},"postgres_changes",{"type":67,"tag":202,"props":1661,"children":1662},{"style":209},[1663],{"type":79,"value":417},{"type":67,"tag":202,"props":1665,"children":1666},{"style":209},[1667],{"type":79,"value":422},{"type":67,"tag":202,"props":1669,"children":1671},{"class":204,"line":1670},19,[1672,1677,1682,1686,1690,1695,1699,1703,1708,1712,1716,1721,1725,1729,1734,1738,1742,1746,1750],{"type":67,"tag":202,"props":1673,"children":1674},{"style":209},[1675],{"type":79,"value":1676}," {",{"type":67,"tag":202,"props":1678,"children":1679},{"style":380},[1680],{"type":79,"value":1681}," event",{"type":67,"tag":202,"props":1683,"children":1684},{"style":209},[1685],{"type":79,"value":402},{"type":67,"tag":202,"props":1687,"children":1688},{"style":209},[1689],{"type":79,"value":407},{"type":67,"tag":202,"props":1691,"children":1692},{"style":231},[1693],{"type":79,"value":1694},"*",{"type":67,"tag":202,"props":1696,"children":1697},{"style":209},[1698],{"type":79,"value":417},{"type":67,"tag":202,"props":1700,"children":1701},{"style":209},[1702],{"type":79,"value":914},{"type":67,"tag":202,"props":1704,"children":1705},{"style":380},[1706],{"type":79,"value":1707}," schema",{"type":67,"tag":202,"props":1709,"children":1710},{"style":209},[1711],{"type":79,"value":402},{"type":67,"tag":202,"props":1713,"children":1714},{"style":209},[1715],{"type":79,"value":407},{"type":67,"tag":202,"props":1717,"children":1718},{"style":231},[1719],{"type":79,"value":1720},"public",{"type":67,"tag":202,"props":1722,"children":1723},{"style":209},[1724],{"type":79,"value":417},{"type":67,"tag":202,"props":1726,"children":1727},{"style":209},[1728],{"type":79,"value":914},{"type":67,"tag":202,"props":1730,"children":1731},{"style":380},[1732],{"type":79,"value":1733}," table",{"type":67,"tag":202,"props":1735,"children":1736},{"style":209},[1737],{"type":79,"value":402},{"type":67,"tag":202,"props":1739,"children":1740},{"style":209},[1741],{"type":79,"value":407},{"type":67,"tag":202,"props":1743,"children":1744},{"style":231},[1745],{"type":79,"value":1405},{"type":67,"tag":202,"props":1747,"children":1748},{"style":209},[1749],{"type":79,"value":417},{"type":67,"tag":202,"props":1751,"children":1752},{"style":209},[1753],{"type":79,"value":1754}," },\n",{"type":67,"tag":202,"props":1756,"children":1758},{"class":204,"line":1757},20,[1759,1764,1768,1773],{"type":67,"tag":202,"props":1760,"children":1761},{"style":209},[1762],{"type":79,"value":1763}," ()",{"type":67,"tag":202,"props":1765,"children":1766},{"style":249},[1767],{"type":79,"value":314},{"type":67,"tag":202,"props":1769,"children":1770},{"style":264},[1771],{"type":79,"value":1772}," refreshCollaborators",{"type":67,"tag":202,"props":1774,"children":1775},{"style":380},[1776],{"type":79,"value":272},{"type":67,"tag":202,"props":1778,"children":1780},{"class":204,"line":1779},21,[1781],{"type":67,"tag":202,"props":1782,"children":1783},{"style":380},[1784],{"type":79,"value":1785}," )\n",{"type":67,"tag":202,"props":1787,"children":1789},{"class":204,"line":1788},22,[1790],{"type":67,"tag":202,"props":1791,"children":1792},{"emptyLinePlaceholder":279},[1793],{"type":79,"value":282},{"type":67,"tag":202,"props":1795,"children":1797},{"class":204,"line":1796},23,[1798,1802,1806,1811],{"type":67,"tag":202,"props":1799,"children":1800},{"style":215},[1801],{"type":79,"value":1594},{"type":67,"tag":202,"props":1803,"children":1804},{"style":209},[1805],{"type":79,"value":105},{"type":67,"tag":202,"props":1807,"children":1808},{"style":264},[1809],{"type":79,"value":1810},"subscribe",{"type":67,"tag":202,"props":1812,"children":1813},{"style":380},[1814],{"type":79,"value":272},{"type":67,"tag":202,"props":1816,"children":1818},{"class":204,"line":1817},24,[1819,1823],{"type":67,"tag":202,"props":1820,"children":1821},{"style":209},[1822],{"type":79,"value":879},{"type":67,"tag":202,"props":1824,"children":1825},{"style":215},[1826],{"type":79,"value":492},{"type":67,"tag":202,"props":1828,"children":1830},{"class":204,"line":1829},25,[1831],{"type":67,"tag":202,"props":1832,"children":1833},{"emptyLinePlaceholder":279},[1834],{"type":79,"value":282},{"type":67,"tag":202,"props":1836,"children":1838},{"class":204,"line":1837},26,[1839],{"type":67,"tag":202,"props":1840,"children":1841},{"style":1331},[1842],{"type":79,"value":1843}," // Don't forget to unsubscribe when user left the page\n",{"type":67,"tag":202,"props":1845,"children":1847},{"class":204,"line":1846},27,[1848,1853,1857,1861,1865],{"type":67,"tag":202,"props":1849,"children":1850},{"style":264},[1851],{"type":79,"value":1852},"onUnmounted",{"type":67,"tag":202,"props":1854,"children":1855},{"style":215},[1856],{"type":79,"value":383},{"type":67,"tag":202,"props":1858,"children":1859},{"style":209},[1860],{"type":79,"value":1570},{"type":67,"tag":202,"props":1862,"children":1863},{"style":249},[1864],{"type":79,"value":314},{"type":67,"tag":202,"props":1866,"children":1867},{"style":209},[1868],{"type":79,"value":319},{"type":67,"tag":202,"props":1870,"children":1872},{"class":204,"line":1871},28,[1873,1878,1882,1887,1891,1896],{"type":67,"tag":202,"props":1874,"children":1875},{"style":215},[1876],{"type":79,"value":1877}," client",{"type":67,"tag":202,"props":1879,"children":1880},{"style":209},[1881],{"type":79,"value":105},{"type":67,"tag":202,"props":1883,"children":1884},{"style":264},[1885],{"type":79,"value":1886},"removeChannel",{"type":67,"tag":202,"props":1888,"children":1889},{"style":380},[1890],{"type":79,"value":383},{"type":67,"tag":202,"props":1892,"children":1893},{"style":215},[1894],{"type":79,"value":1895},"realtimeChannel",{"type":67,"tag":202,"props":1897,"children":1898},{"style":380},[1899],{"type":79,"value":492},{"type":67,"tag":202,"props":1901,"children":1903},{"class":204,"line":1902},29,[1904,1908],{"type":67,"tag":202,"props":1905,"children":1906},{"style":209},[1907],{"type":79,"value":879},{"type":67,"tag":202,"props":1909,"children":1910},{"style":215},[1911],{"type":79,"value":492},{"type":67,"tag":202,"props":1913,"children":1915},{"class":204,"line":1914},30,[1916,1920,1924],{"type":67,"tag":202,"props":1917,"children":1918},{"style":209},[1919],{"type":79,"value":706},{"type":67,"tag":202,"props":1921,"children":1922},{"style":380},[1923],{"type":79,"value":711},{"type":67,"tag":202,"props":1925,"children":1926},{"style":209},[1927],{"type":79,"value":242},{"type":67,"tag":147,"props":1929,"children":1931},{"id":1930},"typescript",[1932],{"type":79,"value":1933},"Typescript",{"type":67,"tag":68,"props":1935,"children":1936},{},[1937,1939,1945,1947,1953,1955,1962],{"type":79,"value":1938},"Database typings are passed to the client out of the box if the database generated types are found at ",{"type":67,"tag":116,"props":1940,"children":1942},{"className":1941},[],[1943],{"type":79,"value":1944},"./types/database.types.ts",{"type":79,"value":1946}," or ",{"type":67,"tag":72,"props":1948,"children":1950},{"href":1949},"/get-started#types",[1951],{"type":79,"value":1952},"your configured types path",{"type":79,"value":1954},". Check Supabase ",{"type":67,"tag":72,"props":1956,"children":1959},{"href":1957,"rel":1958},"https://supabase.com/docs/reference/javascript/release-notes#typescript-support",[76],[1960],{"type":79,"value":1961},"documentation",{"type":79,"value":1963}," for further information.",{"type":67,"tag":192,"props":1965,"children":1969},{"className":1966,"code":1967,"language":1968,"meta":61,"style":61},"language-shell shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","## Generate types from live database\nsupabase gen types typescript --project-id YourProjectId > types/database.types.ts\n\n## Generate types when using local environment\nsupabase gen types typescript --local > types/database.types.ts\n","shell",[1970],{"type":67,"tag":116,"props":1971,"children":1972},{"__ignoreMap":61},[1973,1981,2024,2031,2039],{"type":67,"tag":202,"props":1974,"children":1975},{"class":204,"line":205},[1976],{"type":67,"tag":202,"props":1977,"children":1978},{"style":1331},[1979],{"type":79,"value":1980},"## Generate types from live database\n",{"type":67,"tag":202,"props":1982,"children":1983},{"class":204,"line":245},[1984,1989,1994,1999,2004,2009,2014,2019],{"type":67,"tag":202,"props":1985,"children":1986},{"style":1315},[1987],{"type":79,"value":1988},"supabase",{"type":67,"tag":202,"props":1990,"children":1991},{"style":231},[1992],{"type":79,"value":1993}," gen",{"type":67,"tag":202,"props":1995,"children":1996},{"style":231},[1997],{"type":79,"value":1998}," types",{"type":67,"tag":202,"props":2000,"children":2001},{"style":231},[2002],{"type":79,"value":2003}," typescript",{"type":67,"tag":202,"props":2005,"children":2006},{"style":231},[2007],{"type":79,"value":2008}," --project-id",{"type":67,"tag":202,"props":2010,"children":2011},{"style":231},[2012],{"type":79,"value":2013}," YourProjectId",{"type":67,"tag":202,"props":2015,"children":2016},{"style":209},[2017],{"type":79,"value":2018}," >",{"type":67,"tag":202,"props":2020,"children":2021},{"style":231},[2022],{"type":79,"value":2023}," types/database.types.ts\n",{"type":67,"tag":202,"props":2025,"children":2026},{"class":204,"line":275},[2027],{"type":67,"tag":202,"props":2028,"children":2029},{"emptyLinePlaceholder":279},[2030],{"type":79,"value":282},{"type":67,"tag":202,"props":2032,"children":2033},{"class":204,"line":285},[2034],{"type":67,"tag":202,"props":2035,"children":2036},{"style":1331},[2037],{"type":79,"value":2038},"## Generate types when using local environment\n",{"type":67,"tag":202,"props":2040,"children":2041},{"class":204,"line":322},[2042,2046,2050,2054,2058,2063,2067],{"type":67,"tag":202,"props":2043,"children":2044},{"style":1315},[2045],{"type":79,"value":1988},{"type":67,"tag":202,"props":2047,"children":2048},{"style":231},[2049],{"type":79,"value":1993},{"type":67,"tag":202,"props":2051,"children":2052},{"style":231},[2053],{"type":79,"value":1998},{"type":67,"tag":202,"props":2055,"children":2056},{"style":231},[2057],{"type":79,"value":2003},{"type":67,"tag":202,"props":2059,"children":2060},{"style":231},[2061],{"type":79,"value":2062}," --local",{"type":67,"tag":202,"props":2064,"children":2065},{"style":209},[2066],{"type":79,"value":2018},{"type":67,"tag":202,"props":2068,"children":2069},{"style":231},[2070],{"type":79,"value":2023},{"type":67,"tag":68,"props":2072,"children":2073},{},[2074],{"type":79,"value":2075},"You can also pass Database typings to the client manually:",{"type":67,"tag":192,"props":2077,"children":2079},{"className":771,"code":2078,"language":773,"meta":61,"style":61},"\u003Cscript setup lang=\"ts\">\nimport type { Database } from '~/types'\nconst client = useSupabaseClient\u003CDatabase>()\n\u003C/script>\n",[2080],{"type":67,"tag":116,"props":2081,"children":2082},{"__ignoreMap":61},[2083,2122,2163,2200],{"type":67,"tag":202,"props":2084,"children":2085},{"class":204,"line":205},[2086,2090,2094,2098,2102,2106,2110,2114,2118],{"type":67,"tag":202,"props":2087,"children":2088},{"style":209},[2089],{"type":79,"value":212},{"type":67,"tag":202,"props":2091,"children":2092},{"style":380},[2093],{"type":79,"value":711},{"type":67,"tag":202,"props":2095,"children":2096},{"style":249},[2097],{"type":79,"value":793},{"type":67,"tag":202,"props":2099,"children":2100},{"style":249},[2101],{"type":79,"value":798},{"type":67,"tag":202,"props":2103,"children":2104},{"style":209},[2105],{"type":79,"value":223},{"type":67,"tag":202,"props":2107,"children":2108},{"style":209},[2109],{"type":79,"value":228},{"type":67,"tag":202,"props":2111,"children":2112},{"style":231},[2113],{"type":79,"value":196},{"type":67,"tag":202,"props":2115,"children":2116},{"style":209},[2117],{"type":79,"value":228},{"type":67,"tag":202,"props":2119,"children":2120},{"style":209},[2121],{"type":79,"value":242},{"type":67,"tag":202,"props":2123,"children":2124},{"class":204,"line":245},[2125,2129,2133,2137,2142,2146,2150,2154,2159],{"type":67,"tag":202,"props":2126,"children":2127},{"style":351},[2128],{"type":79,"value":1221},{"type":67,"tag":202,"props":2130,"children":2131},{"style":351},[2132],{"type":79,"value":1226},{"type":67,"tag":202,"props":2134,"children":2135},{"style":209},[2136],{"type":79,"value":333},{"type":67,"tag":202,"props":2138,"children":2139},{"style":215},[2140],{"type":79,"value":2141}," Database",{"type":67,"tag":202,"props":2143,"children":2144},{"style":209},[2145],{"type":79,"value":343},{"type":67,"tag":202,"props":2147,"children":2148},{"style":351},[2149],{"type":79,"value":1244},{"type":67,"tag":202,"props":2151,"children":2152},{"style":209},[2153],{"type":79,"value":407},{"type":67,"tag":202,"props":2155,"children":2156},{"style":231},[2157],{"type":79,"value":2158},"~/types",{"type":67,"tag":202,"props":2160,"children":2161},{"style":209},[2162],{"type":79,"value":1258},{"type":67,"tag":202,"props":2164,"children":2165},{"class":204,"line":275},[2166,2170,2174,2178,2182,2186,2191,2196],{"type":67,"tag":202,"props":2167,"children":2168},{"style":249},[2169],{"type":79,"value":252},{"type":67,"tag":202,"props":2171,"children":2172},{"style":215},[2173],{"type":79,"value":830},{"type":67,"tag":202,"props":2175,"children":2176},{"style":209},[2177],{"type":79,"value":223},{"type":67,"tag":202,"props":2179,"children":2180},{"style":264},[2181],{"type":79,"value":267},{"type":67,"tag":202,"props":2183,"children":2184},{"style":209},[2185],{"type":79,"value":212},{"type":67,"tag":202,"props":2187,"children":2188},{"style":1315},[2189],{"type":79,"value":2190},"Database",{"type":67,"tag":202,"props":2192,"children":2193},{"style":209},[2194],{"type":79,"value":2195},">",{"type":67,"tag":202,"props":2197,"children":2198},{"style":215},[2199],{"type":79,"value":272},{"type":67,"tag":202,"props":2201,"children":2202},{"class":204,"line":285},[2203,2207,2211],{"type":67,"tag":202,"props":2204,"children":2205},{"style":209},[2206],{"type":79,"value":706},{"type":67,"tag":202,"props":2208,"children":2209},{"style":380},[2210],{"type":79,"value":711},{"type":67,"tag":202,"props":2212,"children":2213},{"style":209},[2214],{"type":79,"value":242},{"type":67,"tag":2216,"props":2217,"children":2218},"style",{},[2219],{"type":79,"value":2220},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":61,"searchDepth":245,"depth":245,"links":2222},[2223,2224,2225,2226],{"id":149,"depth":245,"text":9},{"id":729,"depth":245,"text":732},{"id":1131,"depth":245,"text":1134},{"id":1930,"depth":245,"text":1933},"markdown","content:4.usage:composables:useSupabaseClient.md","content","4.usage/composables/useSupabaseClient.md","4.usage/composables/useSupabaseClient","md",[2234,2236],{"_path":10,"title":9,"description":2235},"Authenticate your user thanks to the PKCE Oauth protocol that enables secure exchange of refresh and access tokens between an application and the authorization server",{"_path":25,"title":24,"description":2237},"Auto import and use your Supabase user's session with the useSupabaseSession composable",1724940863107] \ No newline at end of file +[{"data":1,"prerenderedAt":2238},["ShallowReactive",2],{"navigation":3,"/usage/composables/usesupabaseclient":58,"/usage/composables/usesupabaseclient-surround":2233},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":22,"_dir":59,"_draft":60,"_partial":60,"_locale":61,"title":21,"description":62,"body":63,"_type":2227,"_id":2228,"_source":2229,"_file":2230,"_stem":2231,"_extension":2232},"composables",false,"","Make requests to the Supabase API with the useSupabaseClient composable",{"type":64,"children":65,"toc":2221},"root",[66,83,106,146,152,174,191,716,727,733,747,769,1129,1135,1149,1163,1168,1928,1934,1964,2071,2076,2215],{"type":67,"tag":68,"props":69,"children":70},"element","p",{},[71,81],{"type":67,"tag":72,"props":73,"children":77},"a",{"href":74,"rel":75},"https://nuxt.com/docs/guide/directory-structure/composables",[76],"nofollow",[78],{"type":79,"value":80},"text","Auto-import",{"type":79,"value":82}," your client inside your vue files.",{"type":67,"tag":68,"props":84,"children":85},{},[86,88,95,97,104],{"type":79,"value":87},"This composable is using ",{"type":67,"tag":72,"props":89,"children":92},{"href":90,"rel":91},"https://github.com/supabase/supabase-js/",[76],[93],{"type":79,"value":94},"supabase-js",{"type":79,"value":96}," under the hood, it gives access to the ",{"type":67,"tag":72,"props":98,"children":101},{"href":99,"rel":100},"https://supabase.com/docs/reference/javascript/initializing",[76],[102],{"type":79,"value":103},"Supabase client",{"type":79,"value":105},".",{"type":67,"tag":107,"props":108,"children":109},"blockquote",{},[110],{"type":67,"tag":68,"props":111,"children":112},{},[113,115,122,124,130,132,139,141,145],{"type":79,"value":114},"The client is initialized with the ",{"type":67,"tag":116,"props":117,"children":119},"code",{"className":118},[],[120],{"type":79,"value":121},"SUPABASE_KEY",{"type":79,"value":123}," you must have in your ",{"type":67,"tag":116,"props":125,"children":127},{"className":126},[],[128],{"type":79,"value":129},".env",{"type":79,"value":131}," file. It establishes the connection with the database and make use of user JWT to apply ",{"type":67,"tag":72,"props":133,"children":136},{"href":134,"rel":135},"https://supabase.com/docs/learn/auth-deep-dive/auth-row-level-security",[76],[137],{"type":79,"value":138},"RLS Policies",{"type":79,"value":140}," implemented in Supabase. If you want to bypass policies, you can use the ",{"type":67,"tag":72,"props":142,"children":143},{"href":38},[144],{"type":79,"value":37},{"type":79,"value":105},{"type":67,"tag":147,"props":148,"children":150},"h2",{"id":149},"authentication",[151],{"type":79,"value":9},{"type":67,"tag":68,"props":153,"children":154},{},[155,157,163,165,172],{"type":79,"value":156},"The useSupabaseClient composable is providing all methods to manage authorization under ",{"type":67,"tag":116,"props":158,"children":160},{"className":159},[],[161],{"type":79,"value":162},"useSupabaseClient().auth",{"type":79,"value":164},". For more details please see the ",{"type":67,"tag":72,"props":166,"children":169},{"href":167,"rel":168},"https://supabase.com/docs/reference/javascript/auth-api",[76],[170],{"type":79,"value":171},"supabase-js auth documentation",{"type":79,"value":173},". Here is an example for signing in and out:",{"type":67,"tag":175,"props":176,"children":178},"callout",{"icon":177},"i-heroicons-light-bulb",[179],{"type":67,"tag":68,"props":180,"children":181},{},[182,184,190],{"type":79,"value":183},"If you want a full explanation on how to handle the authentication process, please read this ",{"type":67,"tag":72,"props":185,"children":187},{"href":186},"/get-started#handle-authentication",[188],{"type":79,"value":189},"section",{"type":79,"value":105},{"type":67,"tag":192,"props":193,"children":197},"pre",{"className":194,"code":195,"language":196,"meta":61,"style":61},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","\u003Cscript setup lang=\"ts\">\nconst supabase = useSupabaseClient()\n\nconst signInWithOAuth = async () => {\n const { error } = await supabase.auth.signInWithOAuth({\n provider: 'github',\n options: {\n redirectTo: 'http://localhost:3000/confirm',\n },\n })\n if (error) console.log(error)\n}\n\nconst signOut = async () => {\n const { error } = await supabase.auth.signOut()\n if (error) console.log(error)\n}\n\u003C/script>\n","ts",[198],{"type":67,"tag":116,"props":199,"children":200},{"__ignoreMap":61},[201,243,273,283,320,389,423,440,470,479,493,543,552,560,593,646,690,698],{"type":67,"tag":202,"props":203,"children":206},"span",{"class":204,"line":205},"line",1,[207,213,219,224,229,234,238],{"type":67,"tag":202,"props":208,"children":210},{"style":209},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[211],{"type":79,"value":212},"\u003C",{"type":67,"tag":202,"props":214,"children":216},{"style":215},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[217],{"type":79,"value":218},"script setup lang",{"type":67,"tag":202,"props":220,"children":221},{"style":209},[222],{"type":79,"value":223},"=",{"type":67,"tag":202,"props":225,"children":226},{"style":209},[227],{"type":79,"value":228},"\"",{"type":67,"tag":202,"props":230,"children":232},{"style":231},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[233],{"type":79,"value":196},{"type":67,"tag":202,"props":235,"children":236},{"style":209},[237],{"type":79,"value":228},{"type":67,"tag":202,"props":239,"children":240},{"style":209},[241],{"type":79,"value":242},">\n",{"type":67,"tag":202,"props":244,"children":246},{"class":204,"line":245},2,[247,253,258,262,268],{"type":67,"tag":202,"props":248,"children":250},{"style":249},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[251],{"type":79,"value":252},"const",{"type":67,"tag":202,"props":254,"children":255},{"style":215},[256],{"type":79,"value":257}," supabase ",{"type":67,"tag":202,"props":259,"children":260},{"style":209},[261],{"type":79,"value":223},{"type":67,"tag":202,"props":263,"children":265},{"style":264},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[266],{"type":79,"value":267}," useSupabaseClient",{"type":67,"tag":202,"props":269,"children":270},{"style":215},[271],{"type":79,"value":272},"()\n",{"type":67,"tag":202,"props":274,"children":276},{"class":204,"line":275},3,[277],{"type":67,"tag":202,"props":278,"children":280},{"emptyLinePlaceholder":279},true,[281],{"type":79,"value":282},"\n",{"type":67,"tag":202,"props":284,"children":286},{"class":204,"line":285},4,[287,291,296,300,305,310,315],{"type":67,"tag":202,"props":288,"children":289},{"style":249},[290],{"type":79,"value":252},{"type":67,"tag":202,"props":292,"children":293},{"style":215},[294],{"type":79,"value":295}," signInWithOAuth ",{"type":67,"tag":202,"props":297,"children":298},{"style":209},[299],{"type":79,"value":223},{"type":67,"tag":202,"props":301,"children":302},{"style":249},[303],{"type":79,"value":304}," async",{"type":67,"tag":202,"props":306,"children":307},{"style":209},[308],{"type":79,"value":309}," ()",{"type":67,"tag":202,"props":311,"children":312},{"style":249},[313],{"type":79,"value":314}," =>",{"type":67,"tag":202,"props":316,"children":317},{"style":209},[318],{"type":79,"value":319}," {\n",{"type":67,"tag":202,"props":321,"children":323},{"class":204,"line":322},5,[324,329,334,339,344,349,355,360,364,369,373,378,384],{"type":67,"tag":202,"props":325,"children":326},{"style":249},[327],{"type":79,"value":328}," const",{"type":67,"tag":202,"props":330,"children":331},{"style":209},[332],{"type":79,"value":333}," {",{"type":67,"tag":202,"props":335,"children":336},{"style":215},[337],{"type":79,"value":338}," error",{"type":67,"tag":202,"props":340,"children":341},{"style":209},[342],{"type":79,"value":343}," }",{"type":67,"tag":202,"props":345,"children":346},{"style":209},[347],{"type":79,"value":348}," =",{"type":67,"tag":202,"props":350,"children":352},{"style":351},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[353],{"type":79,"value":354}," await",{"type":67,"tag":202,"props":356,"children":357},{"style":215},[358],{"type":79,"value":359}," supabase",{"type":67,"tag":202,"props":361,"children":362},{"style":209},[363],{"type":79,"value":105},{"type":67,"tag":202,"props":365,"children":366},{"style":215},[367],{"type":79,"value":368},"auth",{"type":67,"tag":202,"props":370,"children":371},{"style":209},[372],{"type":79,"value":105},{"type":67,"tag":202,"props":374,"children":375},{"style":264},[376],{"type":79,"value":377},"signInWithOAuth",{"type":67,"tag":202,"props":379,"children":381},{"style":380},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[382],{"type":79,"value":383},"(",{"type":67,"tag":202,"props":385,"children":386},{"style":209},[387],{"type":79,"value":388},"{\n",{"type":67,"tag":202,"props":390,"children":392},{"class":204,"line":391},6,[393,398,403,408,413,418],{"type":67,"tag":202,"props":394,"children":395},{"style":380},[396],{"type":79,"value":397}," provider",{"type":67,"tag":202,"props":399,"children":400},{"style":209},[401],{"type":79,"value":402},":",{"type":67,"tag":202,"props":404,"children":405},{"style":209},[406],{"type":79,"value":407}," '",{"type":67,"tag":202,"props":409,"children":410},{"style":231},[411],{"type":79,"value":412},"github",{"type":67,"tag":202,"props":414,"children":415},{"style":209},[416],{"type":79,"value":417},"'",{"type":67,"tag":202,"props":419,"children":420},{"style":209},[421],{"type":79,"value":422},",\n",{"type":67,"tag":202,"props":424,"children":426},{"class":204,"line":425},7,[427,432,436],{"type":67,"tag":202,"props":428,"children":429},{"style":380},[430],{"type":79,"value":431}," options",{"type":67,"tag":202,"props":433,"children":434},{"style":209},[435],{"type":79,"value":402},{"type":67,"tag":202,"props":437,"children":438},{"style":209},[439],{"type":79,"value":319},{"type":67,"tag":202,"props":441,"children":443},{"class":204,"line":442},8,[444,449,453,457,462,466],{"type":67,"tag":202,"props":445,"children":446},{"style":380},[447],{"type":79,"value":448}," redirectTo",{"type":67,"tag":202,"props":450,"children":451},{"style":209},[452],{"type":79,"value":402},{"type":67,"tag":202,"props":454,"children":455},{"style":209},[456],{"type":79,"value":407},{"type":67,"tag":202,"props":458,"children":459},{"style":231},[460],{"type":79,"value":461},"http://localhost:3000/confirm",{"type":67,"tag":202,"props":463,"children":464},{"style":209},[465],{"type":79,"value":417},{"type":67,"tag":202,"props":467,"children":468},{"style":209},[469],{"type":79,"value":422},{"type":67,"tag":202,"props":471,"children":473},{"class":204,"line":472},9,[474],{"type":67,"tag":202,"props":475,"children":476},{"style":209},[477],{"type":79,"value":478}," },\n",{"type":67,"tag":202,"props":480,"children":482},{"class":204,"line":481},10,[483,488],{"type":67,"tag":202,"props":484,"children":485},{"style":209},[486],{"type":79,"value":487}," }",{"type":67,"tag":202,"props":489,"children":490},{"style":380},[491],{"type":79,"value":492},")\n",{"type":67,"tag":202,"props":494,"children":496},{"class":204,"line":495},11,[497,502,507,512,517,522,526,531,535,539],{"type":67,"tag":202,"props":498,"children":499},{"style":351},[500],{"type":79,"value":501}," if",{"type":67,"tag":202,"props":503,"children":504},{"style":380},[505],{"type":79,"value":506}," (",{"type":67,"tag":202,"props":508,"children":509},{"style":215},[510],{"type":79,"value":511},"error",{"type":67,"tag":202,"props":513,"children":514},{"style":380},[515],{"type":79,"value":516},") ",{"type":67,"tag":202,"props":518,"children":519},{"style":215},[520],{"type":79,"value":521},"console",{"type":67,"tag":202,"props":523,"children":524},{"style":209},[525],{"type":79,"value":105},{"type":67,"tag":202,"props":527,"children":528},{"style":264},[529],{"type":79,"value":530},"log",{"type":67,"tag":202,"props":532,"children":533},{"style":380},[534],{"type":79,"value":383},{"type":67,"tag":202,"props":536,"children":537},{"style":215},[538],{"type":79,"value":511},{"type":67,"tag":202,"props":540,"children":541},{"style":380},[542],{"type":79,"value":492},{"type":67,"tag":202,"props":544,"children":546},{"class":204,"line":545},12,[547],{"type":67,"tag":202,"props":548,"children":549},{"style":209},[550],{"type":79,"value":551},"}\n",{"type":67,"tag":202,"props":553,"children":555},{"class":204,"line":554},13,[556],{"type":67,"tag":202,"props":557,"children":558},{"emptyLinePlaceholder":279},[559],{"type":79,"value":282},{"type":67,"tag":202,"props":561,"children":563},{"class":204,"line":562},14,[564,568,573,577,581,585,589],{"type":67,"tag":202,"props":565,"children":566},{"style":249},[567],{"type":79,"value":252},{"type":67,"tag":202,"props":569,"children":570},{"style":215},[571],{"type":79,"value":572}," signOut ",{"type":67,"tag":202,"props":574,"children":575},{"style":209},[576],{"type":79,"value":223},{"type":67,"tag":202,"props":578,"children":579},{"style":249},[580],{"type":79,"value":304},{"type":67,"tag":202,"props":582,"children":583},{"style":209},[584],{"type":79,"value":309},{"type":67,"tag":202,"props":586,"children":587},{"style":249},[588],{"type":79,"value":314},{"type":67,"tag":202,"props":590,"children":591},{"style":209},[592],{"type":79,"value":319},{"type":67,"tag":202,"props":594,"children":596},{"class":204,"line":595},15,[597,601,605,609,613,617,621,625,629,633,637,642],{"type":67,"tag":202,"props":598,"children":599},{"style":249},[600],{"type":79,"value":328},{"type":67,"tag":202,"props":602,"children":603},{"style":209},[604],{"type":79,"value":333},{"type":67,"tag":202,"props":606,"children":607},{"style":215},[608],{"type":79,"value":338},{"type":67,"tag":202,"props":610,"children":611},{"style":209},[612],{"type":79,"value":343},{"type":67,"tag":202,"props":614,"children":615},{"style":209},[616],{"type":79,"value":348},{"type":67,"tag":202,"props":618,"children":619},{"style":351},[620],{"type":79,"value":354},{"type":67,"tag":202,"props":622,"children":623},{"style":215},[624],{"type":79,"value":359},{"type":67,"tag":202,"props":626,"children":627},{"style":209},[628],{"type":79,"value":105},{"type":67,"tag":202,"props":630,"children":631},{"style":215},[632],{"type":79,"value":368},{"type":67,"tag":202,"props":634,"children":635},{"style":209},[636],{"type":79,"value":105},{"type":67,"tag":202,"props":638,"children":639},{"style":264},[640],{"type":79,"value":641},"signOut",{"type":67,"tag":202,"props":643,"children":644},{"style":380},[645],{"type":79,"value":272},{"type":67,"tag":202,"props":647,"children":649},{"class":204,"line":648},16,[650,654,658,662,666,670,674,678,682,686],{"type":67,"tag":202,"props":651,"children":652},{"style":351},[653],{"type":79,"value":501},{"type":67,"tag":202,"props":655,"children":656},{"style":380},[657],{"type":79,"value":506},{"type":67,"tag":202,"props":659,"children":660},{"style":215},[661],{"type":79,"value":511},{"type":67,"tag":202,"props":663,"children":664},{"style":380},[665],{"type":79,"value":516},{"type":67,"tag":202,"props":667,"children":668},{"style":215},[669],{"type":79,"value":521},{"type":67,"tag":202,"props":671,"children":672},{"style":209},[673],{"type":79,"value":105},{"type":67,"tag":202,"props":675,"children":676},{"style":264},[677],{"type":79,"value":530},{"type":67,"tag":202,"props":679,"children":680},{"style":380},[681],{"type":79,"value":383},{"type":67,"tag":202,"props":683,"children":684},{"style":215},[685],{"type":79,"value":511},{"type":67,"tag":202,"props":687,"children":688},{"style":380},[689],{"type":79,"value":492},{"type":67,"tag":202,"props":691,"children":693},{"class":204,"line":692},17,[694],{"type":67,"tag":202,"props":695,"children":696},{"style":209},[697],{"type":79,"value":551},{"type":67,"tag":202,"props":699,"children":701},{"class":204,"line":700},18,[702,707,712],{"type":67,"tag":202,"props":703,"children":704},{"style":209},[705],{"type":79,"value":706},"\u003C/",{"type":67,"tag":202,"props":708,"children":709},{"style":215},[710],{"type":79,"value":711},"script",{"type":67,"tag":202,"props":713,"children":714},{"style":209},[715],{"type":79,"value":242},{"type":67,"tag":68,"props":717,"children":718},{},[719,721,725],{"type":79,"value":720},"Please also take a look at ",{"type":67,"tag":72,"props":722,"children":723},{"href":6},[724],{"type":79,"value":5},{"type":79,"value":726}," for the authorization flow.",{"type":67,"tag":147,"props":728,"children":730},{"id":729},"database-request",[731],{"type":79,"value":732},"Database Request",{"type":67,"tag":68,"props":734,"children":735},{},[736,738,745],{"type":79,"value":737},"Please check ",{"type":67,"tag":72,"props":739,"children":742},{"href":740,"rel":741},"https://supabase.com/docs/reference/javascript/select",[76],[743],{"type":79,"value":744},"Supabase",{"type":79,"value":746}," documentation to fully use the power of Supabase client.",{"type":67,"tag":68,"props":748,"children":749},{},[750,752,758,760,767],{"type":79,"value":751},"Here is an example of a fetch using the ",{"type":67,"tag":116,"props":753,"children":755},{"className":754},[],[756],{"type":79,"value":757},"select",{"type":79,"value":759}," method with Nuxt 3 ",{"type":67,"tag":72,"props":761,"children":764},{"href":762,"rel":763},"https://nuxt.com/docs/getting-started/data-fetching#useasyncdata",[76],[765],{"type":79,"value":766},"useAsyncData",{"type":79,"value":768}," composable.",{"type":67,"tag":192,"props":770,"children":774},{"className":771,"code":772,"language":773,"meta":61,"style":61},"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","\u003Cscript setup lang=\"ts\">\nconst client = useSupabaseClient()\n\nconst { data: restaurant } = await useAsyncData('restaurant', async () => {\n const { data } = await client.from('restaurants').select('name, location').eq('name', 'My Restaurant Name').single()\n\n return data\n})\n\u003C/script>\n","vue",[775],{"type":67,"tag":116,"props":776,"children":777},{"__ignoreMap":61},[778,819,843,850,931,1083,1090,1103,1114],{"type":67,"tag":202,"props":779,"children":780},{"class":204,"line":205},[781,785,789,794,799,803,807,811,815],{"type":67,"tag":202,"props":782,"children":783},{"style":209},[784],{"type":79,"value":212},{"type":67,"tag":202,"props":786,"children":787},{"style":380},[788],{"type":79,"value":711},{"type":67,"tag":202,"props":790,"children":791},{"style":249},[792],{"type":79,"value":793}," setup",{"type":67,"tag":202,"props":795,"children":796},{"style":249},[797],{"type":79,"value":798}," lang",{"type":67,"tag":202,"props":800,"children":801},{"style":209},[802],{"type":79,"value":223},{"type":67,"tag":202,"props":804,"children":805},{"style":209},[806],{"type":79,"value":228},{"type":67,"tag":202,"props":808,"children":809},{"style":231},[810],{"type":79,"value":196},{"type":67,"tag":202,"props":812,"children":813},{"style":209},[814],{"type":79,"value":228},{"type":67,"tag":202,"props":816,"children":817},{"style":209},[818],{"type":79,"value":242},{"type":67,"tag":202,"props":820,"children":821},{"class":204,"line":245},[822,826,831,835,839],{"type":67,"tag":202,"props":823,"children":824},{"style":249},[825],{"type":79,"value":252},{"type":67,"tag":202,"props":827,"children":828},{"style":215},[829],{"type":79,"value":830}," client ",{"type":67,"tag":202,"props":832,"children":833},{"style":209},[834],{"type":79,"value":223},{"type":67,"tag":202,"props":836,"children":837},{"style":264},[838],{"type":79,"value":267},{"type":67,"tag":202,"props":840,"children":841},{"style":215},[842],{"type":79,"value":272},{"type":67,"tag":202,"props":844,"children":845},{"class":204,"line":275},[846],{"type":67,"tag":202,"props":847,"children":848},{"emptyLinePlaceholder":279},[849],{"type":79,"value":282},{"type":67,"tag":202,"props":851,"children":852},{"class":204,"line":285},[853,857,861,866,870,875,880,884,888,893,897,901,906,910,915,919,923,927],{"type":67,"tag":202,"props":854,"children":855},{"style":249},[856],{"type":79,"value":252},{"type":67,"tag":202,"props":858,"children":859},{"style":209},[860],{"type":79,"value":333},{"type":67,"tag":202,"props":862,"children":863},{"style":380},[864],{"type":79,"value":865}," data",{"type":67,"tag":202,"props":867,"children":868},{"style":209},[869],{"type":79,"value":402},{"type":67,"tag":202,"props":871,"children":872},{"style":215},[873],{"type":79,"value":874}," restaurant ",{"type":67,"tag":202,"props":876,"children":877},{"style":209},[878],{"type":79,"value":879},"}",{"type":67,"tag":202,"props":881,"children":882},{"style":209},[883],{"type":79,"value":348},{"type":67,"tag":202,"props":885,"children":886},{"style":351},[887],{"type":79,"value":354},{"type":67,"tag":202,"props":889,"children":890},{"style":264},[891],{"type":79,"value":892}," useAsyncData",{"type":67,"tag":202,"props":894,"children":895},{"style":215},[896],{"type":79,"value":383},{"type":67,"tag":202,"props":898,"children":899},{"style":209},[900],{"type":79,"value":417},{"type":67,"tag":202,"props":902,"children":903},{"style":231},[904],{"type":79,"value":905},"restaurant",{"type":67,"tag":202,"props":907,"children":908},{"style":209},[909],{"type":79,"value":417},{"type":67,"tag":202,"props":911,"children":912},{"style":209},[913],{"type":79,"value":914},",",{"type":67,"tag":202,"props":916,"children":917},{"style":249},[918],{"type":79,"value":304},{"type":67,"tag":202,"props":920,"children":921},{"style":209},[922],{"type":79,"value":309},{"type":67,"tag":202,"props":924,"children":925},{"style":249},[926],{"type":79,"value":314},{"type":67,"tag":202,"props":928,"children":929},{"style":209},[930],{"type":79,"value":319},{"type":67,"tag":202,"props":932,"children":933},{"class":204,"line":322},[934,938,942,946,950,954,958,963,967,972,976,980,985,989,994,998,1002,1006,1010,1015,1019,1023,1027,1032,1036,1040,1045,1049,1053,1057,1062,1066,1070,1074,1079],{"type":67,"tag":202,"props":935,"children":936},{"style":249},[937],{"type":79,"value":328},{"type":67,"tag":202,"props":939,"children":940},{"style":209},[941],{"type":79,"value":333},{"type":67,"tag":202,"props":943,"children":944},{"style":215},[945],{"type":79,"value":865},{"type":67,"tag":202,"props":947,"children":948},{"style":209},[949],{"type":79,"value":343},{"type":67,"tag":202,"props":951,"children":952},{"style":209},[953],{"type":79,"value":348},{"type":67,"tag":202,"props":955,"children":956},{"style":351},[957],{"type":79,"value":354},{"type":67,"tag":202,"props":959,"children":960},{"style":215},[961],{"type":79,"value":962}," client",{"type":67,"tag":202,"props":964,"children":965},{"style":209},[966],{"type":79,"value":105},{"type":67,"tag":202,"props":968,"children":969},{"style":264},[970],{"type":79,"value":971},"from",{"type":67,"tag":202,"props":973,"children":974},{"style":380},[975],{"type":79,"value":383},{"type":67,"tag":202,"props":977,"children":978},{"style":209},[979],{"type":79,"value":417},{"type":67,"tag":202,"props":981,"children":982},{"style":231},[983],{"type":79,"value":984},"restaurants",{"type":67,"tag":202,"props":986,"children":987},{"style":209},[988],{"type":79,"value":417},{"type":67,"tag":202,"props":990,"children":991},{"style":380},[992],{"type":79,"value":993},")",{"type":67,"tag":202,"props":995,"children":996},{"style":209},[997],{"type":79,"value":105},{"type":67,"tag":202,"props":999,"children":1000},{"style":264},[1001],{"type":79,"value":757},{"type":67,"tag":202,"props":1003,"children":1004},{"style":380},[1005],{"type":79,"value":383},{"type":67,"tag":202,"props":1007,"children":1008},{"style":209},[1009],{"type":79,"value":417},{"type":67,"tag":202,"props":1011,"children":1012},{"style":231},[1013],{"type":79,"value":1014},"name, location",{"type":67,"tag":202,"props":1016,"children":1017},{"style":209},[1018],{"type":79,"value":417},{"type":67,"tag":202,"props":1020,"children":1021},{"style":380},[1022],{"type":79,"value":993},{"type":67,"tag":202,"props":1024,"children":1025},{"style":209},[1026],{"type":79,"value":105},{"type":67,"tag":202,"props":1028,"children":1029},{"style":264},[1030],{"type":79,"value":1031},"eq",{"type":67,"tag":202,"props":1033,"children":1034},{"style":380},[1035],{"type":79,"value":383},{"type":67,"tag":202,"props":1037,"children":1038},{"style":209},[1039],{"type":79,"value":417},{"type":67,"tag":202,"props":1041,"children":1042},{"style":231},[1043],{"type":79,"value":1044},"name",{"type":67,"tag":202,"props":1046,"children":1047},{"style":209},[1048],{"type":79,"value":417},{"type":67,"tag":202,"props":1050,"children":1051},{"style":209},[1052],{"type":79,"value":914},{"type":67,"tag":202,"props":1054,"children":1055},{"style":209},[1056],{"type":79,"value":407},{"type":67,"tag":202,"props":1058,"children":1059},{"style":231},[1060],{"type":79,"value":1061},"My Restaurant Name",{"type":67,"tag":202,"props":1063,"children":1064},{"style":209},[1065],{"type":79,"value":417},{"type":67,"tag":202,"props":1067,"children":1068},{"style":380},[1069],{"type":79,"value":993},{"type":67,"tag":202,"props":1071,"children":1072},{"style":209},[1073],{"type":79,"value":105},{"type":67,"tag":202,"props":1075,"children":1076},{"style":264},[1077],{"type":79,"value":1078},"single",{"type":67,"tag":202,"props":1080,"children":1081},{"style":380},[1082],{"type":79,"value":272},{"type":67,"tag":202,"props":1084,"children":1085},{"class":204,"line":391},[1086],{"type":67,"tag":202,"props":1087,"children":1088},{"emptyLinePlaceholder":279},[1089],{"type":79,"value":282},{"type":67,"tag":202,"props":1091,"children":1092},{"class":204,"line":425},[1093,1098],{"type":67,"tag":202,"props":1094,"children":1095},{"style":351},[1096],{"type":79,"value":1097}," return",{"type":67,"tag":202,"props":1099,"children":1100},{"style":215},[1101],{"type":79,"value":1102}," data\n",{"type":67,"tag":202,"props":1104,"children":1105},{"class":204,"line":442},[1106,1110],{"type":67,"tag":202,"props":1107,"children":1108},{"style":209},[1109],{"type":79,"value":879},{"type":67,"tag":202,"props":1111,"children":1112},{"style":215},[1113],{"type":79,"value":492},{"type":67,"tag":202,"props":1115,"children":1116},{"class":204,"line":472},[1117,1121,1125],{"type":67,"tag":202,"props":1118,"children":1119},{"style":209},[1120],{"type":79,"value":706},{"type":67,"tag":202,"props":1122,"children":1123},{"style":380},[1124],{"type":79,"value":711},{"type":67,"tag":202,"props":1126,"children":1127},{"style":209},[1128],{"type":79,"value":242},{"type":67,"tag":147,"props":1130,"children":1132},{"id":1131},"realtime",[1133],{"type":79,"value":1134},"Realtime",{"type":67,"tag":68,"props":1136,"children":1137},{},[1138,1140,1147],{"type":79,"value":1139},"Based on ",{"type":67,"tag":72,"props":1141,"children":1144},{"href":1142,"rel":1143},"https://github.com/supabase/realtime",[76],[1145],{"type":79,"value":1146},"Supabase Realtime",{"type":79,"value":1148},", listen to changes in your PostgreSQL Database and broadcasts them over WebSockets.",{"type":67,"tag":68,"props":1150,"children":1151},{},[1152,1154,1161],{"type":79,"value":1153},"To enable it, make sure you have turned on the ",{"type":67,"tag":72,"props":1155,"children":1158},{"href":1156,"rel":1157},"https://supabase.com/docs/guides/api#realtime-api",[76],[1159],{"type":79,"value":1160},"Realtime API",{"type":79,"value":1162}," for your table.",{"type":67,"tag":68,"props":1164,"children":1165},{},[1166],{"type":79,"value":1167},"Then, listen to changes directly in your vue page / component:",{"type":67,"tag":192,"props":1169,"children":1171},{"className":771,"code":1170,"language":773,"meta":61,"style":61},"\u003Cscript setup lang=\"ts\">\nimport type { RealtimeChannel } from '@supabase/supabase-js'\n\nconst client = useSupabaseClient()\n\nlet realtimeChannel: RealtimeChannel\n\n// Fetch collaborators and get the refresh method provided by useAsyncData\nconst { data: collaborators, refresh: refreshCollaborators } = await useAsyncData('collaborators', async () => {\n const { data } = await client.from('collaborators').select('name')\n return data\n})\n\n// Once page is mounted, listen to changes on the `collaborators` table and refresh collaborators when receiving event\nonMounted(() => {\n // Real time listener for new workouts\n realtimeChannel = client.channel('public:collaborators').on(\n 'postgres_changes',\n { event: '*', schema: 'public', table: 'collaborators' },\n () => refreshCollaborators()\n )\n\n realtimeChannel.subscribe()\n})\n\n // Don't forget to unsubscribe when user left the page\nonUnmounted(() => {\n client.removeChannel(realtimeChannel)\n})\n\u003C/script>\n",[1172],{"type":67,"tag":116,"props":1173,"children":1174},{"__ignoreMap":61},[1175,1214,1259,1266,1289,1296,1319,1326,1335,1430,1517,1528,1539,1546,1554,1579,1587,1647,1668,1755,1777,1786,1794,1815,1827,1835,1844,1869,1900,1912],{"type":67,"tag":202,"props":1176,"children":1177},{"class":204,"line":205},[1178,1182,1186,1190,1194,1198,1202,1206,1210],{"type":67,"tag":202,"props":1179,"children":1180},{"style":209},[1181],{"type":79,"value":212},{"type":67,"tag":202,"props":1183,"children":1184},{"style":380},[1185],{"type":79,"value":711},{"type":67,"tag":202,"props":1187,"children":1188},{"style":249},[1189],{"type":79,"value":793},{"type":67,"tag":202,"props":1191,"children":1192},{"style":249},[1193],{"type":79,"value":798},{"type":67,"tag":202,"props":1195,"children":1196},{"style":209},[1197],{"type":79,"value":223},{"type":67,"tag":202,"props":1199,"children":1200},{"style":209},[1201],{"type":79,"value":228},{"type":67,"tag":202,"props":1203,"children":1204},{"style":231},[1205],{"type":79,"value":196},{"type":67,"tag":202,"props":1207,"children":1208},{"style":209},[1209],{"type":79,"value":228},{"type":67,"tag":202,"props":1211,"children":1212},{"style":209},[1213],{"type":79,"value":242},{"type":67,"tag":202,"props":1215,"children":1216},{"class":204,"line":245},[1217,1222,1227,1231,1236,1240,1245,1249,1254],{"type":67,"tag":202,"props":1218,"children":1219},{"style":351},[1220],{"type":79,"value":1221},"import",{"type":67,"tag":202,"props":1223,"children":1224},{"style":351},[1225],{"type":79,"value":1226}," type",{"type":67,"tag":202,"props":1228,"children":1229},{"style":209},[1230],{"type":79,"value":333},{"type":67,"tag":202,"props":1232,"children":1233},{"style":215},[1234],{"type":79,"value":1235}," RealtimeChannel",{"type":67,"tag":202,"props":1237,"children":1238},{"style":209},[1239],{"type":79,"value":343},{"type":67,"tag":202,"props":1241,"children":1242},{"style":351},[1243],{"type":79,"value":1244}," from",{"type":67,"tag":202,"props":1246,"children":1247},{"style":209},[1248],{"type":79,"value":407},{"type":67,"tag":202,"props":1250,"children":1251},{"style":231},[1252],{"type":79,"value":1253},"@supabase/supabase-js",{"type":67,"tag":202,"props":1255,"children":1256},{"style":209},[1257],{"type":79,"value":1258},"'\n",{"type":67,"tag":202,"props":1260,"children":1261},{"class":204,"line":275},[1262],{"type":67,"tag":202,"props":1263,"children":1264},{"emptyLinePlaceholder":279},[1265],{"type":79,"value":282},{"type":67,"tag":202,"props":1267,"children":1268},{"class":204,"line":285},[1269,1273,1277,1281,1285],{"type":67,"tag":202,"props":1270,"children":1271},{"style":249},[1272],{"type":79,"value":252},{"type":67,"tag":202,"props":1274,"children":1275},{"style":215},[1276],{"type":79,"value":830},{"type":67,"tag":202,"props":1278,"children":1279},{"style":209},[1280],{"type":79,"value":223},{"type":67,"tag":202,"props":1282,"children":1283},{"style":264},[1284],{"type":79,"value":267},{"type":67,"tag":202,"props":1286,"children":1287},{"style":215},[1288],{"type":79,"value":272},{"type":67,"tag":202,"props":1290,"children":1291},{"class":204,"line":322},[1292],{"type":67,"tag":202,"props":1293,"children":1294},{"emptyLinePlaceholder":279},[1295],{"type":79,"value":282},{"type":67,"tag":202,"props":1297,"children":1298},{"class":204,"line":391},[1299,1304,1309,1313],{"type":67,"tag":202,"props":1300,"children":1301},{"style":249},[1302],{"type":79,"value":1303},"let",{"type":67,"tag":202,"props":1305,"children":1306},{"style":215},[1307],{"type":79,"value":1308}," realtimeChannel",{"type":67,"tag":202,"props":1310,"children":1311},{"style":209},[1312],{"type":79,"value":402},{"type":67,"tag":202,"props":1314,"children":1316},{"style":1315},"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B",[1317],{"type":79,"value":1318}," RealtimeChannel\n",{"type":67,"tag":202,"props":1320,"children":1321},{"class":204,"line":425},[1322],{"type":67,"tag":202,"props":1323,"children":1324},{"emptyLinePlaceholder":279},[1325],{"type":79,"value":282},{"type":67,"tag":202,"props":1327,"children":1328},{"class":204,"line":442},[1329],{"type":67,"tag":202,"props":1330,"children":1332},{"style":1331},"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[1333],{"type":79,"value":1334},"// Fetch collaborators and get the refresh method provided by useAsyncData\n",{"type":67,"tag":202,"props":1336,"children":1337},{"class":204,"line":472},[1338,1342,1346,1350,1354,1359,1363,1368,1372,1377,1381,1385,1389,1393,1397,1401,1406,1410,1414,1418,1422,1426],{"type":67,"tag":202,"props":1339,"children":1340},{"style":249},[1341],{"type":79,"value":252},{"type":67,"tag":202,"props":1343,"children":1344},{"style":209},[1345],{"type":79,"value":333},{"type":67,"tag":202,"props":1347,"children":1348},{"style":380},[1349],{"type":79,"value":865},{"type":67,"tag":202,"props":1351,"children":1352},{"style":209},[1353],{"type":79,"value":402},{"type":67,"tag":202,"props":1355,"children":1356},{"style":215},[1357],{"type":79,"value":1358}," collaborators",{"type":67,"tag":202,"props":1360,"children":1361},{"style":209},[1362],{"type":79,"value":914},{"type":67,"tag":202,"props":1364,"children":1365},{"style":380},[1366],{"type":79,"value":1367}," refresh",{"type":67,"tag":202,"props":1369,"children":1370},{"style":209},[1371],{"type":79,"value":402},{"type":67,"tag":202,"props":1373,"children":1374},{"style":215},[1375],{"type":79,"value":1376}," refreshCollaborators ",{"type":67,"tag":202,"props":1378,"children":1379},{"style":209},[1380],{"type":79,"value":879},{"type":67,"tag":202,"props":1382,"children":1383},{"style":209},[1384],{"type":79,"value":348},{"type":67,"tag":202,"props":1386,"children":1387},{"style":351},[1388],{"type":79,"value":354},{"type":67,"tag":202,"props":1390,"children":1391},{"style":264},[1392],{"type":79,"value":892},{"type":67,"tag":202,"props":1394,"children":1395},{"style":215},[1396],{"type":79,"value":383},{"type":67,"tag":202,"props":1398,"children":1399},{"style":209},[1400],{"type":79,"value":417},{"type":67,"tag":202,"props":1402,"children":1403},{"style":231},[1404],{"type":79,"value":1405},"collaborators",{"type":67,"tag":202,"props":1407,"children":1408},{"style":209},[1409],{"type":79,"value":417},{"type":67,"tag":202,"props":1411,"children":1412},{"style":209},[1413],{"type":79,"value":914},{"type":67,"tag":202,"props":1415,"children":1416},{"style":249},[1417],{"type":79,"value":304},{"type":67,"tag":202,"props":1419,"children":1420},{"style":209},[1421],{"type":79,"value":309},{"type":67,"tag":202,"props":1423,"children":1424},{"style":249},[1425],{"type":79,"value":314},{"type":67,"tag":202,"props":1427,"children":1428},{"style":209},[1429],{"type":79,"value":319},{"type":67,"tag":202,"props":1431,"children":1432},{"class":204,"line":481},[1433,1437,1441,1445,1449,1453,1457,1461,1465,1469,1473,1477,1481,1485,1489,1493,1497,1501,1505,1509,1513],{"type":67,"tag":202,"props":1434,"children":1435},{"style":249},[1436],{"type":79,"value":328},{"type":67,"tag":202,"props":1438,"children":1439},{"style":209},[1440],{"type":79,"value":333},{"type":67,"tag":202,"props":1442,"children":1443},{"style":215},[1444],{"type":79,"value":865},{"type":67,"tag":202,"props":1446,"children":1447},{"style":209},[1448],{"type":79,"value":343},{"type":67,"tag":202,"props":1450,"children":1451},{"style":209},[1452],{"type":79,"value":348},{"type":67,"tag":202,"props":1454,"children":1455},{"style":351},[1456],{"type":79,"value":354},{"type":67,"tag":202,"props":1458,"children":1459},{"style":215},[1460],{"type":79,"value":962},{"type":67,"tag":202,"props":1462,"children":1463},{"style":209},[1464],{"type":79,"value":105},{"type":67,"tag":202,"props":1466,"children":1467},{"style":264},[1468],{"type":79,"value":971},{"type":67,"tag":202,"props":1470,"children":1471},{"style":380},[1472],{"type":79,"value":383},{"type":67,"tag":202,"props":1474,"children":1475},{"style":209},[1476],{"type":79,"value":417},{"type":67,"tag":202,"props":1478,"children":1479},{"style":231},[1480],{"type":79,"value":1405},{"type":67,"tag":202,"props":1482,"children":1483},{"style":209},[1484],{"type":79,"value":417},{"type":67,"tag":202,"props":1486,"children":1487},{"style":380},[1488],{"type":79,"value":993},{"type":67,"tag":202,"props":1490,"children":1491},{"style":209},[1492],{"type":79,"value":105},{"type":67,"tag":202,"props":1494,"children":1495},{"style":264},[1496],{"type":79,"value":757},{"type":67,"tag":202,"props":1498,"children":1499},{"style":380},[1500],{"type":79,"value":383},{"type":67,"tag":202,"props":1502,"children":1503},{"style":209},[1504],{"type":79,"value":417},{"type":67,"tag":202,"props":1506,"children":1507},{"style":231},[1508],{"type":79,"value":1044},{"type":67,"tag":202,"props":1510,"children":1511},{"style":209},[1512],{"type":79,"value":417},{"type":67,"tag":202,"props":1514,"children":1515},{"style":380},[1516],{"type":79,"value":492},{"type":67,"tag":202,"props":1518,"children":1519},{"class":204,"line":495},[1520,1524],{"type":67,"tag":202,"props":1521,"children":1522},{"style":351},[1523],{"type":79,"value":1097},{"type":67,"tag":202,"props":1525,"children":1526},{"style":215},[1527],{"type":79,"value":1102},{"type":67,"tag":202,"props":1529,"children":1530},{"class":204,"line":545},[1531,1535],{"type":67,"tag":202,"props":1532,"children":1533},{"style":209},[1534],{"type":79,"value":879},{"type":67,"tag":202,"props":1536,"children":1537},{"style":215},[1538],{"type":79,"value":492},{"type":67,"tag":202,"props":1540,"children":1541},{"class":204,"line":554},[1542],{"type":67,"tag":202,"props":1543,"children":1544},{"emptyLinePlaceholder":279},[1545],{"type":79,"value":282},{"type":67,"tag":202,"props":1547,"children":1548},{"class":204,"line":562},[1549],{"type":67,"tag":202,"props":1550,"children":1551},{"style":1331},[1552],{"type":79,"value":1553},"// Once page is mounted, listen to changes on the `collaborators` table and refresh collaborators when receiving event\n",{"type":67,"tag":202,"props":1555,"children":1556},{"class":204,"line":595},[1557,1562,1566,1571,1575],{"type":67,"tag":202,"props":1558,"children":1559},{"style":264},[1560],{"type":79,"value":1561},"onMounted",{"type":67,"tag":202,"props":1563,"children":1564},{"style":215},[1565],{"type":79,"value":383},{"type":67,"tag":202,"props":1567,"children":1568},{"style":209},[1569],{"type":79,"value":1570},"()",{"type":67,"tag":202,"props":1572,"children":1573},{"style":249},[1574],{"type":79,"value":314},{"type":67,"tag":202,"props":1576,"children":1577},{"style":209},[1578],{"type":79,"value":319},{"type":67,"tag":202,"props":1580,"children":1581},{"class":204,"line":648},[1582],{"type":67,"tag":202,"props":1583,"children":1584},{"style":1331},[1585],{"type":79,"value":1586}," // Real time listener for new workouts\n",{"type":67,"tag":202,"props":1588,"children":1589},{"class":204,"line":692},[1590,1595,1599,1603,1607,1612,1616,1620,1625,1629,1633,1637,1642],{"type":67,"tag":202,"props":1591,"children":1592},{"style":215},[1593],{"type":79,"value":1594}," realtimeChannel",{"type":67,"tag":202,"props":1596,"children":1597},{"style":209},[1598],{"type":79,"value":348},{"type":67,"tag":202,"props":1600,"children":1601},{"style":215},[1602],{"type":79,"value":962},{"type":67,"tag":202,"props":1604,"children":1605},{"style":209},[1606],{"type":79,"value":105},{"type":67,"tag":202,"props":1608,"children":1609},{"style":264},[1610],{"type":79,"value":1611},"channel",{"type":67,"tag":202,"props":1613,"children":1614},{"style":380},[1615],{"type":79,"value":383},{"type":67,"tag":202,"props":1617,"children":1618},{"style":209},[1619],{"type":79,"value":417},{"type":67,"tag":202,"props":1621,"children":1622},{"style":231},[1623],{"type":79,"value":1624},"public:collaborators",{"type":67,"tag":202,"props":1626,"children":1627},{"style":209},[1628],{"type":79,"value":417},{"type":67,"tag":202,"props":1630,"children":1631},{"style":380},[1632],{"type":79,"value":993},{"type":67,"tag":202,"props":1634,"children":1635},{"style":209},[1636],{"type":79,"value":105},{"type":67,"tag":202,"props":1638,"children":1639},{"style":264},[1640],{"type":79,"value":1641},"on",{"type":67,"tag":202,"props":1643,"children":1644},{"style":380},[1645],{"type":79,"value":1646},"(\n",{"type":67,"tag":202,"props":1648,"children":1649},{"class":204,"line":700},[1650,1655,1660,1664],{"type":67,"tag":202,"props":1651,"children":1652},{"style":209},[1653],{"type":79,"value":1654}," '",{"type":67,"tag":202,"props":1656,"children":1657},{"style":231},[1658],{"type":79,"value":1659},"postgres_changes",{"type":67,"tag":202,"props":1661,"children":1662},{"style":209},[1663],{"type":79,"value":417},{"type":67,"tag":202,"props":1665,"children":1666},{"style":209},[1667],{"type":79,"value":422},{"type":67,"tag":202,"props":1669,"children":1671},{"class":204,"line":1670},19,[1672,1677,1682,1686,1690,1695,1699,1703,1708,1712,1716,1721,1725,1729,1734,1738,1742,1746,1750],{"type":67,"tag":202,"props":1673,"children":1674},{"style":209},[1675],{"type":79,"value":1676}," {",{"type":67,"tag":202,"props":1678,"children":1679},{"style":380},[1680],{"type":79,"value":1681}," event",{"type":67,"tag":202,"props":1683,"children":1684},{"style":209},[1685],{"type":79,"value":402},{"type":67,"tag":202,"props":1687,"children":1688},{"style":209},[1689],{"type":79,"value":407},{"type":67,"tag":202,"props":1691,"children":1692},{"style":231},[1693],{"type":79,"value":1694},"*",{"type":67,"tag":202,"props":1696,"children":1697},{"style":209},[1698],{"type":79,"value":417},{"type":67,"tag":202,"props":1700,"children":1701},{"style":209},[1702],{"type":79,"value":914},{"type":67,"tag":202,"props":1704,"children":1705},{"style":380},[1706],{"type":79,"value":1707}," schema",{"type":67,"tag":202,"props":1709,"children":1710},{"style":209},[1711],{"type":79,"value":402},{"type":67,"tag":202,"props":1713,"children":1714},{"style":209},[1715],{"type":79,"value":407},{"type":67,"tag":202,"props":1717,"children":1718},{"style":231},[1719],{"type":79,"value":1720},"public",{"type":67,"tag":202,"props":1722,"children":1723},{"style":209},[1724],{"type":79,"value":417},{"type":67,"tag":202,"props":1726,"children":1727},{"style":209},[1728],{"type":79,"value":914},{"type":67,"tag":202,"props":1730,"children":1731},{"style":380},[1732],{"type":79,"value":1733}," table",{"type":67,"tag":202,"props":1735,"children":1736},{"style":209},[1737],{"type":79,"value":402},{"type":67,"tag":202,"props":1739,"children":1740},{"style":209},[1741],{"type":79,"value":407},{"type":67,"tag":202,"props":1743,"children":1744},{"style":231},[1745],{"type":79,"value":1405},{"type":67,"tag":202,"props":1747,"children":1748},{"style":209},[1749],{"type":79,"value":417},{"type":67,"tag":202,"props":1751,"children":1752},{"style":209},[1753],{"type":79,"value":1754}," },\n",{"type":67,"tag":202,"props":1756,"children":1758},{"class":204,"line":1757},20,[1759,1764,1768,1773],{"type":67,"tag":202,"props":1760,"children":1761},{"style":209},[1762],{"type":79,"value":1763}," ()",{"type":67,"tag":202,"props":1765,"children":1766},{"style":249},[1767],{"type":79,"value":314},{"type":67,"tag":202,"props":1769,"children":1770},{"style":264},[1771],{"type":79,"value":1772}," refreshCollaborators",{"type":67,"tag":202,"props":1774,"children":1775},{"style":380},[1776],{"type":79,"value":272},{"type":67,"tag":202,"props":1778,"children":1780},{"class":204,"line":1779},21,[1781],{"type":67,"tag":202,"props":1782,"children":1783},{"style":380},[1784],{"type":79,"value":1785}," )\n",{"type":67,"tag":202,"props":1787,"children":1789},{"class":204,"line":1788},22,[1790],{"type":67,"tag":202,"props":1791,"children":1792},{"emptyLinePlaceholder":279},[1793],{"type":79,"value":282},{"type":67,"tag":202,"props":1795,"children":1797},{"class":204,"line":1796},23,[1798,1802,1806,1811],{"type":67,"tag":202,"props":1799,"children":1800},{"style":215},[1801],{"type":79,"value":1594},{"type":67,"tag":202,"props":1803,"children":1804},{"style":209},[1805],{"type":79,"value":105},{"type":67,"tag":202,"props":1807,"children":1808},{"style":264},[1809],{"type":79,"value":1810},"subscribe",{"type":67,"tag":202,"props":1812,"children":1813},{"style":380},[1814],{"type":79,"value":272},{"type":67,"tag":202,"props":1816,"children":1818},{"class":204,"line":1817},24,[1819,1823],{"type":67,"tag":202,"props":1820,"children":1821},{"style":209},[1822],{"type":79,"value":879},{"type":67,"tag":202,"props":1824,"children":1825},{"style":215},[1826],{"type":79,"value":492},{"type":67,"tag":202,"props":1828,"children":1830},{"class":204,"line":1829},25,[1831],{"type":67,"tag":202,"props":1832,"children":1833},{"emptyLinePlaceholder":279},[1834],{"type":79,"value":282},{"type":67,"tag":202,"props":1836,"children":1838},{"class":204,"line":1837},26,[1839],{"type":67,"tag":202,"props":1840,"children":1841},{"style":1331},[1842],{"type":79,"value":1843}," // Don't forget to unsubscribe when user left the page\n",{"type":67,"tag":202,"props":1845,"children":1847},{"class":204,"line":1846},27,[1848,1853,1857,1861,1865],{"type":67,"tag":202,"props":1849,"children":1850},{"style":264},[1851],{"type":79,"value":1852},"onUnmounted",{"type":67,"tag":202,"props":1854,"children":1855},{"style":215},[1856],{"type":79,"value":383},{"type":67,"tag":202,"props":1858,"children":1859},{"style":209},[1860],{"type":79,"value":1570},{"type":67,"tag":202,"props":1862,"children":1863},{"style":249},[1864],{"type":79,"value":314},{"type":67,"tag":202,"props":1866,"children":1867},{"style":209},[1868],{"type":79,"value":319},{"type":67,"tag":202,"props":1870,"children":1872},{"class":204,"line":1871},28,[1873,1878,1882,1887,1891,1896],{"type":67,"tag":202,"props":1874,"children":1875},{"style":215},[1876],{"type":79,"value":1877}," client",{"type":67,"tag":202,"props":1879,"children":1880},{"style":209},[1881],{"type":79,"value":105},{"type":67,"tag":202,"props":1883,"children":1884},{"style":264},[1885],{"type":79,"value":1886},"removeChannel",{"type":67,"tag":202,"props":1888,"children":1889},{"style":380},[1890],{"type":79,"value":383},{"type":67,"tag":202,"props":1892,"children":1893},{"style":215},[1894],{"type":79,"value":1895},"realtimeChannel",{"type":67,"tag":202,"props":1897,"children":1898},{"style":380},[1899],{"type":79,"value":492},{"type":67,"tag":202,"props":1901,"children":1903},{"class":204,"line":1902},29,[1904,1908],{"type":67,"tag":202,"props":1905,"children":1906},{"style":209},[1907],{"type":79,"value":879},{"type":67,"tag":202,"props":1909,"children":1910},{"style":215},[1911],{"type":79,"value":492},{"type":67,"tag":202,"props":1913,"children":1915},{"class":204,"line":1914},30,[1916,1920,1924],{"type":67,"tag":202,"props":1917,"children":1918},{"style":209},[1919],{"type":79,"value":706},{"type":67,"tag":202,"props":1921,"children":1922},{"style":380},[1923],{"type":79,"value":711},{"type":67,"tag":202,"props":1925,"children":1926},{"style":209},[1927],{"type":79,"value":242},{"type":67,"tag":147,"props":1929,"children":1931},{"id":1930},"typescript",[1932],{"type":79,"value":1933},"Typescript",{"type":67,"tag":68,"props":1935,"children":1936},{},[1937,1939,1945,1947,1953,1955,1962],{"type":79,"value":1938},"Database typings are passed to the client out of the box if the database generated types are found at ",{"type":67,"tag":116,"props":1940,"children":1942},{"className":1941},[],[1943],{"type":79,"value":1944},"./types/database.types.ts",{"type":79,"value":1946}," or ",{"type":67,"tag":72,"props":1948,"children":1950},{"href":1949},"/get-started#types",[1951],{"type":79,"value":1952},"your configured types path",{"type":79,"value":1954},". Check Supabase ",{"type":67,"tag":72,"props":1956,"children":1959},{"href":1957,"rel":1958},"https://supabase.com/docs/reference/javascript/release-notes#typescript-support",[76],[1960],{"type":79,"value":1961},"documentation",{"type":79,"value":1963}," for further information.",{"type":67,"tag":192,"props":1965,"children":1969},{"className":1966,"code":1967,"language":1968,"meta":61,"style":61},"language-shell shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","## Generate types from live database\nsupabase gen types typescript --project-id YourProjectId > types/database.types.ts\n\n## Generate types when using local environment\nsupabase gen types typescript --local > types/database.types.ts\n","shell",[1970],{"type":67,"tag":116,"props":1971,"children":1972},{"__ignoreMap":61},[1973,1981,2024,2031,2039],{"type":67,"tag":202,"props":1974,"children":1975},{"class":204,"line":205},[1976],{"type":67,"tag":202,"props":1977,"children":1978},{"style":1331},[1979],{"type":79,"value":1980},"## Generate types from live database\n",{"type":67,"tag":202,"props":1982,"children":1983},{"class":204,"line":245},[1984,1989,1994,1999,2004,2009,2014,2019],{"type":67,"tag":202,"props":1985,"children":1986},{"style":1315},[1987],{"type":79,"value":1988},"supabase",{"type":67,"tag":202,"props":1990,"children":1991},{"style":231},[1992],{"type":79,"value":1993}," gen",{"type":67,"tag":202,"props":1995,"children":1996},{"style":231},[1997],{"type":79,"value":1998}," types",{"type":67,"tag":202,"props":2000,"children":2001},{"style":231},[2002],{"type":79,"value":2003}," typescript",{"type":67,"tag":202,"props":2005,"children":2006},{"style":231},[2007],{"type":79,"value":2008}," --project-id",{"type":67,"tag":202,"props":2010,"children":2011},{"style":231},[2012],{"type":79,"value":2013}," YourProjectId",{"type":67,"tag":202,"props":2015,"children":2016},{"style":209},[2017],{"type":79,"value":2018}," >",{"type":67,"tag":202,"props":2020,"children":2021},{"style":231},[2022],{"type":79,"value":2023}," types/database.types.ts\n",{"type":67,"tag":202,"props":2025,"children":2026},{"class":204,"line":275},[2027],{"type":67,"tag":202,"props":2028,"children":2029},{"emptyLinePlaceholder":279},[2030],{"type":79,"value":282},{"type":67,"tag":202,"props":2032,"children":2033},{"class":204,"line":285},[2034],{"type":67,"tag":202,"props":2035,"children":2036},{"style":1331},[2037],{"type":79,"value":2038},"## Generate types when using local environment\n",{"type":67,"tag":202,"props":2040,"children":2041},{"class":204,"line":322},[2042,2046,2050,2054,2058,2063,2067],{"type":67,"tag":202,"props":2043,"children":2044},{"style":1315},[2045],{"type":79,"value":1988},{"type":67,"tag":202,"props":2047,"children":2048},{"style":231},[2049],{"type":79,"value":1993},{"type":67,"tag":202,"props":2051,"children":2052},{"style":231},[2053],{"type":79,"value":1998},{"type":67,"tag":202,"props":2055,"children":2056},{"style":231},[2057],{"type":79,"value":2003},{"type":67,"tag":202,"props":2059,"children":2060},{"style":231},[2061],{"type":79,"value":2062}," --local",{"type":67,"tag":202,"props":2064,"children":2065},{"style":209},[2066],{"type":79,"value":2018},{"type":67,"tag":202,"props":2068,"children":2069},{"style":231},[2070],{"type":79,"value":2023},{"type":67,"tag":68,"props":2072,"children":2073},{},[2074],{"type":79,"value":2075},"You can also pass Database typings to the client manually:",{"type":67,"tag":192,"props":2077,"children":2079},{"className":771,"code":2078,"language":773,"meta":61,"style":61},"\u003Cscript setup lang=\"ts\">\nimport type { Database } from '~/types'\nconst client = useSupabaseClient\u003CDatabase>()\n\u003C/script>\n",[2080],{"type":67,"tag":116,"props":2081,"children":2082},{"__ignoreMap":61},[2083,2122,2163,2200],{"type":67,"tag":202,"props":2084,"children":2085},{"class":204,"line":205},[2086,2090,2094,2098,2102,2106,2110,2114,2118],{"type":67,"tag":202,"props":2087,"children":2088},{"style":209},[2089],{"type":79,"value":212},{"type":67,"tag":202,"props":2091,"children":2092},{"style":380},[2093],{"type":79,"value":711},{"type":67,"tag":202,"props":2095,"children":2096},{"style":249},[2097],{"type":79,"value":793},{"type":67,"tag":202,"props":2099,"children":2100},{"style":249},[2101],{"type":79,"value":798},{"type":67,"tag":202,"props":2103,"children":2104},{"style":209},[2105],{"type":79,"value":223},{"type":67,"tag":202,"props":2107,"children":2108},{"style":209},[2109],{"type":79,"value":228},{"type":67,"tag":202,"props":2111,"children":2112},{"style":231},[2113],{"type":79,"value":196},{"type":67,"tag":202,"props":2115,"children":2116},{"style":209},[2117],{"type":79,"value":228},{"type":67,"tag":202,"props":2119,"children":2120},{"style":209},[2121],{"type":79,"value":242},{"type":67,"tag":202,"props":2123,"children":2124},{"class":204,"line":245},[2125,2129,2133,2137,2142,2146,2150,2154,2159],{"type":67,"tag":202,"props":2126,"children":2127},{"style":351},[2128],{"type":79,"value":1221},{"type":67,"tag":202,"props":2130,"children":2131},{"style":351},[2132],{"type":79,"value":1226},{"type":67,"tag":202,"props":2134,"children":2135},{"style":209},[2136],{"type":79,"value":333},{"type":67,"tag":202,"props":2138,"children":2139},{"style":215},[2140],{"type":79,"value":2141}," Database",{"type":67,"tag":202,"props":2143,"children":2144},{"style":209},[2145],{"type":79,"value":343},{"type":67,"tag":202,"props":2147,"children":2148},{"style":351},[2149],{"type":79,"value":1244},{"type":67,"tag":202,"props":2151,"children":2152},{"style":209},[2153],{"type":79,"value":407},{"type":67,"tag":202,"props":2155,"children":2156},{"style":231},[2157],{"type":79,"value":2158},"~/types",{"type":67,"tag":202,"props":2160,"children":2161},{"style":209},[2162],{"type":79,"value":1258},{"type":67,"tag":202,"props":2164,"children":2165},{"class":204,"line":275},[2166,2170,2174,2178,2182,2186,2191,2196],{"type":67,"tag":202,"props":2167,"children":2168},{"style":249},[2169],{"type":79,"value":252},{"type":67,"tag":202,"props":2171,"children":2172},{"style":215},[2173],{"type":79,"value":830},{"type":67,"tag":202,"props":2175,"children":2176},{"style":209},[2177],{"type":79,"value":223},{"type":67,"tag":202,"props":2179,"children":2180},{"style":264},[2181],{"type":79,"value":267},{"type":67,"tag":202,"props":2183,"children":2184},{"style":209},[2185],{"type":79,"value":212},{"type":67,"tag":202,"props":2187,"children":2188},{"style":1315},[2189],{"type":79,"value":2190},"Database",{"type":67,"tag":202,"props":2192,"children":2193},{"style":209},[2194],{"type":79,"value":2195},">",{"type":67,"tag":202,"props":2197,"children":2198},{"style":215},[2199],{"type":79,"value":272},{"type":67,"tag":202,"props":2201,"children":2202},{"class":204,"line":285},[2203,2207,2211],{"type":67,"tag":202,"props":2204,"children":2205},{"style":209},[2206],{"type":79,"value":706},{"type":67,"tag":202,"props":2208,"children":2209},{"style":380},[2210],{"type":79,"value":711},{"type":67,"tag":202,"props":2212,"children":2213},{"style":209},[2214],{"type":79,"value":242},{"type":67,"tag":2216,"props":2217,"children":2218},"style",{},[2219],{"type":79,"value":2220},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":61,"searchDepth":245,"depth":245,"links":2222},[2223,2224,2225,2226],{"id":149,"depth":245,"text":9},{"id":729,"depth":245,"text":732},{"id":1131,"depth":245,"text":1134},{"id":1930,"depth":245,"text":1933},"markdown","content:4.usage:composables:useSupabaseClient.md","content","4.usage/composables/useSupabaseClient.md","4.usage/composables/useSupabaseClient","md",[2234,2236],{"_path":10,"title":9,"description":2235},"Authenticate your user thanks to the PKCE Oauth protocol that enables secure exchange of refresh and access tokens between an application and the authorization server",{"_path":25,"title":24,"description":2237},"Auto import and use your Supabase user's session with the useSupabaseSession composable",1724942526901] \ No newline at end of file diff --git a/usage/composables/usesupabaseclient/index.html b/usage/composables/usesupabaseclient/index.html index 8b5f5a1e..de294762 100644 --- a/usage/composables/usesupabaseclient/index.html +++ b/usage/composables/usesupabaseclient/index.html @@ -61,7 +61,7 @@ - + @@ -172,5 +172,5 @@ const client = useSupabaseClient<Database>() </script>
Made with Nuxt Studio
- - \ No newline at end of file + + \ No newline at end of file diff --git a/usage/composables/usesupabasesession/_payload.json b/usage/composables/usesupabasesession/_payload.json index 0ff8f845..d98df691 100644 --- a/usage/composables/usesupabasesession/_payload.json +++ b/usage/composables/usesupabasesession/_payload.json @@ -1 +1 @@ -[{"data":1,"prerenderedAt":556},["ShallowReactive",2],{"navigation":3,"/usage/composables/usesupabasesession":58,"/usage/composables/usesupabasesession-surround":551},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":25,"_dir":59,"_draft":60,"_partial":60,"_locale":61,"title":24,"description":62,"body":63,"_type":545,"_id":546,"_source":547,"_file":548,"_stem":549,"_extension":550},"composables",false,"","Auto import and use your Supabase user's session with the useSupabaseSession composable",{"type":64,"children":65,"toc":542},"root",[66,85,173,189,196,226,239,447,452,515,536],{"type":67,"tag":68,"props":69,"children":70},"element","p",{},[71,74,83],{"type":72,"value":73},"text","Once logged in, you can ",{"type":67,"tag":75,"props":76,"children":80},"a",{"href":77,"rel":78},"https://nuxt.com/docs/guide/directory-structure/composables",[79],"nofollow",[81],{"type":72,"value":82},"auto-import",{"type":72,"value":84}," your user's session everywhere inside your vue files.",{"type":67,"tag":86,"props":87,"children":91},"pre",{"className":88,"code":89,"language":90,"meta":61,"style":61},"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","\u003Cscript setup>\nconst session = useSupabaseSession()\n\u003C/script>\n","vue",[92],{"type":67,"tag":93,"props":94,"children":95},"code",{"__ignoreMap":61},[96,125,156],{"type":67,"tag":97,"props":98,"children":101},"span",{"class":99,"line":100},"line",1,[102,108,114,120],{"type":67,"tag":97,"props":103,"children":105},{"style":104},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[106],{"type":72,"value":107},"\u003C",{"type":67,"tag":97,"props":109,"children":111},{"style":110},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[112],{"type":72,"value":113},"script",{"type":67,"tag":97,"props":115,"children":117},{"style":116},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[118],{"type":72,"value":119}," setup",{"type":67,"tag":97,"props":121,"children":122},{"style":104},[123],{"type":72,"value":124},">\n",{"type":67,"tag":97,"props":126,"children":128},{"class":99,"line":127},2,[129,134,140,145,151],{"type":67,"tag":97,"props":130,"children":131},{"style":116},[132],{"type":72,"value":133},"const",{"type":67,"tag":97,"props":135,"children":137},{"style":136},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[138],{"type":72,"value":139}," session ",{"type":67,"tag":97,"props":141,"children":142},{"style":104},[143],{"type":72,"value":144},"=",{"type":67,"tag":97,"props":146,"children":148},{"style":147},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[149],{"type":72,"value":150}," useSupabaseSession",{"type":67,"tag":97,"props":152,"children":153},{"style":136},[154],{"type":72,"value":155},"()\n",{"type":67,"tag":97,"props":157,"children":159},{"class":99,"line":158},3,[160,165,169],{"type":67,"tag":97,"props":161,"children":162},{"style":104},[163],{"type":72,"value":164},"\u003C/",{"type":67,"tag":97,"props":166,"children":167},{"style":110},[168],{"type":72,"value":113},{"type":67,"tag":97,"props":170,"children":171},{"style":104},[172],{"type":72,"value":124},{"type":67,"tag":174,"props":175,"children":177},"callout",{"icon":176},"i-heroicons-light-bulb",[178],{"type":67,"tag":68,"props":179,"children":180},{},[181,183,187],{"type":72,"value":182},"If you just need the User's information you can use ",{"type":67,"tag":75,"props":184,"children":185},{"href":28},[186],{"type":72,"value":27},{"type":72,"value":188}," which returns just the User information of the session.",{"type":67,"tag":190,"props":191,"children":193},"h2",{"id":192},"auth-middleware",[194],{"type":72,"value":195},"Auth middleware",{"type":67,"tag":174,"props":197,"children":198},{"icon":176},[199],{"type":67,"tag":68,"props":200,"children":201},{},[202,204,210,212,217,219,224],{"type":72,"value":203},"By default, the module is implementing a redirect middleware. All pages of your application are automatically redirected to the ",{"type":67,"tag":75,"props":205,"children":207},{"href":206},"/get-started#redirectoptions",[208],{"type":72,"value":209},"login",{"type":72,"value":211}," page. However, you can allow redirection to \"public\" pages by setting the ",{"type":67,"tag":75,"props":213,"children":214},{"href":206},[215],{"type":72,"value":216},"exclude",{"type":72,"value":218}," redirect option. Alternatively, you can enable the redirect only for certain routes using the ",{"type":67,"tag":75,"props":220,"children":221},{"href":206},[222],{"type":72,"value":223},"include",{"type":72,"value":225}," redirect option.",{"type":67,"tag":68,"props":227,"children":228},{},[229,231,237],{"type":72,"value":230},"If the ",{"type":67,"tag":75,"props":232,"children":234},{"href":233},"/get-started#redirect",[235],{"type":72,"value":236},"redirect",{"type":72,"value":238}," option is disabled, you can protect your authenticated routes by creating a custom middleware in your project, here is an example:",{"type":67,"tag":86,"props":240,"children":245},{"className":241,"code":242,"filename":243,"language":244,"meta":61,"style":61},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","export default defineNuxtRouteMiddleware((to, _from) => {\n const session = useSupabaseSession()\n\n if (!session.value) {\n return navigateTo('/login')\n }\n})\n","middleware/auth.ts","ts",[246],{"type":67,"tag":93,"props":247,"children":248},{"__ignoreMap":61},[249,308,334,343,387,425,434],{"type":67,"tag":97,"props":250,"children":251},{"class":99,"line":100},[252,258,263,268,273,277,283,288,293,298,303],{"type":67,"tag":97,"props":253,"children":255},{"style":254},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[256],{"type":72,"value":257},"export",{"type":67,"tag":97,"props":259,"children":260},{"style":254},[261],{"type":72,"value":262}," default",{"type":67,"tag":97,"props":264,"children":265},{"style":147},[266],{"type":72,"value":267}," defineNuxtRouteMiddleware",{"type":67,"tag":97,"props":269,"children":270},{"style":136},[271],{"type":72,"value":272},"(",{"type":67,"tag":97,"props":274,"children":275},{"style":104},[276],{"type":72,"value":272},{"type":67,"tag":97,"props":278,"children":280},{"style":279},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[281],{"type":72,"value":282},"to",{"type":67,"tag":97,"props":284,"children":285},{"style":104},[286],{"type":72,"value":287},",",{"type":67,"tag":97,"props":289,"children":290},{"style":279},[291],{"type":72,"value":292}," _from",{"type":67,"tag":97,"props":294,"children":295},{"style":104},[296],{"type":72,"value":297},")",{"type":67,"tag":97,"props":299,"children":300},{"style":116},[301],{"type":72,"value":302}," =>",{"type":67,"tag":97,"props":304,"children":305},{"style":104},[306],{"type":72,"value":307}," {\n",{"type":67,"tag":97,"props":309,"children":310},{"class":99,"line":127},[311,316,321,326,330],{"type":67,"tag":97,"props":312,"children":313},{"style":116},[314],{"type":72,"value":315}," const",{"type":67,"tag":97,"props":317,"children":318},{"style":136},[319],{"type":72,"value":320}," session",{"type":67,"tag":97,"props":322,"children":323},{"style":104},[324],{"type":72,"value":325}," =",{"type":67,"tag":97,"props":327,"children":328},{"style":147},[329],{"type":72,"value":150},{"type":67,"tag":97,"props":331,"children":332},{"style":110},[333],{"type":72,"value":155},{"type":67,"tag":97,"props":335,"children":336},{"class":99,"line":158},[337],{"type":67,"tag":97,"props":338,"children":340},{"emptyLinePlaceholder":339},true,[341],{"type":72,"value":342},"\n",{"type":67,"tag":97,"props":344,"children":346},{"class":99,"line":345},4,[347,352,357,362,367,372,377,382],{"type":67,"tag":97,"props":348,"children":349},{"style":254},[350],{"type":72,"value":351}," if",{"type":67,"tag":97,"props":353,"children":354},{"style":110},[355],{"type":72,"value":356}," (",{"type":67,"tag":97,"props":358,"children":359},{"style":104},[360],{"type":72,"value":361},"!",{"type":67,"tag":97,"props":363,"children":364},{"style":136},[365],{"type":72,"value":366},"session",{"type":67,"tag":97,"props":368,"children":369},{"style":104},[370],{"type":72,"value":371},".",{"type":67,"tag":97,"props":373,"children":374},{"style":136},[375],{"type":72,"value":376},"value",{"type":67,"tag":97,"props":378,"children":379},{"style":110},[380],{"type":72,"value":381},") ",{"type":67,"tag":97,"props":383,"children":384},{"style":104},[385],{"type":72,"value":386},"{\n",{"type":67,"tag":97,"props":388,"children":390},{"class":99,"line":389},5,[391,396,401,405,410,416,420],{"type":67,"tag":97,"props":392,"children":393},{"style":254},[394],{"type":72,"value":395}," return",{"type":67,"tag":97,"props":397,"children":398},{"style":147},[399],{"type":72,"value":400}," navigateTo",{"type":67,"tag":97,"props":402,"children":403},{"style":110},[404],{"type":72,"value":272},{"type":67,"tag":97,"props":406,"children":407},{"style":104},[408],{"type":72,"value":409},"'",{"type":67,"tag":97,"props":411,"children":413},{"style":412},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[414],{"type":72,"value":415},"/login",{"type":67,"tag":97,"props":417,"children":418},{"style":104},[419],{"type":72,"value":409},{"type":67,"tag":97,"props":421,"children":422},{"style":110},[423],{"type":72,"value":424},")\n",{"type":67,"tag":97,"props":426,"children":428},{"class":99,"line":427},6,[429],{"type":67,"tag":97,"props":430,"children":431},{"style":104},[432],{"type":72,"value":433}," }\n",{"type":67,"tag":97,"props":435,"children":437},{"class":99,"line":436},7,[438,443],{"type":67,"tag":97,"props":439,"children":440},{"style":104},[441],{"type":72,"value":442},"}",{"type":67,"tag":97,"props":444,"children":445},{"style":136},[446],{"type":72,"value":424},{"type":67,"tag":68,"props":448,"children":449},{},[450],{"type":72,"value":451},"Then you can reference your middleware in your page with:",{"type":67,"tag":86,"props":453,"children":456},{"className":241,"code":454,"filename":455,"language":244,"meta":61,"style":61},"definePageMeta({\n middleware: 'auth'\n})\n","pages/dashboard.vue",[457],{"type":67,"tag":93,"props":458,"children":459},{"__ignoreMap":61},[460,476,504],{"type":67,"tag":97,"props":461,"children":462},{"class":99,"line":100},[463,468,472],{"type":67,"tag":97,"props":464,"children":465},{"style":147},[466],{"type":72,"value":467},"definePageMeta",{"type":67,"tag":97,"props":469,"children":470},{"style":136},[471],{"type":72,"value":272},{"type":67,"tag":97,"props":473,"children":474},{"style":104},[475],{"type":72,"value":386},{"type":67,"tag":97,"props":477,"children":478},{"class":99,"line":127},[479,484,489,494,499],{"type":67,"tag":97,"props":480,"children":481},{"style":110},[482],{"type":72,"value":483}," middleware",{"type":67,"tag":97,"props":485,"children":486},{"style":104},[487],{"type":72,"value":488},":",{"type":67,"tag":97,"props":490,"children":491},{"style":104},[492],{"type":72,"value":493}," '",{"type":67,"tag":97,"props":495,"children":496},{"style":412},[497],{"type":72,"value":498},"auth",{"type":67,"tag":97,"props":500,"children":501},{"style":104},[502],{"type":72,"value":503},"'\n",{"type":67,"tag":97,"props":505,"children":506},{"class":99,"line":158},[507,511],{"type":67,"tag":97,"props":508,"children":509},{"style":104},[510],{"type":72,"value":442},{"type":67,"tag":97,"props":512,"children":513},{"style":136},[514],{"type":72,"value":424},{"type":67,"tag":68,"props":516,"children":517},{},[518,520,527,529,535],{"type":72,"value":519},"Learn more about ",{"type":67,"tag":75,"props":521,"children":524},{"href":522,"rel":523},"https://nuxt.com/docs/guide/directory-structure/middleware",[79],[525],{"type":72,"value":526},"Nuxt middleware",{"type":72,"value":528}," and ",{"type":67,"tag":75,"props":530,"children":533},{"href":531,"rel":532},"https://nuxt.com/docs/guide/directory-structure/pages#page-metadata",[79],[534],{"type":72,"value":467},{"type":72,"value":371},{"type":67,"tag":537,"props":538,"children":539},"style",{},[540],{"type":72,"value":541},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":61,"searchDepth":127,"depth":127,"links":543},[544],{"id":192,"depth":127,"text":195},"markdown","content:4.usage:composables:useSupabaseSession.md","content","4.usage/composables/useSupabaseSession.md","4.usage/composables/useSupabaseSession","md",[552,554],{"_path":22,"title":21,"description":553},"Make requests to the Supabase API with the useSupabaseClient composable",{"_path":28,"title":27,"description":555},"Auto import and use your Supabase user with the useSupabaseUser composable",1724940863116] \ No newline at end of file +[{"data":1,"prerenderedAt":556},["ShallowReactive",2],{"navigation":3,"/usage/composables/usesupabasesession":58,"/usage/composables/usesupabasesession-surround":551},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":25,"_dir":59,"_draft":60,"_partial":60,"_locale":61,"title":24,"description":62,"body":63,"_type":545,"_id":546,"_source":547,"_file":548,"_stem":549,"_extension":550},"composables",false,"","Auto import and use your Supabase user's session with the useSupabaseSession composable",{"type":64,"children":65,"toc":542},"root",[66,85,173,189,196,226,239,447,452,515,536],{"type":67,"tag":68,"props":69,"children":70},"element","p",{},[71,74,83],{"type":72,"value":73},"text","Once logged in, you can ",{"type":67,"tag":75,"props":76,"children":80},"a",{"href":77,"rel":78},"https://nuxt.com/docs/guide/directory-structure/composables",[79],"nofollow",[81],{"type":72,"value":82},"auto-import",{"type":72,"value":84}," your user's session everywhere inside your vue files.",{"type":67,"tag":86,"props":87,"children":91},"pre",{"className":88,"code":89,"language":90,"meta":61,"style":61},"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","\u003Cscript setup>\nconst session = useSupabaseSession()\n\u003C/script>\n","vue",[92],{"type":67,"tag":93,"props":94,"children":95},"code",{"__ignoreMap":61},[96,125,156],{"type":67,"tag":97,"props":98,"children":101},"span",{"class":99,"line":100},"line",1,[102,108,114,120],{"type":67,"tag":97,"props":103,"children":105},{"style":104},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[106],{"type":72,"value":107},"\u003C",{"type":67,"tag":97,"props":109,"children":111},{"style":110},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[112],{"type":72,"value":113},"script",{"type":67,"tag":97,"props":115,"children":117},{"style":116},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[118],{"type":72,"value":119}," setup",{"type":67,"tag":97,"props":121,"children":122},{"style":104},[123],{"type":72,"value":124},">\n",{"type":67,"tag":97,"props":126,"children":128},{"class":99,"line":127},2,[129,134,140,145,151],{"type":67,"tag":97,"props":130,"children":131},{"style":116},[132],{"type":72,"value":133},"const",{"type":67,"tag":97,"props":135,"children":137},{"style":136},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[138],{"type":72,"value":139}," session ",{"type":67,"tag":97,"props":141,"children":142},{"style":104},[143],{"type":72,"value":144},"=",{"type":67,"tag":97,"props":146,"children":148},{"style":147},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[149],{"type":72,"value":150}," useSupabaseSession",{"type":67,"tag":97,"props":152,"children":153},{"style":136},[154],{"type":72,"value":155},"()\n",{"type":67,"tag":97,"props":157,"children":159},{"class":99,"line":158},3,[160,165,169],{"type":67,"tag":97,"props":161,"children":162},{"style":104},[163],{"type":72,"value":164},"\u003C/",{"type":67,"tag":97,"props":166,"children":167},{"style":110},[168],{"type":72,"value":113},{"type":67,"tag":97,"props":170,"children":171},{"style":104},[172],{"type":72,"value":124},{"type":67,"tag":174,"props":175,"children":177},"callout",{"icon":176},"i-heroicons-light-bulb",[178],{"type":67,"tag":68,"props":179,"children":180},{},[181,183,187],{"type":72,"value":182},"If you just need the User's information you can use ",{"type":67,"tag":75,"props":184,"children":185},{"href":28},[186],{"type":72,"value":27},{"type":72,"value":188}," which returns just the User information of the session.",{"type":67,"tag":190,"props":191,"children":193},"h2",{"id":192},"auth-middleware",[194],{"type":72,"value":195},"Auth middleware",{"type":67,"tag":174,"props":197,"children":198},{"icon":176},[199],{"type":67,"tag":68,"props":200,"children":201},{},[202,204,210,212,217,219,224],{"type":72,"value":203},"By default, the module is implementing a redirect middleware. All pages of your application are automatically redirected to the ",{"type":67,"tag":75,"props":205,"children":207},{"href":206},"/get-started#redirectoptions",[208],{"type":72,"value":209},"login",{"type":72,"value":211}," page. However, you can allow redirection to \"public\" pages by setting the ",{"type":67,"tag":75,"props":213,"children":214},{"href":206},[215],{"type":72,"value":216},"exclude",{"type":72,"value":218}," redirect option. Alternatively, you can enable the redirect only for certain routes using the ",{"type":67,"tag":75,"props":220,"children":221},{"href":206},[222],{"type":72,"value":223},"include",{"type":72,"value":225}," redirect option.",{"type":67,"tag":68,"props":227,"children":228},{},[229,231,237],{"type":72,"value":230},"If the ",{"type":67,"tag":75,"props":232,"children":234},{"href":233},"/get-started#redirect",[235],{"type":72,"value":236},"redirect",{"type":72,"value":238}," option is disabled, you can protect your authenticated routes by creating a custom middleware in your project, here is an example:",{"type":67,"tag":86,"props":240,"children":245},{"className":241,"code":242,"filename":243,"language":244,"meta":61,"style":61},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","export default defineNuxtRouteMiddleware((to, _from) => {\n const session = useSupabaseSession()\n\n if (!session.value) {\n return navigateTo('/login')\n }\n})\n","middleware/auth.ts","ts",[246],{"type":67,"tag":93,"props":247,"children":248},{"__ignoreMap":61},[249,308,334,343,387,425,434],{"type":67,"tag":97,"props":250,"children":251},{"class":99,"line":100},[252,258,263,268,273,277,283,288,293,298,303],{"type":67,"tag":97,"props":253,"children":255},{"style":254},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[256],{"type":72,"value":257},"export",{"type":67,"tag":97,"props":259,"children":260},{"style":254},[261],{"type":72,"value":262}," default",{"type":67,"tag":97,"props":264,"children":265},{"style":147},[266],{"type":72,"value":267}," defineNuxtRouteMiddleware",{"type":67,"tag":97,"props":269,"children":270},{"style":136},[271],{"type":72,"value":272},"(",{"type":67,"tag":97,"props":274,"children":275},{"style":104},[276],{"type":72,"value":272},{"type":67,"tag":97,"props":278,"children":280},{"style":279},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[281],{"type":72,"value":282},"to",{"type":67,"tag":97,"props":284,"children":285},{"style":104},[286],{"type":72,"value":287},",",{"type":67,"tag":97,"props":289,"children":290},{"style":279},[291],{"type":72,"value":292}," _from",{"type":67,"tag":97,"props":294,"children":295},{"style":104},[296],{"type":72,"value":297},")",{"type":67,"tag":97,"props":299,"children":300},{"style":116},[301],{"type":72,"value":302}," =>",{"type":67,"tag":97,"props":304,"children":305},{"style":104},[306],{"type":72,"value":307}," {\n",{"type":67,"tag":97,"props":309,"children":310},{"class":99,"line":127},[311,316,321,326,330],{"type":67,"tag":97,"props":312,"children":313},{"style":116},[314],{"type":72,"value":315}," const",{"type":67,"tag":97,"props":317,"children":318},{"style":136},[319],{"type":72,"value":320}," session",{"type":67,"tag":97,"props":322,"children":323},{"style":104},[324],{"type":72,"value":325}," =",{"type":67,"tag":97,"props":327,"children":328},{"style":147},[329],{"type":72,"value":150},{"type":67,"tag":97,"props":331,"children":332},{"style":110},[333],{"type":72,"value":155},{"type":67,"tag":97,"props":335,"children":336},{"class":99,"line":158},[337],{"type":67,"tag":97,"props":338,"children":340},{"emptyLinePlaceholder":339},true,[341],{"type":72,"value":342},"\n",{"type":67,"tag":97,"props":344,"children":346},{"class":99,"line":345},4,[347,352,357,362,367,372,377,382],{"type":67,"tag":97,"props":348,"children":349},{"style":254},[350],{"type":72,"value":351}," if",{"type":67,"tag":97,"props":353,"children":354},{"style":110},[355],{"type":72,"value":356}," (",{"type":67,"tag":97,"props":358,"children":359},{"style":104},[360],{"type":72,"value":361},"!",{"type":67,"tag":97,"props":363,"children":364},{"style":136},[365],{"type":72,"value":366},"session",{"type":67,"tag":97,"props":368,"children":369},{"style":104},[370],{"type":72,"value":371},".",{"type":67,"tag":97,"props":373,"children":374},{"style":136},[375],{"type":72,"value":376},"value",{"type":67,"tag":97,"props":378,"children":379},{"style":110},[380],{"type":72,"value":381},") ",{"type":67,"tag":97,"props":383,"children":384},{"style":104},[385],{"type":72,"value":386},"{\n",{"type":67,"tag":97,"props":388,"children":390},{"class":99,"line":389},5,[391,396,401,405,410,416,420],{"type":67,"tag":97,"props":392,"children":393},{"style":254},[394],{"type":72,"value":395}," return",{"type":67,"tag":97,"props":397,"children":398},{"style":147},[399],{"type":72,"value":400}," navigateTo",{"type":67,"tag":97,"props":402,"children":403},{"style":110},[404],{"type":72,"value":272},{"type":67,"tag":97,"props":406,"children":407},{"style":104},[408],{"type":72,"value":409},"'",{"type":67,"tag":97,"props":411,"children":413},{"style":412},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[414],{"type":72,"value":415},"/login",{"type":67,"tag":97,"props":417,"children":418},{"style":104},[419],{"type":72,"value":409},{"type":67,"tag":97,"props":421,"children":422},{"style":110},[423],{"type":72,"value":424},")\n",{"type":67,"tag":97,"props":426,"children":428},{"class":99,"line":427},6,[429],{"type":67,"tag":97,"props":430,"children":431},{"style":104},[432],{"type":72,"value":433}," }\n",{"type":67,"tag":97,"props":435,"children":437},{"class":99,"line":436},7,[438,443],{"type":67,"tag":97,"props":439,"children":440},{"style":104},[441],{"type":72,"value":442},"}",{"type":67,"tag":97,"props":444,"children":445},{"style":136},[446],{"type":72,"value":424},{"type":67,"tag":68,"props":448,"children":449},{},[450],{"type":72,"value":451},"Then you can reference your middleware in your page with:",{"type":67,"tag":86,"props":453,"children":456},{"className":241,"code":454,"filename":455,"language":244,"meta":61,"style":61},"definePageMeta({\n middleware: 'auth'\n})\n","pages/dashboard.vue",[457],{"type":67,"tag":93,"props":458,"children":459},{"__ignoreMap":61},[460,476,504],{"type":67,"tag":97,"props":461,"children":462},{"class":99,"line":100},[463,468,472],{"type":67,"tag":97,"props":464,"children":465},{"style":147},[466],{"type":72,"value":467},"definePageMeta",{"type":67,"tag":97,"props":469,"children":470},{"style":136},[471],{"type":72,"value":272},{"type":67,"tag":97,"props":473,"children":474},{"style":104},[475],{"type":72,"value":386},{"type":67,"tag":97,"props":477,"children":478},{"class":99,"line":127},[479,484,489,494,499],{"type":67,"tag":97,"props":480,"children":481},{"style":110},[482],{"type":72,"value":483}," middleware",{"type":67,"tag":97,"props":485,"children":486},{"style":104},[487],{"type":72,"value":488},":",{"type":67,"tag":97,"props":490,"children":491},{"style":104},[492],{"type":72,"value":493}," '",{"type":67,"tag":97,"props":495,"children":496},{"style":412},[497],{"type":72,"value":498},"auth",{"type":67,"tag":97,"props":500,"children":501},{"style":104},[502],{"type":72,"value":503},"'\n",{"type":67,"tag":97,"props":505,"children":506},{"class":99,"line":158},[507,511],{"type":67,"tag":97,"props":508,"children":509},{"style":104},[510],{"type":72,"value":442},{"type":67,"tag":97,"props":512,"children":513},{"style":136},[514],{"type":72,"value":424},{"type":67,"tag":68,"props":516,"children":517},{},[518,520,527,529,535],{"type":72,"value":519},"Learn more about ",{"type":67,"tag":75,"props":521,"children":524},{"href":522,"rel":523},"https://nuxt.com/docs/guide/directory-structure/middleware",[79],[525],{"type":72,"value":526},"Nuxt middleware",{"type":72,"value":528}," and ",{"type":67,"tag":75,"props":530,"children":533},{"href":531,"rel":532},"https://nuxt.com/docs/guide/directory-structure/pages#page-metadata",[79],[534],{"type":72,"value":467},{"type":72,"value":371},{"type":67,"tag":537,"props":538,"children":539},"style",{},[540],{"type":72,"value":541},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":61,"searchDepth":127,"depth":127,"links":543},[544],{"id":192,"depth":127,"text":195},"markdown","content:4.usage:composables:useSupabaseSession.md","content","4.usage/composables/useSupabaseSession.md","4.usage/composables/useSupabaseSession","md",[552,554],{"_path":22,"title":21,"description":553},"Make requests to the Supabase API with the useSupabaseClient composable",{"_path":28,"title":27,"description":555},"Auto import and use your Supabase user with the useSupabaseUser composable",1724942526911] \ No newline at end of file diff --git a/usage/composables/usesupabasesession/index.html b/usage/composables/usesupabasesession/index.html index 771cf160..eb30d1e1 100644 --- a/usage/composables/usesupabasesession/index.html +++ b/usage/composables/usesupabasesession/index.html @@ -61,7 +61,7 @@ - + @@ -118,5 +118,5 @@ middleware: 'auth' })

Learn more about Nuxt middleware and definePageMeta.


Made with Nuxt Studio
- - \ No newline at end of file + + \ No newline at end of file diff --git a/usage/composables/usesupabaseuser/_payload.json b/usage/composables/usesupabaseuser/_payload.json index 8798d70d..331313ee 100644 --- a/usage/composables/usesupabaseuser/_payload.json +++ b/usage/composables/usesupabaseuser/_payload.json @@ -1 +1 @@ -[{"data":1,"prerenderedAt":542},["ShallowReactive",2],{"navigation":3,"/usage/composables/usesupabaseuser":58,"/usage/composables/usesupabaseuser-surround":537},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":28,"_dir":59,"_draft":60,"_partial":60,"_locale":61,"title":27,"description":62,"body":63,"_type":531,"_id":532,"_source":533,"_file":534,"_stem":535,"_extension":536},"composables",false,"","Auto import and use your Supabase user with the useSupabaseUser composable",{"type":64,"children":65,"toc":528},"root",[66,85,173,180,212,225,433,438,501,522],{"type":67,"tag":68,"props":69,"children":70},"element","p",{},[71,74,83],{"type":72,"value":73},"text","Once logged in, you can ",{"type":67,"tag":75,"props":76,"children":80},"a",{"href":77,"rel":78},"https://nuxt.com/docs/guide/directory-structure/composables",[79],"nofollow",[81],{"type":72,"value":82},"auto-import",{"type":72,"value":84}," your user everywhere inside your vue files.",{"type":67,"tag":86,"props":87,"children":91},"pre",{"className":88,"code":89,"language":90,"meta":61,"style":61},"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","\u003Cscript setup>\nconst user = useSupabaseUser()\n\u003C/script>\n","vue",[92],{"type":67,"tag":93,"props":94,"children":95},"code",{"__ignoreMap":61},[96,125,156],{"type":67,"tag":97,"props":98,"children":101},"span",{"class":99,"line":100},"line",1,[102,108,114,120],{"type":67,"tag":97,"props":103,"children":105},{"style":104},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[106],{"type":72,"value":107},"\u003C",{"type":67,"tag":97,"props":109,"children":111},{"style":110},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[112],{"type":72,"value":113},"script",{"type":67,"tag":97,"props":115,"children":117},{"style":116},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[118],{"type":72,"value":119}," setup",{"type":67,"tag":97,"props":121,"children":122},{"style":104},[123],{"type":72,"value":124},">\n",{"type":67,"tag":97,"props":126,"children":128},{"class":99,"line":127},2,[129,134,140,145,151],{"type":67,"tag":97,"props":130,"children":131},{"style":116},[132],{"type":72,"value":133},"const",{"type":67,"tag":97,"props":135,"children":137},{"style":136},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[138],{"type":72,"value":139}," user ",{"type":67,"tag":97,"props":141,"children":142},{"style":104},[143],{"type":72,"value":144},"=",{"type":67,"tag":97,"props":146,"children":148},{"style":147},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[149],{"type":72,"value":150}," useSupabaseUser",{"type":67,"tag":97,"props":152,"children":153},{"style":136},[154],{"type":72,"value":155},"()\n",{"type":67,"tag":97,"props":157,"children":159},{"class":99,"line":158},3,[160,165,169],{"type":67,"tag":97,"props":161,"children":162},{"style":104},[163],{"type":72,"value":164},"\u003C/",{"type":67,"tag":97,"props":166,"children":167},{"style":110},[168],{"type":72,"value":113},{"type":67,"tag":97,"props":170,"children":171},{"style":104},[172],{"type":72,"value":124},{"type":67,"tag":174,"props":175,"children":177},"h2",{"id":176},"auth-middleware",[178],{"type":72,"value":179},"Auth middleware",{"type":67,"tag":181,"props":182,"children":184},"callout",{"icon":183},"i-heroicons-light-bulb",[185],{"type":67,"tag":68,"props":186,"children":187},{},[188,190,196,198,203,205,210],{"type":72,"value":189},"By default, the module is implementing a redirect middleware. All pages of your application are automatically redirected to the ",{"type":67,"tag":75,"props":191,"children":193},{"href":192},"/get-started#redirectoptions",[194],{"type":72,"value":195},"login",{"type":72,"value":197}," page. However, you can allow redirection to \"public\" pages by setting the ",{"type":67,"tag":75,"props":199,"children":200},{"href":192},[201],{"type":72,"value":202},"exclude",{"type":72,"value":204}," redirect option. Alternatively, you can enable the redirect only for certain routes using the ",{"type":67,"tag":75,"props":206,"children":207},{"href":192},[208],{"type":72,"value":209},"include",{"type":72,"value":211}," redirect option.",{"type":67,"tag":68,"props":213,"children":214},{},[215,217,223],{"type":72,"value":216},"If the ",{"type":67,"tag":75,"props":218,"children":220},{"href":219},"/get-started#redirect",[221],{"type":72,"value":222},"redirect",{"type":72,"value":224}," option is disabled, you can protect your authenticated routes by creating a custom middleware in your project, here is an example:",{"type":67,"tag":86,"props":226,"children":231},{"className":227,"code":228,"filename":229,"language":230,"meta":61,"style":61},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","export default defineNuxtRouteMiddleware((to, _from) => {\n const user = useSupabaseUser()\n\n if (!user.value) {\n return navigateTo('/login')\n }\n})\n","middleware/auth.ts","ts",[232],{"type":67,"tag":93,"props":233,"children":234},{"__ignoreMap":61},[235,294,320,329,373,411,420],{"type":67,"tag":97,"props":236,"children":237},{"class":99,"line":100},[238,244,249,254,259,263,269,274,279,284,289],{"type":67,"tag":97,"props":239,"children":241},{"style":240},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[242],{"type":72,"value":243},"export",{"type":67,"tag":97,"props":245,"children":246},{"style":240},[247],{"type":72,"value":248}," default",{"type":67,"tag":97,"props":250,"children":251},{"style":147},[252],{"type":72,"value":253}," defineNuxtRouteMiddleware",{"type":67,"tag":97,"props":255,"children":256},{"style":136},[257],{"type":72,"value":258},"(",{"type":67,"tag":97,"props":260,"children":261},{"style":104},[262],{"type":72,"value":258},{"type":67,"tag":97,"props":264,"children":266},{"style":265},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[267],{"type":72,"value":268},"to",{"type":67,"tag":97,"props":270,"children":271},{"style":104},[272],{"type":72,"value":273},",",{"type":67,"tag":97,"props":275,"children":276},{"style":265},[277],{"type":72,"value":278}," _from",{"type":67,"tag":97,"props":280,"children":281},{"style":104},[282],{"type":72,"value":283},")",{"type":67,"tag":97,"props":285,"children":286},{"style":116},[287],{"type":72,"value":288}," =>",{"type":67,"tag":97,"props":290,"children":291},{"style":104},[292],{"type":72,"value":293}," {\n",{"type":67,"tag":97,"props":295,"children":296},{"class":99,"line":127},[297,302,307,312,316],{"type":67,"tag":97,"props":298,"children":299},{"style":116},[300],{"type":72,"value":301}," const",{"type":67,"tag":97,"props":303,"children":304},{"style":136},[305],{"type":72,"value":306}," user",{"type":67,"tag":97,"props":308,"children":309},{"style":104},[310],{"type":72,"value":311}," =",{"type":67,"tag":97,"props":313,"children":314},{"style":147},[315],{"type":72,"value":150},{"type":67,"tag":97,"props":317,"children":318},{"style":110},[319],{"type":72,"value":155},{"type":67,"tag":97,"props":321,"children":322},{"class":99,"line":158},[323],{"type":67,"tag":97,"props":324,"children":326},{"emptyLinePlaceholder":325},true,[327],{"type":72,"value":328},"\n",{"type":67,"tag":97,"props":330,"children":332},{"class":99,"line":331},4,[333,338,343,348,353,358,363,368],{"type":67,"tag":97,"props":334,"children":335},{"style":240},[336],{"type":72,"value":337}," if",{"type":67,"tag":97,"props":339,"children":340},{"style":110},[341],{"type":72,"value":342}," (",{"type":67,"tag":97,"props":344,"children":345},{"style":104},[346],{"type":72,"value":347},"!",{"type":67,"tag":97,"props":349,"children":350},{"style":136},[351],{"type":72,"value":352},"user",{"type":67,"tag":97,"props":354,"children":355},{"style":104},[356],{"type":72,"value":357},".",{"type":67,"tag":97,"props":359,"children":360},{"style":136},[361],{"type":72,"value":362},"value",{"type":67,"tag":97,"props":364,"children":365},{"style":110},[366],{"type":72,"value":367},") ",{"type":67,"tag":97,"props":369,"children":370},{"style":104},[371],{"type":72,"value":372},"{\n",{"type":67,"tag":97,"props":374,"children":376},{"class":99,"line":375},5,[377,382,387,391,396,402,406],{"type":67,"tag":97,"props":378,"children":379},{"style":240},[380],{"type":72,"value":381}," return",{"type":67,"tag":97,"props":383,"children":384},{"style":147},[385],{"type":72,"value":386}," navigateTo",{"type":67,"tag":97,"props":388,"children":389},{"style":110},[390],{"type":72,"value":258},{"type":67,"tag":97,"props":392,"children":393},{"style":104},[394],{"type":72,"value":395},"'",{"type":67,"tag":97,"props":397,"children":399},{"style":398},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[400],{"type":72,"value":401},"/login",{"type":67,"tag":97,"props":403,"children":404},{"style":104},[405],{"type":72,"value":395},{"type":67,"tag":97,"props":407,"children":408},{"style":110},[409],{"type":72,"value":410},")\n",{"type":67,"tag":97,"props":412,"children":414},{"class":99,"line":413},6,[415],{"type":67,"tag":97,"props":416,"children":417},{"style":104},[418],{"type":72,"value":419}," }\n",{"type":67,"tag":97,"props":421,"children":423},{"class":99,"line":422},7,[424,429],{"type":67,"tag":97,"props":425,"children":426},{"style":104},[427],{"type":72,"value":428},"}",{"type":67,"tag":97,"props":430,"children":431},{"style":136},[432],{"type":72,"value":410},{"type":67,"tag":68,"props":434,"children":435},{},[436],{"type":72,"value":437},"Then you can reference your middleware in your page with:",{"type":67,"tag":86,"props":439,"children":442},{"className":227,"code":440,"filename":441,"language":230,"meta":61,"style":61},"definePageMeta({\n middleware: 'auth'\n})\n","pages/dashboard.vue",[443],{"type":67,"tag":93,"props":444,"children":445},{"__ignoreMap":61},[446,462,490],{"type":67,"tag":97,"props":447,"children":448},{"class":99,"line":100},[449,454,458],{"type":67,"tag":97,"props":450,"children":451},{"style":147},[452],{"type":72,"value":453},"definePageMeta",{"type":67,"tag":97,"props":455,"children":456},{"style":136},[457],{"type":72,"value":258},{"type":67,"tag":97,"props":459,"children":460},{"style":104},[461],{"type":72,"value":372},{"type":67,"tag":97,"props":463,"children":464},{"class":99,"line":127},[465,470,475,480,485],{"type":67,"tag":97,"props":466,"children":467},{"style":110},[468],{"type":72,"value":469}," middleware",{"type":67,"tag":97,"props":471,"children":472},{"style":104},[473],{"type":72,"value":474},":",{"type":67,"tag":97,"props":476,"children":477},{"style":104},[478],{"type":72,"value":479}," '",{"type":67,"tag":97,"props":481,"children":482},{"style":398},[483],{"type":72,"value":484},"auth",{"type":67,"tag":97,"props":486,"children":487},{"style":104},[488],{"type":72,"value":489},"'\n",{"type":67,"tag":97,"props":491,"children":492},{"class":99,"line":158},[493,497],{"type":67,"tag":97,"props":494,"children":495},{"style":104},[496],{"type":72,"value":428},{"type":67,"tag":97,"props":498,"children":499},{"style":136},[500],{"type":72,"value":410},{"type":67,"tag":68,"props":502,"children":503},{},[504,506,513,515,521],{"type":72,"value":505},"Learn more about ",{"type":67,"tag":75,"props":507,"children":510},{"href":508,"rel":509},"https://nuxt.com/docs/guide/directory-structure/middleware",[79],[511],{"type":72,"value":512},"Nuxt middleware",{"type":72,"value":514}," and ",{"type":67,"tag":75,"props":516,"children":519},{"href":517,"rel":518},"https://nuxt.com/docs/guide/directory-structure/pages#page-metadata",[79],[520],{"type":72,"value":453},{"type":72,"value":357},{"type":67,"tag":523,"props":524,"children":525},"style",{},[526],{"type":72,"value":527},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":61,"searchDepth":127,"depth":127,"links":529},[530],{"id":176,"depth":127,"text":179},"markdown","content:4.usage:composables:useSupabaseUser.md","content","4.usage/composables/useSupabaseUser.md","4.usage/composables/useSupabaseUser","md",[538,540],{"_path":25,"title":24,"description":539},"Auto import and use your Supabase user's session with the useSupabaseSession composable",{"_path":35,"title":34,"description":541},"Make requests to the Supabase API on server side with the serverSupabaseClient service",1724940863123] \ No newline at end of file +[{"data":1,"prerenderedAt":542},["ShallowReactive",2],{"navigation":3,"/usage/composables/usesupabaseuser":58,"/usage/composables/usesupabaseuser-surround":537},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":28,"_dir":59,"_draft":60,"_partial":60,"_locale":61,"title":27,"description":62,"body":63,"_type":531,"_id":532,"_source":533,"_file":534,"_stem":535,"_extension":536},"composables",false,"","Auto import and use your Supabase user with the useSupabaseUser composable",{"type":64,"children":65,"toc":528},"root",[66,85,173,180,212,225,433,438,501,522],{"type":67,"tag":68,"props":69,"children":70},"element","p",{},[71,74,83],{"type":72,"value":73},"text","Once logged in, you can ",{"type":67,"tag":75,"props":76,"children":80},"a",{"href":77,"rel":78},"https://nuxt.com/docs/guide/directory-structure/composables",[79],"nofollow",[81],{"type":72,"value":82},"auto-import",{"type":72,"value":84}," your user everywhere inside your vue files.",{"type":67,"tag":86,"props":87,"children":91},"pre",{"className":88,"code":89,"language":90,"meta":61,"style":61},"language-vue shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","\u003Cscript setup>\nconst user = useSupabaseUser()\n\u003C/script>\n","vue",[92],{"type":67,"tag":93,"props":94,"children":95},"code",{"__ignoreMap":61},[96,125,156],{"type":67,"tag":97,"props":98,"children":101},"span",{"class":99,"line":100},"line",1,[102,108,114,120],{"type":67,"tag":97,"props":103,"children":105},{"style":104},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[106],{"type":72,"value":107},"\u003C",{"type":67,"tag":97,"props":109,"children":111},{"style":110},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[112],{"type":72,"value":113},"script",{"type":67,"tag":97,"props":115,"children":117},{"style":116},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[118],{"type":72,"value":119}," setup",{"type":67,"tag":97,"props":121,"children":122},{"style":104},[123],{"type":72,"value":124},">\n",{"type":67,"tag":97,"props":126,"children":128},{"class":99,"line":127},2,[129,134,140,145,151],{"type":67,"tag":97,"props":130,"children":131},{"style":116},[132],{"type":72,"value":133},"const",{"type":67,"tag":97,"props":135,"children":137},{"style":136},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[138],{"type":72,"value":139}," user ",{"type":67,"tag":97,"props":141,"children":142},{"style":104},[143],{"type":72,"value":144},"=",{"type":67,"tag":97,"props":146,"children":148},{"style":147},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[149],{"type":72,"value":150}," useSupabaseUser",{"type":67,"tag":97,"props":152,"children":153},{"style":136},[154],{"type":72,"value":155},"()\n",{"type":67,"tag":97,"props":157,"children":159},{"class":99,"line":158},3,[160,165,169],{"type":67,"tag":97,"props":161,"children":162},{"style":104},[163],{"type":72,"value":164},"\u003C/",{"type":67,"tag":97,"props":166,"children":167},{"style":110},[168],{"type":72,"value":113},{"type":67,"tag":97,"props":170,"children":171},{"style":104},[172],{"type":72,"value":124},{"type":67,"tag":174,"props":175,"children":177},"h2",{"id":176},"auth-middleware",[178],{"type":72,"value":179},"Auth middleware",{"type":67,"tag":181,"props":182,"children":184},"callout",{"icon":183},"i-heroicons-light-bulb",[185],{"type":67,"tag":68,"props":186,"children":187},{},[188,190,196,198,203,205,210],{"type":72,"value":189},"By default, the module is implementing a redirect middleware. All pages of your application are automatically redirected to the ",{"type":67,"tag":75,"props":191,"children":193},{"href":192},"/get-started#redirectoptions",[194],{"type":72,"value":195},"login",{"type":72,"value":197}," page. However, you can allow redirection to \"public\" pages by setting the ",{"type":67,"tag":75,"props":199,"children":200},{"href":192},[201],{"type":72,"value":202},"exclude",{"type":72,"value":204}," redirect option. Alternatively, you can enable the redirect only for certain routes using the ",{"type":67,"tag":75,"props":206,"children":207},{"href":192},[208],{"type":72,"value":209},"include",{"type":72,"value":211}," redirect option.",{"type":67,"tag":68,"props":213,"children":214},{},[215,217,223],{"type":72,"value":216},"If the ",{"type":67,"tag":75,"props":218,"children":220},{"href":219},"/get-started#redirect",[221],{"type":72,"value":222},"redirect",{"type":72,"value":224}," option is disabled, you can protect your authenticated routes by creating a custom middleware in your project, here is an example:",{"type":67,"tag":86,"props":226,"children":231},{"className":227,"code":228,"filename":229,"language":230,"meta":61,"style":61},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","export default defineNuxtRouteMiddleware((to, _from) => {\n const user = useSupabaseUser()\n\n if (!user.value) {\n return navigateTo('/login')\n }\n})\n","middleware/auth.ts","ts",[232],{"type":67,"tag":93,"props":233,"children":234},{"__ignoreMap":61},[235,294,320,329,373,411,420],{"type":67,"tag":97,"props":236,"children":237},{"class":99,"line":100},[238,244,249,254,259,263,269,274,279,284,289],{"type":67,"tag":97,"props":239,"children":241},{"style":240},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[242],{"type":72,"value":243},"export",{"type":67,"tag":97,"props":245,"children":246},{"style":240},[247],{"type":72,"value":248}," default",{"type":67,"tag":97,"props":250,"children":251},{"style":147},[252],{"type":72,"value":253}," defineNuxtRouteMiddleware",{"type":67,"tag":97,"props":255,"children":256},{"style":136},[257],{"type":72,"value":258},"(",{"type":67,"tag":97,"props":260,"children":261},{"style":104},[262],{"type":72,"value":258},{"type":67,"tag":97,"props":264,"children":266},{"style":265},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[267],{"type":72,"value":268},"to",{"type":67,"tag":97,"props":270,"children":271},{"style":104},[272],{"type":72,"value":273},",",{"type":67,"tag":97,"props":275,"children":276},{"style":265},[277],{"type":72,"value":278}," _from",{"type":67,"tag":97,"props":280,"children":281},{"style":104},[282],{"type":72,"value":283},")",{"type":67,"tag":97,"props":285,"children":286},{"style":116},[287],{"type":72,"value":288}," =>",{"type":67,"tag":97,"props":290,"children":291},{"style":104},[292],{"type":72,"value":293}," {\n",{"type":67,"tag":97,"props":295,"children":296},{"class":99,"line":127},[297,302,307,312,316],{"type":67,"tag":97,"props":298,"children":299},{"style":116},[300],{"type":72,"value":301}," const",{"type":67,"tag":97,"props":303,"children":304},{"style":136},[305],{"type":72,"value":306}," user",{"type":67,"tag":97,"props":308,"children":309},{"style":104},[310],{"type":72,"value":311}," =",{"type":67,"tag":97,"props":313,"children":314},{"style":147},[315],{"type":72,"value":150},{"type":67,"tag":97,"props":317,"children":318},{"style":110},[319],{"type":72,"value":155},{"type":67,"tag":97,"props":321,"children":322},{"class":99,"line":158},[323],{"type":67,"tag":97,"props":324,"children":326},{"emptyLinePlaceholder":325},true,[327],{"type":72,"value":328},"\n",{"type":67,"tag":97,"props":330,"children":332},{"class":99,"line":331},4,[333,338,343,348,353,358,363,368],{"type":67,"tag":97,"props":334,"children":335},{"style":240},[336],{"type":72,"value":337}," if",{"type":67,"tag":97,"props":339,"children":340},{"style":110},[341],{"type":72,"value":342}," (",{"type":67,"tag":97,"props":344,"children":345},{"style":104},[346],{"type":72,"value":347},"!",{"type":67,"tag":97,"props":349,"children":350},{"style":136},[351],{"type":72,"value":352},"user",{"type":67,"tag":97,"props":354,"children":355},{"style":104},[356],{"type":72,"value":357},".",{"type":67,"tag":97,"props":359,"children":360},{"style":136},[361],{"type":72,"value":362},"value",{"type":67,"tag":97,"props":364,"children":365},{"style":110},[366],{"type":72,"value":367},") ",{"type":67,"tag":97,"props":369,"children":370},{"style":104},[371],{"type":72,"value":372},"{\n",{"type":67,"tag":97,"props":374,"children":376},{"class":99,"line":375},5,[377,382,387,391,396,402,406],{"type":67,"tag":97,"props":378,"children":379},{"style":240},[380],{"type":72,"value":381}," return",{"type":67,"tag":97,"props":383,"children":384},{"style":147},[385],{"type":72,"value":386}," navigateTo",{"type":67,"tag":97,"props":388,"children":389},{"style":110},[390],{"type":72,"value":258},{"type":67,"tag":97,"props":392,"children":393},{"style":104},[394],{"type":72,"value":395},"'",{"type":67,"tag":97,"props":397,"children":399},{"style":398},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[400],{"type":72,"value":401},"/login",{"type":67,"tag":97,"props":403,"children":404},{"style":104},[405],{"type":72,"value":395},{"type":67,"tag":97,"props":407,"children":408},{"style":110},[409],{"type":72,"value":410},")\n",{"type":67,"tag":97,"props":412,"children":414},{"class":99,"line":413},6,[415],{"type":67,"tag":97,"props":416,"children":417},{"style":104},[418],{"type":72,"value":419}," }\n",{"type":67,"tag":97,"props":421,"children":423},{"class":99,"line":422},7,[424,429],{"type":67,"tag":97,"props":425,"children":426},{"style":104},[427],{"type":72,"value":428},"}",{"type":67,"tag":97,"props":430,"children":431},{"style":136},[432],{"type":72,"value":410},{"type":67,"tag":68,"props":434,"children":435},{},[436],{"type":72,"value":437},"Then you can reference your middleware in your page with:",{"type":67,"tag":86,"props":439,"children":442},{"className":227,"code":440,"filename":441,"language":230,"meta":61,"style":61},"definePageMeta({\n middleware: 'auth'\n})\n","pages/dashboard.vue",[443],{"type":67,"tag":93,"props":444,"children":445},{"__ignoreMap":61},[446,462,490],{"type":67,"tag":97,"props":447,"children":448},{"class":99,"line":100},[449,454,458],{"type":67,"tag":97,"props":450,"children":451},{"style":147},[452],{"type":72,"value":453},"definePageMeta",{"type":67,"tag":97,"props":455,"children":456},{"style":136},[457],{"type":72,"value":258},{"type":67,"tag":97,"props":459,"children":460},{"style":104},[461],{"type":72,"value":372},{"type":67,"tag":97,"props":463,"children":464},{"class":99,"line":127},[465,470,475,480,485],{"type":67,"tag":97,"props":466,"children":467},{"style":110},[468],{"type":72,"value":469}," middleware",{"type":67,"tag":97,"props":471,"children":472},{"style":104},[473],{"type":72,"value":474},":",{"type":67,"tag":97,"props":476,"children":477},{"style":104},[478],{"type":72,"value":479}," '",{"type":67,"tag":97,"props":481,"children":482},{"style":398},[483],{"type":72,"value":484},"auth",{"type":67,"tag":97,"props":486,"children":487},{"style":104},[488],{"type":72,"value":489},"'\n",{"type":67,"tag":97,"props":491,"children":492},{"class":99,"line":158},[493,497],{"type":67,"tag":97,"props":494,"children":495},{"style":104},[496],{"type":72,"value":428},{"type":67,"tag":97,"props":498,"children":499},{"style":136},[500],{"type":72,"value":410},{"type":67,"tag":68,"props":502,"children":503},{},[504,506,513,515,521],{"type":72,"value":505},"Learn more about ",{"type":67,"tag":75,"props":507,"children":510},{"href":508,"rel":509},"https://nuxt.com/docs/guide/directory-structure/middleware",[79],[511],{"type":72,"value":512},"Nuxt middleware",{"type":72,"value":514}," and ",{"type":67,"tag":75,"props":516,"children":519},{"href":517,"rel":518},"https://nuxt.com/docs/guide/directory-structure/pages#page-metadata",[79],[520],{"type":72,"value":453},{"type":72,"value":357},{"type":67,"tag":523,"props":524,"children":525},"style",{},[526],{"type":72,"value":527},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":61,"searchDepth":127,"depth":127,"links":529},[530],{"id":176,"depth":127,"text":179},"markdown","content:4.usage:composables:useSupabaseUser.md","content","4.usage/composables/useSupabaseUser.md","4.usage/composables/useSupabaseUser","md",[538,540],{"_path":25,"title":24,"description":539},"Auto import and use your Supabase user's session with the useSupabaseSession composable",{"_path":35,"title":34,"description":541},"Make requests to the Supabase API on server side with the serverSupabaseClient service",1724942526923] \ No newline at end of file diff --git a/usage/composables/usesupabaseuser/index.html b/usage/composables/usesupabaseuser/index.html index f5f76de8..25027ecc 100644 --- a/usage/composables/usesupabaseuser/index.html +++ b/usage/composables/usesupabaseuser/index.html @@ -61,7 +61,7 @@ - + @@ -118,5 +118,5 @@ middleware: 'auth' })

Learn more about Nuxt middleware and definePageMeta.


Made with Nuxt Studio
- - \ No newline at end of file + + \ No newline at end of file diff --git a/usage/services/serversupabaseclient/_payload.json b/usage/services/serversupabaseclient/_payload.json index 4e3844bd..3f3c58b8 100644 --- a/usage/services/serversupabaseclient/_payload.json +++ b/usage/services/serversupabaseclient/_payload.json @@ -1 +1 @@ -[{"data":1,"prerenderedAt":736},["ShallowReactive",2],{"navigation":3,"/usage/services/serversupabaseclient":58,"/usage/services/serversupabaseclient-surround":730},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":35,"_dir":59,"_draft":60,"_partial":60,"_locale":61,"title":34,"description":62,"body":63,"_type":724,"_id":725,"_source":726,"_file":727,"_stem":728,"_extension":729},"services",false,"","Make requests to the Supabase API on server side with the serverSupabaseClient service",{"type":64,"children":65,"toc":722},"root",[66,91,111,139,463,468,573,587,716],{"type":67,"tag":68,"props":69,"children":72},"element","callout",{"color":70,"icon":71},"amber","i-heroicons-exclamation-triangle-20-solid",[73],{"type":67,"tag":74,"props":75,"children":76},"p",{},[77,80,89],{"type":78,"value":79},"text","This section assumes you're familiar with ",{"type":67,"tag":81,"props":82,"children":86},"a",{"href":83,"rel":84},"https://v3.nuxtjs.org/guide/concepts/server-engine",[85],"nofollow",[87],{"type":78,"value":88},"Nitro",{"type":78,"value":90},", the server engine powered by Nuxt.",{"type":67,"tag":74,"props":92,"children":93},{},[94,96,100,102,109],{"type":78,"value":95},"This function is working similary as the ",{"type":67,"tag":81,"props":97,"children":98},{"href":22},[99],{"type":78,"value":21},{"type":78,"value":101}," composable but is designed to be used in ",{"type":67,"tag":81,"props":103,"children":106},{"href":104,"rel":105},"https://nuxt.com/docs/guide/directory-structure/server#server-routes",[85],[107],{"type":78,"value":108},"server routes",{"type":78,"value":110},".",{"type":67,"tag":74,"props":112,"children":113},{},[114,116,122,124,130,132,137],{"type":78,"value":115},"Define your server route and just import the ",{"type":67,"tag":117,"props":118,"children":120},"code",{"className":119},[],[121],{"type":78,"value":34},{"type":78,"value":123}," from ",{"type":67,"tag":117,"props":125,"children":127},{"className":126},[],[128],{"type":78,"value":129},"#supabase/server",{"type":78,"value":131},". Be careful, ",{"type":67,"tag":117,"props":133,"children":135},{"className":134},[],[136],{"type":78,"value":34},{"type":78,"value":138}," is returning a promise.",{"type":67,"tag":140,"props":141,"children":146},"pre",{"className":142,"code":143,"filename":144,"language":145,"meta":61,"style":61},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","import { serverSupabaseClient } from '#supabase/server'\n\nexport default eventHandler(async (event) => {\n const client = await serverSupabaseClient(event)\n\n const { data } = await client.from('libraries').select('*')\n\n return { libraries: data }\n})\n","server/api/libraries.ts","ts",[147],{"type":67,"tag":117,"props":148,"children":149},{"__ignoreMap":61},[150,199,209,266,308,316,410,418,450],{"type":67,"tag":151,"props":152,"children":155},"span",{"class":153,"line":154},"line",1,[156,162,168,174,179,184,189,194],{"type":67,"tag":151,"props":157,"children":159},{"style":158},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[160],{"type":78,"value":161},"import",{"type":67,"tag":151,"props":163,"children":165},{"style":164},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[166],{"type":78,"value":167}," {",{"type":67,"tag":151,"props":169,"children":171},{"style":170},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[172],{"type":78,"value":173}," serverSupabaseClient",{"type":67,"tag":151,"props":175,"children":176},{"style":164},[177],{"type":78,"value":178}," }",{"type":67,"tag":151,"props":180,"children":181},{"style":158},[182],{"type":78,"value":183}," from",{"type":67,"tag":151,"props":185,"children":186},{"style":164},[187],{"type":78,"value":188}," '",{"type":67,"tag":151,"props":190,"children":192},{"style":191},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[193],{"type":78,"value":129},{"type":67,"tag":151,"props":195,"children":196},{"style":164},[197],{"type":78,"value":198},"'\n",{"type":67,"tag":151,"props":200,"children":202},{"class":153,"line":201},2,[203],{"type":67,"tag":151,"props":204,"children":206},{"emptyLinePlaceholder":205},true,[207],{"type":78,"value":208},"\n",{"type":67,"tag":151,"props":210,"children":212},{"class":153,"line":211},3,[213,218,223,229,234,240,245,251,256,261],{"type":67,"tag":151,"props":214,"children":215},{"style":158},[216],{"type":78,"value":217},"export",{"type":67,"tag":151,"props":219,"children":220},{"style":158},[221],{"type":78,"value":222}," default",{"type":67,"tag":151,"props":224,"children":226},{"style":225},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[227],{"type":78,"value":228}," eventHandler",{"type":67,"tag":151,"props":230,"children":231},{"style":170},[232],{"type":78,"value":233},"(",{"type":67,"tag":151,"props":235,"children":237},{"style":236},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[238],{"type":78,"value":239},"async",{"type":67,"tag":151,"props":241,"children":242},{"style":164},[243],{"type":78,"value":244}," (",{"type":67,"tag":151,"props":246,"children":248},{"style":247},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[249],{"type":78,"value":250},"event",{"type":67,"tag":151,"props":252,"children":253},{"style":164},[254],{"type":78,"value":255},")",{"type":67,"tag":151,"props":257,"children":258},{"style":236},[259],{"type":78,"value":260}," =>",{"type":67,"tag":151,"props":262,"children":263},{"style":164},[264],{"type":78,"value":265}," {\n",{"type":67,"tag":151,"props":267,"children":269},{"class":153,"line":268},4,[270,275,280,285,290,294,299,303],{"type":67,"tag":151,"props":271,"children":272},{"style":236},[273],{"type":78,"value":274}," const",{"type":67,"tag":151,"props":276,"children":277},{"style":170},[278],{"type":78,"value":279}," client",{"type":67,"tag":151,"props":281,"children":282},{"style":164},[283],{"type":78,"value":284}," =",{"type":67,"tag":151,"props":286,"children":287},{"style":158},[288],{"type":78,"value":289}," await",{"type":67,"tag":151,"props":291,"children":292},{"style":225},[293],{"type":78,"value":173},{"type":67,"tag":151,"props":295,"children":297},{"style":296},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[298],{"type":78,"value":233},{"type":67,"tag":151,"props":300,"children":301},{"style":170},[302],{"type":78,"value":250},{"type":67,"tag":151,"props":304,"children":305},{"style":296},[306],{"type":78,"value":307},")\n",{"type":67,"tag":151,"props":309,"children":311},{"class":153,"line":310},5,[312],{"type":67,"tag":151,"props":313,"children":314},{"emptyLinePlaceholder":205},[315],{"type":78,"value":208},{"type":67,"tag":151,"props":317,"children":319},{"class":153,"line":318},6,[320,324,328,333,337,341,345,349,353,358,362,367,372,376,380,384,389,393,397,402,406],{"type":67,"tag":151,"props":321,"children":322},{"style":236},[323],{"type":78,"value":274},{"type":67,"tag":151,"props":325,"children":326},{"style":164},[327],{"type":78,"value":167},{"type":67,"tag":151,"props":329,"children":330},{"style":170},[331],{"type":78,"value":332}," data",{"type":67,"tag":151,"props":334,"children":335},{"style":164},[336],{"type":78,"value":178},{"type":67,"tag":151,"props":338,"children":339},{"style":164},[340],{"type":78,"value":284},{"type":67,"tag":151,"props":342,"children":343},{"style":158},[344],{"type":78,"value":289},{"type":67,"tag":151,"props":346,"children":347},{"style":170},[348],{"type":78,"value":279},{"type":67,"tag":151,"props":350,"children":351},{"style":164},[352],{"type":78,"value":110},{"type":67,"tag":151,"props":354,"children":355},{"style":225},[356],{"type":78,"value":357},"from",{"type":67,"tag":151,"props":359,"children":360},{"style":296},[361],{"type":78,"value":233},{"type":67,"tag":151,"props":363,"children":364},{"style":164},[365],{"type":78,"value":366},"'",{"type":67,"tag":151,"props":368,"children":369},{"style":191},[370],{"type":78,"value":371},"libraries",{"type":67,"tag":151,"props":373,"children":374},{"style":164},[375],{"type":78,"value":366},{"type":67,"tag":151,"props":377,"children":378},{"style":296},[379],{"type":78,"value":255},{"type":67,"tag":151,"props":381,"children":382},{"style":164},[383],{"type":78,"value":110},{"type":67,"tag":151,"props":385,"children":386},{"style":225},[387],{"type":78,"value":388},"select",{"type":67,"tag":151,"props":390,"children":391},{"style":296},[392],{"type":78,"value":233},{"type":67,"tag":151,"props":394,"children":395},{"style":164},[396],{"type":78,"value":366},{"type":67,"tag":151,"props":398,"children":399},{"style":191},[400],{"type":78,"value":401},"*",{"type":67,"tag":151,"props":403,"children":404},{"style":164},[405],{"type":78,"value":366},{"type":67,"tag":151,"props":407,"children":408},{"style":296},[409],{"type":78,"value":307},{"type":67,"tag":151,"props":411,"children":413},{"class":153,"line":412},7,[414],{"type":67,"tag":151,"props":415,"children":416},{"emptyLinePlaceholder":205},[417],{"type":78,"value":208},{"type":67,"tag":151,"props":419,"children":421},{"class":153,"line":420},8,[422,427,431,436,441,445],{"type":67,"tag":151,"props":423,"children":424},{"style":158},[425],{"type":78,"value":426}," return",{"type":67,"tag":151,"props":428,"children":429},{"style":164},[430],{"type":78,"value":167},{"type":67,"tag":151,"props":432,"children":433},{"style":296},[434],{"type":78,"value":435}," libraries",{"type":67,"tag":151,"props":437,"children":438},{"style":164},[439],{"type":78,"value":440},":",{"type":67,"tag":151,"props":442,"children":443},{"style":170},[444],{"type":78,"value":332},{"type":67,"tag":151,"props":446,"children":447},{"style":164},[448],{"type":78,"value":449}," }\n",{"type":67,"tag":151,"props":451,"children":453},{"class":153,"line":452},9,[454,459],{"type":67,"tag":151,"props":455,"children":456},{"style":164},[457],{"type":78,"value":458},"}",{"type":67,"tag":151,"props":460,"children":461},{"style":170},[462],{"type":78,"value":307},{"type":67,"tag":74,"props":464,"children":465},{},[466],{"type":78,"value":467},"Then call your API route from any vue file:",{"type":67,"tag":140,"props":469,"children":472},{"className":142,"code":470,"filename":471,"language":145,"meta":61,"style":61},"const fetchLibrary = async () => {\n const { libraries } = await $fetch('/api/libraries')\n}\n","pages/index.vue",[473],{"type":67,"tag":117,"props":474,"children":475},{"__ignoreMap":61},[476,512,565],{"type":67,"tag":151,"props":477,"children":478},{"class":153,"line":154},[479,484,489,494,499,504,508],{"type":67,"tag":151,"props":480,"children":481},{"style":236},[482],{"type":78,"value":483},"const",{"type":67,"tag":151,"props":485,"children":486},{"style":170},[487],{"type":78,"value":488}," fetchLibrary ",{"type":67,"tag":151,"props":490,"children":491},{"style":164},[492],{"type":78,"value":493},"=",{"type":67,"tag":151,"props":495,"children":496},{"style":236},[497],{"type":78,"value":498}," async",{"type":67,"tag":151,"props":500,"children":501},{"style":164},[502],{"type":78,"value":503}," ()",{"type":67,"tag":151,"props":505,"children":506},{"style":236},[507],{"type":78,"value":260},{"type":67,"tag":151,"props":509,"children":510},{"style":164},[511],{"type":78,"value":265},{"type":67,"tag":151,"props":513,"children":514},{"class":153,"line":201},[515,519,523,527,531,535,539,544,548,552,557,561],{"type":67,"tag":151,"props":516,"children":517},{"style":236},[518],{"type":78,"value":274},{"type":67,"tag":151,"props":520,"children":521},{"style":164},[522],{"type":78,"value":167},{"type":67,"tag":151,"props":524,"children":525},{"style":170},[526],{"type":78,"value":435},{"type":67,"tag":151,"props":528,"children":529},{"style":164},[530],{"type":78,"value":178},{"type":67,"tag":151,"props":532,"children":533},{"style":164},[534],{"type":78,"value":284},{"type":67,"tag":151,"props":536,"children":537},{"style":158},[538],{"type":78,"value":289},{"type":67,"tag":151,"props":540,"children":541},{"style":225},[542],{"type":78,"value":543}," $fetch",{"type":67,"tag":151,"props":545,"children":546},{"style":296},[547],{"type":78,"value":233},{"type":67,"tag":151,"props":549,"children":550},{"style":164},[551],{"type":78,"value":366},{"type":67,"tag":151,"props":553,"children":554},{"style":191},[555],{"type":78,"value":556},"/api/libraries",{"type":67,"tag":151,"props":558,"children":559},{"style":164},[560],{"type":78,"value":366},{"type":67,"tag":151,"props":562,"children":563},{"style":296},[564],{"type":78,"value":307},{"type":67,"tag":151,"props":566,"children":567},{"class":153,"line":211},[568],{"type":67,"tag":151,"props":569,"children":570},{"style":164},[571],{"type":78,"value":572},"}\n",{"type":67,"tag":74,"props":574,"children":575},{},[576,578,585],{"type":78,"value":577},"Be careful, if you want to call this route on SSR, please read this ",{"type":67,"tag":81,"props":579,"children":582},{"href":580,"rel":581},"https://nuxt.com/docs/getting-started/data-fetching#isomorphic-fetch-and-fetch",[85],[583],{"type":78,"value":584},"section",{"type":78,"value":586},", you must send your browser cookies including your supabase token.",{"type":67,"tag":140,"props":588,"children":590},{"className":142,"code":589,"filename":471,"language":145,"meta":61,"style":61},"const { data: { libraries }} = await useFetch('/api/libraries', {\n headers: useRequestHeaders(['cookie'])\n})\n",[591],{"type":67,"tag":117,"props":592,"children":593},{"__ignoreMap":61},[594,665,705],{"type":67,"tag":151,"props":595,"children":596},{"class":153,"line":154},[597,601,605,609,613,617,622,627,631,635,640,644,648,652,656,661],{"type":67,"tag":151,"props":598,"children":599},{"style":236},[600],{"type":78,"value":483},{"type":67,"tag":151,"props":602,"children":603},{"style":164},[604],{"type":78,"value":167},{"type":67,"tag":151,"props":606,"children":607},{"style":296},[608],{"type":78,"value":332},{"type":67,"tag":151,"props":610,"children":611},{"style":164},[612],{"type":78,"value":440},{"type":67,"tag":151,"props":614,"children":615},{"style":164},[616],{"type":78,"value":167},{"type":67,"tag":151,"props":618,"children":619},{"style":170},[620],{"type":78,"value":621}," libraries ",{"type":67,"tag":151,"props":623,"children":624},{"style":164},[625],{"type":78,"value":626},"}}",{"type":67,"tag":151,"props":628,"children":629},{"style":164},[630],{"type":78,"value":284},{"type":67,"tag":151,"props":632,"children":633},{"style":158},[634],{"type":78,"value":289},{"type":67,"tag":151,"props":636,"children":637},{"style":225},[638],{"type":78,"value":639}," useFetch",{"type":67,"tag":151,"props":641,"children":642},{"style":170},[643],{"type":78,"value":233},{"type":67,"tag":151,"props":645,"children":646},{"style":164},[647],{"type":78,"value":366},{"type":67,"tag":151,"props":649,"children":650},{"style":191},[651],{"type":78,"value":556},{"type":67,"tag":151,"props":653,"children":654},{"style":164},[655],{"type":78,"value":366},{"type":67,"tag":151,"props":657,"children":658},{"style":164},[659],{"type":78,"value":660},",",{"type":67,"tag":151,"props":662,"children":663},{"style":164},[664],{"type":78,"value":265},{"type":67,"tag":151,"props":666,"children":667},{"class":153,"line":201},[668,673,677,682,687,691,696,700],{"type":67,"tag":151,"props":669,"children":670},{"style":296},[671],{"type":78,"value":672}," headers",{"type":67,"tag":151,"props":674,"children":675},{"style":164},[676],{"type":78,"value":440},{"type":67,"tag":151,"props":678,"children":679},{"style":225},[680],{"type":78,"value":681}," useRequestHeaders",{"type":67,"tag":151,"props":683,"children":684},{"style":170},[685],{"type":78,"value":686},"([",{"type":67,"tag":151,"props":688,"children":689},{"style":164},[690],{"type":78,"value":366},{"type":67,"tag":151,"props":692,"children":693},{"style":191},[694],{"type":78,"value":695},"cookie",{"type":67,"tag":151,"props":697,"children":698},{"style":164},[699],{"type":78,"value":366},{"type":67,"tag":151,"props":701,"children":702},{"style":170},[703],{"type":78,"value":704},"])\n",{"type":67,"tag":151,"props":706,"children":707},{"class":153,"line":211},[708,712],{"type":67,"tag":151,"props":709,"children":710},{"style":164},[711],{"type":78,"value":458},{"type":67,"tag":151,"props":713,"children":714},{"style":170},[715],{"type":78,"value":307},{"type":67,"tag":717,"props":718,"children":719},"style",{},[720],{"type":78,"value":721},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":61,"searchDepth":201,"depth":201,"links":723},[],"markdown","content:4.usage:services:1.serverSupabaseClient.md","content","4.usage/services/1.serverSupabaseClient.md","4.usage/services/1.serverSupabaseClient","md",[731,733],{"_path":28,"title":27,"description":732},"Auto import and use your Supabase user with the useSupabaseUser composable",{"_path":38,"title":734,"description":735},"serverServiceRole","Make requests with super admin rights to the Supabase API with the serverSupabaseServiceRole service",1724940862193] \ No newline at end of file +[{"data":1,"prerenderedAt":736},["ShallowReactive",2],{"navigation":3,"/usage/services/serversupabaseclient":58,"/usage/services/serversupabaseclient-surround":730},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":35,"_dir":59,"_draft":60,"_partial":60,"_locale":61,"title":34,"description":62,"body":63,"_type":724,"_id":725,"_source":726,"_file":727,"_stem":728,"_extension":729},"services",false,"","Make requests to the Supabase API on server side with the serverSupabaseClient service",{"type":64,"children":65,"toc":722},"root",[66,91,111,139,463,468,573,587,716],{"type":67,"tag":68,"props":69,"children":72},"element","callout",{"color":70,"icon":71},"amber","i-heroicons-exclamation-triangle-20-solid",[73],{"type":67,"tag":74,"props":75,"children":76},"p",{},[77,80,89],{"type":78,"value":79},"text","This section assumes you're familiar with ",{"type":67,"tag":81,"props":82,"children":86},"a",{"href":83,"rel":84},"https://v3.nuxtjs.org/guide/concepts/server-engine",[85],"nofollow",[87],{"type":78,"value":88},"Nitro",{"type":78,"value":90},", the server engine powered by Nuxt.",{"type":67,"tag":74,"props":92,"children":93},{},[94,96,100,102,109],{"type":78,"value":95},"This function is working similary as the ",{"type":67,"tag":81,"props":97,"children":98},{"href":22},[99],{"type":78,"value":21},{"type":78,"value":101}," composable but is designed to be used in ",{"type":67,"tag":81,"props":103,"children":106},{"href":104,"rel":105},"https://nuxt.com/docs/guide/directory-structure/server#server-routes",[85],[107],{"type":78,"value":108},"server routes",{"type":78,"value":110},".",{"type":67,"tag":74,"props":112,"children":113},{},[114,116,122,124,130,132,137],{"type":78,"value":115},"Define your server route and just import the ",{"type":67,"tag":117,"props":118,"children":120},"code",{"className":119},[],[121],{"type":78,"value":34},{"type":78,"value":123}," from ",{"type":67,"tag":117,"props":125,"children":127},{"className":126},[],[128],{"type":78,"value":129},"#supabase/server",{"type":78,"value":131},". Be careful, ",{"type":67,"tag":117,"props":133,"children":135},{"className":134},[],[136],{"type":78,"value":34},{"type":78,"value":138}," is returning a promise.",{"type":67,"tag":140,"props":141,"children":146},"pre",{"className":142,"code":143,"filename":144,"language":145,"meta":61,"style":61},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","import { serverSupabaseClient } from '#supabase/server'\n\nexport default eventHandler(async (event) => {\n const client = await serverSupabaseClient(event)\n\n const { data } = await client.from('libraries').select('*')\n\n return { libraries: data }\n})\n","server/api/libraries.ts","ts",[147],{"type":67,"tag":117,"props":148,"children":149},{"__ignoreMap":61},[150,199,209,266,308,316,410,418,450],{"type":67,"tag":151,"props":152,"children":155},"span",{"class":153,"line":154},"line",1,[156,162,168,174,179,184,189,194],{"type":67,"tag":151,"props":157,"children":159},{"style":158},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[160],{"type":78,"value":161},"import",{"type":67,"tag":151,"props":163,"children":165},{"style":164},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[166],{"type":78,"value":167}," {",{"type":67,"tag":151,"props":169,"children":171},{"style":170},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[172],{"type":78,"value":173}," serverSupabaseClient",{"type":67,"tag":151,"props":175,"children":176},{"style":164},[177],{"type":78,"value":178}," }",{"type":67,"tag":151,"props":180,"children":181},{"style":158},[182],{"type":78,"value":183}," from",{"type":67,"tag":151,"props":185,"children":186},{"style":164},[187],{"type":78,"value":188}," '",{"type":67,"tag":151,"props":190,"children":192},{"style":191},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[193],{"type":78,"value":129},{"type":67,"tag":151,"props":195,"children":196},{"style":164},[197],{"type":78,"value":198},"'\n",{"type":67,"tag":151,"props":200,"children":202},{"class":153,"line":201},2,[203],{"type":67,"tag":151,"props":204,"children":206},{"emptyLinePlaceholder":205},true,[207],{"type":78,"value":208},"\n",{"type":67,"tag":151,"props":210,"children":212},{"class":153,"line":211},3,[213,218,223,229,234,240,245,251,256,261],{"type":67,"tag":151,"props":214,"children":215},{"style":158},[216],{"type":78,"value":217},"export",{"type":67,"tag":151,"props":219,"children":220},{"style":158},[221],{"type":78,"value":222}," default",{"type":67,"tag":151,"props":224,"children":226},{"style":225},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[227],{"type":78,"value":228}," eventHandler",{"type":67,"tag":151,"props":230,"children":231},{"style":170},[232],{"type":78,"value":233},"(",{"type":67,"tag":151,"props":235,"children":237},{"style":236},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[238],{"type":78,"value":239},"async",{"type":67,"tag":151,"props":241,"children":242},{"style":164},[243],{"type":78,"value":244}," (",{"type":67,"tag":151,"props":246,"children":248},{"style":247},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[249],{"type":78,"value":250},"event",{"type":67,"tag":151,"props":252,"children":253},{"style":164},[254],{"type":78,"value":255},")",{"type":67,"tag":151,"props":257,"children":258},{"style":236},[259],{"type":78,"value":260}," =>",{"type":67,"tag":151,"props":262,"children":263},{"style":164},[264],{"type":78,"value":265}," {\n",{"type":67,"tag":151,"props":267,"children":269},{"class":153,"line":268},4,[270,275,280,285,290,294,299,303],{"type":67,"tag":151,"props":271,"children":272},{"style":236},[273],{"type":78,"value":274}," const",{"type":67,"tag":151,"props":276,"children":277},{"style":170},[278],{"type":78,"value":279}," client",{"type":67,"tag":151,"props":281,"children":282},{"style":164},[283],{"type":78,"value":284}," =",{"type":67,"tag":151,"props":286,"children":287},{"style":158},[288],{"type":78,"value":289}," await",{"type":67,"tag":151,"props":291,"children":292},{"style":225},[293],{"type":78,"value":173},{"type":67,"tag":151,"props":295,"children":297},{"style":296},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[298],{"type":78,"value":233},{"type":67,"tag":151,"props":300,"children":301},{"style":170},[302],{"type":78,"value":250},{"type":67,"tag":151,"props":304,"children":305},{"style":296},[306],{"type":78,"value":307},")\n",{"type":67,"tag":151,"props":309,"children":311},{"class":153,"line":310},5,[312],{"type":67,"tag":151,"props":313,"children":314},{"emptyLinePlaceholder":205},[315],{"type":78,"value":208},{"type":67,"tag":151,"props":317,"children":319},{"class":153,"line":318},6,[320,324,328,333,337,341,345,349,353,358,362,367,372,376,380,384,389,393,397,402,406],{"type":67,"tag":151,"props":321,"children":322},{"style":236},[323],{"type":78,"value":274},{"type":67,"tag":151,"props":325,"children":326},{"style":164},[327],{"type":78,"value":167},{"type":67,"tag":151,"props":329,"children":330},{"style":170},[331],{"type":78,"value":332}," data",{"type":67,"tag":151,"props":334,"children":335},{"style":164},[336],{"type":78,"value":178},{"type":67,"tag":151,"props":338,"children":339},{"style":164},[340],{"type":78,"value":284},{"type":67,"tag":151,"props":342,"children":343},{"style":158},[344],{"type":78,"value":289},{"type":67,"tag":151,"props":346,"children":347},{"style":170},[348],{"type":78,"value":279},{"type":67,"tag":151,"props":350,"children":351},{"style":164},[352],{"type":78,"value":110},{"type":67,"tag":151,"props":354,"children":355},{"style":225},[356],{"type":78,"value":357},"from",{"type":67,"tag":151,"props":359,"children":360},{"style":296},[361],{"type":78,"value":233},{"type":67,"tag":151,"props":363,"children":364},{"style":164},[365],{"type":78,"value":366},"'",{"type":67,"tag":151,"props":368,"children":369},{"style":191},[370],{"type":78,"value":371},"libraries",{"type":67,"tag":151,"props":373,"children":374},{"style":164},[375],{"type":78,"value":366},{"type":67,"tag":151,"props":377,"children":378},{"style":296},[379],{"type":78,"value":255},{"type":67,"tag":151,"props":381,"children":382},{"style":164},[383],{"type":78,"value":110},{"type":67,"tag":151,"props":385,"children":386},{"style":225},[387],{"type":78,"value":388},"select",{"type":67,"tag":151,"props":390,"children":391},{"style":296},[392],{"type":78,"value":233},{"type":67,"tag":151,"props":394,"children":395},{"style":164},[396],{"type":78,"value":366},{"type":67,"tag":151,"props":398,"children":399},{"style":191},[400],{"type":78,"value":401},"*",{"type":67,"tag":151,"props":403,"children":404},{"style":164},[405],{"type":78,"value":366},{"type":67,"tag":151,"props":407,"children":408},{"style":296},[409],{"type":78,"value":307},{"type":67,"tag":151,"props":411,"children":413},{"class":153,"line":412},7,[414],{"type":67,"tag":151,"props":415,"children":416},{"emptyLinePlaceholder":205},[417],{"type":78,"value":208},{"type":67,"tag":151,"props":419,"children":421},{"class":153,"line":420},8,[422,427,431,436,441,445],{"type":67,"tag":151,"props":423,"children":424},{"style":158},[425],{"type":78,"value":426}," return",{"type":67,"tag":151,"props":428,"children":429},{"style":164},[430],{"type":78,"value":167},{"type":67,"tag":151,"props":432,"children":433},{"style":296},[434],{"type":78,"value":435}," libraries",{"type":67,"tag":151,"props":437,"children":438},{"style":164},[439],{"type":78,"value":440},":",{"type":67,"tag":151,"props":442,"children":443},{"style":170},[444],{"type":78,"value":332},{"type":67,"tag":151,"props":446,"children":447},{"style":164},[448],{"type":78,"value":449}," }\n",{"type":67,"tag":151,"props":451,"children":453},{"class":153,"line":452},9,[454,459],{"type":67,"tag":151,"props":455,"children":456},{"style":164},[457],{"type":78,"value":458},"}",{"type":67,"tag":151,"props":460,"children":461},{"style":170},[462],{"type":78,"value":307},{"type":67,"tag":74,"props":464,"children":465},{},[466],{"type":78,"value":467},"Then call your API route from any vue file:",{"type":67,"tag":140,"props":469,"children":472},{"className":142,"code":470,"filename":471,"language":145,"meta":61,"style":61},"const fetchLibrary = async () => {\n const { libraries } = await $fetch('/api/libraries')\n}\n","pages/index.vue",[473],{"type":67,"tag":117,"props":474,"children":475},{"__ignoreMap":61},[476,512,565],{"type":67,"tag":151,"props":477,"children":478},{"class":153,"line":154},[479,484,489,494,499,504,508],{"type":67,"tag":151,"props":480,"children":481},{"style":236},[482],{"type":78,"value":483},"const",{"type":67,"tag":151,"props":485,"children":486},{"style":170},[487],{"type":78,"value":488}," fetchLibrary ",{"type":67,"tag":151,"props":490,"children":491},{"style":164},[492],{"type":78,"value":493},"=",{"type":67,"tag":151,"props":495,"children":496},{"style":236},[497],{"type":78,"value":498}," async",{"type":67,"tag":151,"props":500,"children":501},{"style":164},[502],{"type":78,"value":503}," ()",{"type":67,"tag":151,"props":505,"children":506},{"style":236},[507],{"type":78,"value":260},{"type":67,"tag":151,"props":509,"children":510},{"style":164},[511],{"type":78,"value":265},{"type":67,"tag":151,"props":513,"children":514},{"class":153,"line":201},[515,519,523,527,531,535,539,544,548,552,557,561],{"type":67,"tag":151,"props":516,"children":517},{"style":236},[518],{"type":78,"value":274},{"type":67,"tag":151,"props":520,"children":521},{"style":164},[522],{"type":78,"value":167},{"type":67,"tag":151,"props":524,"children":525},{"style":170},[526],{"type":78,"value":435},{"type":67,"tag":151,"props":528,"children":529},{"style":164},[530],{"type":78,"value":178},{"type":67,"tag":151,"props":532,"children":533},{"style":164},[534],{"type":78,"value":284},{"type":67,"tag":151,"props":536,"children":537},{"style":158},[538],{"type":78,"value":289},{"type":67,"tag":151,"props":540,"children":541},{"style":225},[542],{"type":78,"value":543}," $fetch",{"type":67,"tag":151,"props":545,"children":546},{"style":296},[547],{"type":78,"value":233},{"type":67,"tag":151,"props":549,"children":550},{"style":164},[551],{"type":78,"value":366},{"type":67,"tag":151,"props":553,"children":554},{"style":191},[555],{"type":78,"value":556},"/api/libraries",{"type":67,"tag":151,"props":558,"children":559},{"style":164},[560],{"type":78,"value":366},{"type":67,"tag":151,"props":562,"children":563},{"style":296},[564],{"type":78,"value":307},{"type":67,"tag":151,"props":566,"children":567},{"class":153,"line":211},[568],{"type":67,"tag":151,"props":569,"children":570},{"style":164},[571],{"type":78,"value":572},"}\n",{"type":67,"tag":74,"props":574,"children":575},{},[576,578,585],{"type":78,"value":577},"Be careful, if you want to call this route on SSR, please read this ",{"type":67,"tag":81,"props":579,"children":582},{"href":580,"rel":581},"https://nuxt.com/docs/getting-started/data-fetching#isomorphic-fetch-and-fetch",[85],[583],{"type":78,"value":584},"section",{"type":78,"value":586},", you must send your browser cookies including your supabase token.",{"type":67,"tag":140,"props":588,"children":590},{"className":142,"code":589,"filename":471,"language":145,"meta":61,"style":61},"const { data: { libraries }} = await useFetch('/api/libraries', {\n headers: useRequestHeaders(['cookie'])\n})\n",[591],{"type":67,"tag":117,"props":592,"children":593},{"__ignoreMap":61},[594,665,705],{"type":67,"tag":151,"props":595,"children":596},{"class":153,"line":154},[597,601,605,609,613,617,622,627,631,635,640,644,648,652,656,661],{"type":67,"tag":151,"props":598,"children":599},{"style":236},[600],{"type":78,"value":483},{"type":67,"tag":151,"props":602,"children":603},{"style":164},[604],{"type":78,"value":167},{"type":67,"tag":151,"props":606,"children":607},{"style":296},[608],{"type":78,"value":332},{"type":67,"tag":151,"props":610,"children":611},{"style":164},[612],{"type":78,"value":440},{"type":67,"tag":151,"props":614,"children":615},{"style":164},[616],{"type":78,"value":167},{"type":67,"tag":151,"props":618,"children":619},{"style":170},[620],{"type":78,"value":621}," libraries ",{"type":67,"tag":151,"props":623,"children":624},{"style":164},[625],{"type":78,"value":626},"}}",{"type":67,"tag":151,"props":628,"children":629},{"style":164},[630],{"type":78,"value":284},{"type":67,"tag":151,"props":632,"children":633},{"style":158},[634],{"type":78,"value":289},{"type":67,"tag":151,"props":636,"children":637},{"style":225},[638],{"type":78,"value":639}," useFetch",{"type":67,"tag":151,"props":641,"children":642},{"style":170},[643],{"type":78,"value":233},{"type":67,"tag":151,"props":645,"children":646},{"style":164},[647],{"type":78,"value":366},{"type":67,"tag":151,"props":649,"children":650},{"style":191},[651],{"type":78,"value":556},{"type":67,"tag":151,"props":653,"children":654},{"style":164},[655],{"type":78,"value":366},{"type":67,"tag":151,"props":657,"children":658},{"style":164},[659],{"type":78,"value":660},",",{"type":67,"tag":151,"props":662,"children":663},{"style":164},[664],{"type":78,"value":265},{"type":67,"tag":151,"props":666,"children":667},{"class":153,"line":201},[668,673,677,682,687,691,696,700],{"type":67,"tag":151,"props":669,"children":670},{"style":296},[671],{"type":78,"value":672}," headers",{"type":67,"tag":151,"props":674,"children":675},{"style":164},[676],{"type":78,"value":440},{"type":67,"tag":151,"props":678,"children":679},{"style":225},[680],{"type":78,"value":681}," useRequestHeaders",{"type":67,"tag":151,"props":683,"children":684},{"style":170},[685],{"type":78,"value":686},"([",{"type":67,"tag":151,"props":688,"children":689},{"style":164},[690],{"type":78,"value":366},{"type":67,"tag":151,"props":692,"children":693},{"style":191},[694],{"type":78,"value":695},"cookie",{"type":67,"tag":151,"props":697,"children":698},{"style":164},[699],{"type":78,"value":366},{"type":67,"tag":151,"props":701,"children":702},{"style":170},[703],{"type":78,"value":704},"])\n",{"type":67,"tag":151,"props":706,"children":707},{"class":153,"line":211},[708,712],{"type":67,"tag":151,"props":709,"children":710},{"style":164},[711],{"type":78,"value":458},{"type":67,"tag":151,"props":713,"children":714},{"style":170},[715],{"type":78,"value":307},{"type":67,"tag":717,"props":718,"children":719},"style",{},[720],{"type":78,"value":721},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":61,"searchDepth":201,"depth":201,"links":723},[],"markdown","content:4.usage:services:1.serverSupabaseClient.md","content","4.usage/services/1.serverSupabaseClient.md","4.usage/services/1.serverSupabaseClient","md",[731,733],{"_path":28,"title":27,"description":732},"Auto import and use your Supabase user with the useSupabaseUser composable",{"_path":38,"title":734,"description":735},"serverServiceRole","Make requests with super admin rights to the Supabase API with the serverSupabaseServiceRole service",1724942526484] \ No newline at end of file diff --git a/usage/services/serversupabaseclient/index.html b/usage/services/serversupabaseclient/index.html index d9df771e..4dff162f 100644 --- a/usage/services/serversupabaseclient/index.html +++ b/usage/services/serversupabaseclient/index.html @@ -61,7 +61,7 @@ - + @@ -119,5 +119,5 @@ headers: useRequestHeaders(['cookie']) })
Made with Nuxt Studio
- - \ No newline at end of file + + \ No newline at end of file diff --git a/usage/services/serversupabaseservicerole/_payload.json b/usage/services/serversupabaseservicerole/_payload.json index fbdba0a4..b379d07b 100644 --- a/usage/services/serversupabaseservicerole/_payload.json +++ b/usage/services/serversupabaseservicerole/_payload.json @@ -1 +1 @@ -[{"data":1,"prerenderedAt":613},["ShallowReactive",2],{"navigation":3,"/usage/services/serversupabaseservicerole":58,"/usage/services/serversupabaseservicerole-surround":608},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":38,"_dir":59,"_draft":60,"_partial":60,"_locale":61,"title":62,"description":63,"navigation":64,"body":65,"_type":602,"_id":603,"_source":604,"_file":605,"_stem":606,"_extension":607},"services",false,"","serverServiceRole","Make requests with super admin rights to the Supabase API with the serverSupabaseServiceRole service",{"title":37},{"type":66,"children":67,"toc":600},"root",[68,93,107,127,161,180,484,489,594],{"type":69,"tag":70,"props":71,"children":74},"element","callout",{"color":72,"icon":73},"amber","i-heroicons-exclamation-triangle-20-solid",[75],{"type":69,"tag":76,"props":77,"children":78},"p",{},[79,82,91],{"type":80,"value":81},"text","This section assumes you're familiar with ",{"type":69,"tag":83,"props":84,"children":88},"a",{"href":85,"rel":86},"https://v3.nuxtjs.org/guide/concepts/server-engine",[87],"nofollow",[89],{"type":80,"value":90},"Nitro",{"type":80,"value":92},", the server engine powered by Nuxt.",{"type":69,"tag":76,"props":94,"children":95},{},[96,98,105],{"type":80,"value":97},"This function is designed to work only in ",{"type":69,"tag":83,"props":99,"children":102},{"href":100,"rel":101},"https://nuxt.com/docs/guide/directory-structure/server#server-routes",[87],[103],{"type":80,"value":104},"server routes",{"type":80,"value":106},", there is no vue composable equivalent.",{"type":69,"tag":76,"props":108,"children":109},{},[110,112,116,118,125],{"type":80,"value":111},"It works similary as the ",{"type":69,"tag":83,"props":113,"children":114},{"href":35},[115],{"type":80,"value":34},{"type":80,"value":117}," but it provides a client with super admin rights that can bypass your ",{"type":69,"tag":83,"props":119,"children":122},{"href":120,"rel":121},"https://supabase.com/docs/guides/auth/row-level-security",[87],[123],{"type":80,"value":124},"Row Level Security",{"type":80,"value":126},".",{"type":69,"tag":128,"props":129,"children":130},"blockquote",{},[131],{"type":69,"tag":76,"props":132,"children":133},{},[134,136,143,145,151,153,160],{"type":80,"value":135},"The client is initialized with the ",{"type":69,"tag":137,"props":138,"children":140},"code",{"className":139},[],[141],{"type":80,"value":142},"SUPABASE_SERVICE_KEY",{"type":80,"value":144}," you must have in your ",{"type":69,"tag":137,"props":146,"children":148},{"className":147},[],[149],{"type":80,"value":150},".env",{"type":80,"value":152}," file. Checkout the doc if you want to know more about ",{"type":69,"tag":83,"props":154,"children":157},{"href":155,"rel":156},"https://supabase.com/docs/learn/auth-deep-dive/auth-deep-dive-jwts#jwts-in-supabase",[87],[158],{"type":80,"value":159},"Supabase keys",{"type":80,"value":126},{"type":69,"tag":76,"props":162,"children":163},{},[164,166,171,173,179],{"type":80,"value":165},"Define your server route and just import the ",{"type":69,"tag":137,"props":167,"children":169},{"className":168},[],[170],{"type":80,"value":37},{"type":80,"value":172}," from ",{"type":69,"tag":137,"props":174,"children":176},{"className":175},[],[177],{"type":80,"value":178},"#supabase/server",{"type":80,"value":126},{"type":69,"tag":181,"props":182,"children":187},"pre",{"className":183,"code":184,"filename":185,"language":186,"meta":61,"style":61},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","import { serverSupabaseServiceRole } from '#supabase/server'\n\nexport default eventHandler(async (event) => {\n const client = serverSupabaseServiceRole(event)\n\n const { data } = await client.from('rls-protected-table').select()\n\n return { sensitiveData: data }\n})\n","server/api/bypass-rls.ts","ts",[188],{"type":69,"tag":137,"props":189,"children":190},{"__ignoreMap":61},[191,240,250,307,344,352,431,439,471],{"type":69,"tag":192,"props":193,"children":196},"span",{"class":194,"line":195},"line",1,[197,203,209,215,220,225,230,235],{"type":69,"tag":192,"props":198,"children":200},{"style":199},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[201],{"type":80,"value":202},"import",{"type":69,"tag":192,"props":204,"children":206},{"style":205},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[207],{"type":80,"value":208}," {",{"type":69,"tag":192,"props":210,"children":212},{"style":211},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[213],{"type":80,"value":214}," serverSupabaseServiceRole",{"type":69,"tag":192,"props":216,"children":217},{"style":205},[218],{"type":80,"value":219}," }",{"type":69,"tag":192,"props":221,"children":222},{"style":199},[223],{"type":80,"value":224}," from",{"type":69,"tag":192,"props":226,"children":227},{"style":205},[228],{"type":80,"value":229}," '",{"type":69,"tag":192,"props":231,"children":233},{"style":232},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[234],{"type":80,"value":178},{"type":69,"tag":192,"props":236,"children":237},{"style":205},[238],{"type":80,"value":239},"'\n",{"type":69,"tag":192,"props":241,"children":243},{"class":194,"line":242},2,[244],{"type":69,"tag":192,"props":245,"children":247},{"emptyLinePlaceholder":246},true,[248],{"type":80,"value":249},"\n",{"type":69,"tag":192,"props":251,"children":253},{"class":194,"line":252},3,[254,259,264,270,275,281,286,292,297,302],{"type":69,"tag":192,"props":255,"children":256},{"style":199},[257],{"type":80,"value":258},"export",{"type":69,"tag":192,"props":260,"children":261},{"style":199},[262],{"type":80,"value":263}," default",{"type":69,"tag":192,"props":265,"children":267},{"style":266},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[268],{"type":80,"value":269}," eventHandler",{"type":69,"tag":192,"props":271,"children":272},{"style":211},[273],{"type":80,"value":274},"(",{"type":69,"tag":192,"props":276,"children":278},{"style":277},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[279],{"type":80,"value":280},"async",{"type":69,"tag":192,"props":282,"children":283},{"style":205},[284],{"type":80,"value":285}," (",{"type":69,"tag":192,"props":287,"children":289},{"style":288},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[290],{"type":80,"value":291},"event",{"type":69,"tag":192,"props":293,"children":294},{"style":205},[295],{"type":80,"value":296},")",{"type":69,"tag":192,"props":298,"children":299},{"style":277},[300],{"type":80,"value":301}," =>",{"type":69,"tag":192,"props":303,"children":304},{"style":205},[305],{"type":80,"value":306}," {\n",{"type":69,"tag":192,"props":308,"children":310},{"class":194,"line":309},4,[311,316,321,326,330,335,339],{"type":69,"tag":192,"props":312,"children":313},{"style":277},[314],{"type":80,"value":315}," const",{"type":69,"tag":192,"props":317,"children":318},{"style":211},[319],{"type":80,"value":320}," client",{"type":69,"tag":192,"props":322,"children":323},{"style":205},[324],{"type":80,"value":325}," =",{"type":69,"tag":192,"props":327,"children":328},{"style":266},[329],{"type":80,"value":214},{"type":69,"tag":192,"props":331,"children":333},{"style":332},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[334],{"type":80,"value":274},{"type":69,"tag":192,"props":336,"children":337},{"style":211},[338],{"type":80,"value":291},{"type":69,"tag":192,"props":340,"children":341},{"style":332},[342],{"type":80,"value":343},")\n",{"type":69,"tag":192,"props":345,"children":347},{"class":194,"line":346},5,[348],{"type":69,"tag":192,"props":349,"children":350},{"emptyLinePlaceholder":246},[351],{"type":80,"value":249},{"type":69,"tag":192,"props":353,"children":355},{"class":194,"line":354},6,[356,360,364,369,373,377,382,386,390,395,399,404,409,413,417,421,426],{"type":69,"tag":192,"props":357,"children":358},{"style":277},[359],{"type":80,"value":315},{"type":69,"tag":192,"props":361,"children":362},{"style":205},[363],{"type":80,"value":208},{"type":69,"tag":192,"props":365,"children":366},{"style":211},[367],{"type":80,"value":368}," data",{"type":69,"tag":192,"props":370,"children":371},{"style":205},[372],{"type":80,"value":219},{"type":69,"tag":192,"props":374,"children":375},{"style":205},[376],{"type":80,"value":325},{"type":69,"tag":192,"props":378,"children":379},{"style":199},[380],{"type":80,"value":381}," await",{"type":69,"tag":192,"props":383,"children":384},{"style":211},[385],{"type":80,"value":320},{"type":69,"tag":192,"props":387,"children":388},{"style":205},[389],{"type":80,"value":126},{"type":69,"tag":192,"props":391,"children":392},{"style":266},[393],{"type":80,"value":394},"from",{"type":69,"tag":192,"props":396,"children":397},{"style":332},[398],{"type":80,"value":274},{"type":69,"tag":192,"props":400,"children":401},{"style":205},[402],{"type":80,"value":403},"'",{"type":69,"tag":192,"props":405,"children":406},{"style":232},[407],{"type":80,"value":408},"rls-protected-table",{"type":69,"tag":192,"props":410,"children":411},{"style":205},[412],{"type":80,"value":403},{"type":69,"tag":192,"props":414,"children":415},{"style":332},[416],{"type":80,"value":296},{"type":69,"tag":192,"props":418,"children":419},{"style":205},[420],{"type":80,"value":126},{"type":69,"tag":192,"props":422,"children":423},{"style":266},[424],{"type":80,"value":425},"select",{"type":69,"tag":192,"props":427,"children":428},{"style":332},[429],{"type":80,"value":430},"()\n",{"type":69,"tag":192,"props":432,"children":434},{"class":194,"line":433},7,[435],{"type":69,"tag":192,"props":436,"children":437},{"emptyLinePlaceholder":246},[438],{"type":80,"value":249},{"type":69,"tag":192,"props":440,"children":442},{"class":194,"line":441},8,[443,448,452,457,462,466],{"type":69,"tag":192,"props":444,"children":445},{"style":199},[446],{"type":80,"value":447}," return",{"type":69,"tag":192,"props":449,"children":450},{"style":205},[451],{"type":80,"value":208},{"type":69,"tag":192,"props":453,"children":454},{"style":332},[455],{"type":80,"value":456}," sensitiveData",{"type":69,"tag":192,"props":458,"children":459},{"style":205},[460],{"type":80,"value":461},":",{"type":69,"tag":192,"props":463,"children":464},{"style":211},[465],{"type":80,"value":368},{"type":69,"tag":192,"props":467,"children":468},{"style":205},[469],{"type":80,"value":470}," }\n",{"type":69,"tag":192,"props":472,"children":474},{"class":194,"line":473},9,[475,480],{"type":69,"tag":192,"props":476,"children":477},{"style":205},[478],{"type":80,"value":479},"}",{"type":69,"tag":192,"props":481,"children":482},{"style":211},[483],{"type":80,"value":343},{"type":69,"tag":76,"props":485,"children":486},{},[487],{"type":80,"value":488},"Then call your API route from any vue file:",{"type":69,"tag":181,"props":490,"children":493},{"className":183,"code":491,"filename":492,"language":186,"meta":61,"style":61},"const fetchSensitiveData = async () => {\n const { sensitiveData } = await useFetch('/api/bypass-rls')\n}\n","pages/index.vue",[494],{"type":69,"tag":137,"props":495,"children":496},{"__ignoreMap":61},[497,533,586],{"type":69,"tag":192,"props":498,"children":499},{"class":194,"line":195},[500,505,510,515,520,525,529],{"type":69,"tag":192,"props":501,"children":502},{"style":277},[503],{"type":80,"value":504},"const",{"type":69,"tag":192,"props":506,"children":507},{"style":211},[508],{"type":80,"value":509}," fetchSensitiveData ",{"type":69,"tag":192,"props":511,"children":512},{"style":205},[513],{"type":80,"value":514},"=",{"type":69,"tag":192,"props":516,"children":517},{"style":277},[518],{"type":80,"value":519}," async",{"type":69,"tag":192,"props":521,"children":522},{"style":205},[523],{"type":80,"value":524}," ()",{"type":69,"tag":192,"props":526,"children":527},{"style":277},[528],{"type":80,"value":301},{"type":69,"tag":192,"props":530,"children":531},{"style":205},[532],{"type":80,"value":306},{"type":69,"tag":192,"props":534,"children":535},{"class":194,"line":242},[536,540,544,548,552,556,560,565,569,573,578,582],{"type":69,"tag":192,"props":537,"children":538},{"style":277},[539],{"type":80,"value":315},{"type":69,"tag":192,"props":541,"children":542},{"style":205},[543],{"type":80,"value":208},{"type":69,"tag":192,"props":545,"children":546},{"style":211},[547],{"type":80,"value":456},{"type":69,"tag":192,"props":549,"children":550},{"style":205},[551],{"type":80,"value":219},{"type":69,"tag":192,"props":553,"children":554},{"style":205},[555],{"type":80,"value":325},{"type":69,"tag":192,"props":557,"children":558},{"style":199},[559],{"type":80,"value":381},{"type":69,"tag":192,"props":561,"children":562},{"style":266},[563],{"type":80,"value":564}," useFetch",{"type":69,"tag":192,"props":566,"children":567},{"style":332},[568],{"type":80,"value":274},{"type":69,"tag":192,"props":570,"children":571},{"style":205},[572],{"type":80,"value":403},{"type":69,"tag":192,"props":574,"children":575},{"style":232},[576],{"type":80,"value":577},"/api/bypass-rls",{"type":69,"tag":192,"props":579,"children":580},{"style":205},[581],{"type":80,"value":403},{"type":69,"tag":192,"props":583,"children":584},{"style":332},[585],{"type":80,"value":343},{"type":69,"tag":192,"props":587,"children":588},{"class":194,"line":252},[589],{"type":69,"tag":192,"props":590,"children":591},{"style":205},[592],{"type":80,"value":593},"}\n",{"type":69,"tag":595,"props":596,"children":597},"style",{},[598],{"type":80,"value":599},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":61,"searchDepth":242,"depth":242,"links":601},[],"markdown","content:4.usage:services:2.serverSupabaseServiceRole.md","content","4.usage/services/2.serverSupabaseServiceRole.md","4.usage/services/2.serverSupabaseServiceRole","md",[609,611],{"_path":35,"title":34,"description":610},"Make requests to the Supabase API on server side with the serverSupabaseClient service",{"_path":41,"title":40,"description":612},"Get your Supabase user's session from serverside with the serverSupabaseUser service",1724940863129] \ No newline at end of file +[{"data":1,"prerenderedAt":613},["ShallowReactive",2],{"navigation":3,"/usage/services/serversupabaseservicerole":58,"/usage/services/serversupabaseservicerole-surround":608},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":38,"_dir":59,"_draft":60,"_partial":60,"_locale":61,"title":62,"description":63,"navigation":64,"body":65,"_type":602,"_id":603,"_source":604,"_file":605,"_stem":606,"_extension":607},"services",false,"","serverServiceRole","Make requests with super admin rights to the Supabase API with the serverSupabaseServiceRole service",{"title":37},{"type":66,"children":67,"toc":600},"root",[68,93,107,127,161,180,484,489,594],{"type":69,"tag":70,"props":71,"children":74},"element","callout",{"color":72,"icon":73},"amber","i-heroicons-exclamation-triangle-20-solid",[75],{"type":69,"tag":76,"props":77,"children":78},"p",{},[79,82,91],{"type":80,"value":81},"text","This section assumes you're familiar with ",{"type":69,"tag":83,"props":84,"children":88},"a",{"href":85,"rel":86},"https://v3.nuxtjs.org/guide/concepts/server-engine",[87],"nofollow",[89],{"type":80,"value":90},"Nitro",{"type":80,"value":92},", the server engine powered by Nuxt.",{"type":69,"tag":76,"props":94,"children":95},{},[96,98,105],{"type":80,"value":97},"This function is designed to work only in ",{"type":69,"tag":83,"props":99,"children":102},{"href":100,"rel":101},"https://nuxt.com/docs/guide/directory-structure/server#server-routes",[87],[103],{"type":80,"value":104},"server routes",{"type":80,"value":106},", there is no vue composable equivalent.",{"type":69,"tag":76,"props":108,"children":109},{},[110,112,116,118,125],{"type":80,"value":111},"It works similary as the ",{"type":69,"tag":83,"props":113,"children":114},{"href":35},[115],{"type":80,"value":34},{"type":80,"value":117}," but it provides a client with super admin rights that can bypass your ",{"type":69,"tag":83,"props":119,"children":122},{"href":120,"rel":121},"https://supabase.com/docs/guides/auth/row-level-security",[87],[123],{"type":80,"value":124},"Row Level Security",{"type":80,"value":126},".",{"type":69,"tag":128,"props":129,"children":130},"blockquote",{},[131],{"type":69,"tag":76,"props":132,"children":133},{},[134,136,143,145,151,153,160],{"type":80,"value":135},"The client is initialized with the ",{"type":69,"tag":137,"props":138,"children":140},"code",{"className":139},[],[141],{"type":80,"value":142},"SUPABASE_SERVICE_KEY",{"type":80,"value":144}," you must have in your ",{"type":69,"tag":137,"props":146,"children":148},{"className":147},[],[149],{"type":80,"value":150},".env",{"type":80,"value":152}," file. Checkout the doc if you want to know more about ",{"type":69,"tag":83,"props":154,"children":157},{"href":155,"rel":156},"https://supabase.com/docs/learn/auth-deep-dive/auth-deep-dive-jwts#jwts-in-supabase",[87],[158],{"type":80,"value":159},"Supabase keys",{"type":80,"value":126},{"type":69,"tag":76,"props":162,"children":163},{},[164,166,171,173,179],{"type":80,"value":165},"Define your server route and just import the ",{"type":69,"tag":137,"props":167,"children":169},{"className":168},[],[170],{"type":80,"value":37},{"type":80,"value":172}," from ",{"type":69,"tag":137,"props":174,"children":176},{"className":175},[],[177],{"type":80,"value":178},"#supabase/server",{"type":80,"value":126},{"type":69,"tag":181,"props":182,"children":187},"pre",{"className":183,"code":184,"filename":185,"language":186,"meta":61,"style":61},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","import { serverSupabaseServiceRole } from '#supabase/server'\n\nexport default eventHandler(async (event) => {\n const client = serverSupabaseServiceRole(event)\n\n const { data } = await client.from('rls-protected-table').select()\n\n return { sensitiveData: data }\n})\n","server/api/bypass-rls.ts","ts",[188],{"type":69,"tag":137,"props":189,"children":190},{"__ignoreMap":61},[191,240,250,307,344,352,431,439,471],{"type":69,"tag":192,"props":193,"children":196},"span",{"class":194,"line":195},"line",1,[197,203,209,215,220,225,230,235],{"type":69,"tag":192,"props":198,"children":200},{"style":199},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[201],{"type":80,"value":202},"import",{"type":69,"tag":192,"props":204,"children":206},{"style":205},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[207],{"type":80,"value":208}," {",{"type":69,"tag":192,"props":210,"children":212},{"style":211},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[213],{"type":80,"value":214}," serverSupabaseServiceRole",{"type":69,"tag":192,"props":216,"children":217},{"style":205},[218],{"type":80,"value":219}," }",{"type":69,"tag":192,"props":221,"children":222},{"style":199},[223],{"type":80,"value":224}," from",{"type":69,"tag":192,"props":226,"children":227},{"style":205},[228],{"type":80,"value":229}," '",{"type":69,"tag":192,"props":231,"children":233},{"style":232},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[234],{"type":80,"value":178},{"type":69,"tag":192,"props":236,"children":237},{"style":205},[238],{"type":80,"value":239},"'\n",{"type":69,"tag":192,"props":241,"children":243},{"class":194,"line":242},2,[244],{"type":69,"tag":192,"props":245,"children":247},{"emptyLinePlaceholder":246},true,[248],{"type":80,"value":249},"\n",{"type":69,"tag":192,"props":251,"children":253},{"class":194,"line":252},3,[254,259,264,270,275,281,286,292,297,302],{"type":69,"tag":192,"props":255,"children":256},{"style":199},[257],{"type":80,"value":258},"export",{"type":69,"tag":192,"props":260,"children":261},{"style":199},[262],{"type":80,"value":263}," default",{"type":69,"tag":192,"props":265,"children":267},{"style":266},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[268],{"type":80,"value":269}," eventHandler",{"type":69,"tag":192,"props":271,"children":272},{"style":211},[273],{"type":80,"value":274},"(",{"type":69,"tag":192,"props":276,"children":278},{"style":277},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[279],{"type":80,"value":280},"async",{"type":69,"tag":192,"props":282,"children":283},{"style":205},[284],{"type":80,"value":285}," (",{"type":69,"tag":192,"props":287,"children":289},{"style":288},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[290],{"type":80,"value":291},"event",{"type":69,"tag":192,"props":293,"children":294},{"style":205},[295],{"type":80,"value":296},")",{"type":69,"tag":192,"props":298,"children":299},{"style":277},[300],{"type":80,"value":301}," =>",{"type":69,"tag":192,"props":303,"children":304},{"style":205},[305],{"type":80,"value":306}," {\n",{"type":69,"tag":192,"props":308,"children":310},{"class":194,"line":309},4,[311,316,321,326,330,335,339],{"type":69,"tag":192,"props":312,"children":313},{"style":277},[314],{"type":80,"value":315}," const",{"type":69,"tag":192,"props":317,"children":318},{"style":211},[319],{"type":80,"value":320}," client",{"type":69,"tag":192,"props":322,"children":323},{"style":205},[324],{"type":80,"value":325}," =",{"type":69,"tag":192,"props":327,"children":328},{"style":266},[329],{"type":80,"value":214},{"type":69,"tag":192,"props":331,"children":333},{"style":332},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[334],{"type":80,"value":274},{"type":69,"tag":192,"props":336,"children":337},{"style":211},[338],{"type":80,"value":291},{"type":69,"tag":192,"props":340,"children":341},{"style":332},[342],{"type":80,"value":343},")\n",{"type":69,"tag":192,"props":345,"children":347},{"class":194,"line":346},5,[348],{"type":69,"tag":192,"props":349,"children":350},{"emptyLinePlaceholder":246},[351],{"type":80,"value":249},{"type":69,"tag":192,"props":353,"children":355},{"class":194,"line":354},6,[356,360,364,369,373,377,382,386,390,395,399,404,409,413,417,421,426],{"type":69,"tag":192,"props":357,"children":358},{"style":277},[359],{"type":80,"value":315},{"type":69,"tag":192,"props":361,"children":362},{"style":205},[363],{"type":80,"value":208},{"type":69,"tag":192,"props":365,"children":366},{"style":211},[367],{"type":80,"value":368}," data",{"type":69,"tag":192,"props":370,"children":371},{"style":205},[372],{"type":80,"value":219},{"type":69,"tag":192,"props":374,"children":375},{"style":205},[376],{"type":80,"value":325},{"type":69,"tag":192,"props":378,"children":379},{"style":199},[380],{"type":80,"value":381}," await",{"type":69,"tag":192,"props":383,"children":384},{"style":211},[385],{"type":80,"value":320},{"type":69,"tag":192,"props":387,"children":388},{"style":205},[389],{"type":80,"value":126},{"type":69,"tag":192,"props":391,"children":392},{"style":266},[393],{"type":80,"value":394},"from",{"type":69,"tag":192,"props":396,"children":397},{"style":332},[398],{"type":80,"value":274},{"type":69,"tag":192,"props":400,"children":401},{"style":205},[402],{"type":80,"value":403},"'",{"type":69,"tag":192,"props":405,"children":406},{"style":232},[407],{"type":80,"value":408},"rls-protected-table",{"type":69,"tag":192,"props":410,"children":411},{"style":205},[412],{"type":80,"value":403},{"type":69,"tag":192,"props":414,"children":415},{"style":332},[416],{"type":80,"value":296},{"type":69,"tag":192,"props":418,"children":419},{"style":205},[420],{"type":80,"value":126},{"type":69,"tag":192,"props":422,"children":423},{"style":266},[424],{"type":80,"value":425},"select",{"type":69,"tag":192,"props":427,"children":428},{"style":332},[429],{"type":80,"value":430},"()\n",{"type":69,"tag":192,"props":432,"children":434},{"class":194,"line":433},7,[435],{"type":69,"tag":192,"props":436,"children":437},{"emptyLinePlaceholder":246},[438],{"type":80,"value":249},{"type":69,"tag":192,"props":440,"children":442},{"class":194,"line":441},8,[443,448,452,457,462,466],{"type":69,"tag":192,"props":444,"children":445},{"style":199},[446],{"type":80,"value":447}," return",{"type":69,"tag":192,"props":449,"children":450},{"style":205},[451],{"type":80,"value":208},{"type":69,"tag":192,"props":453,"children":454},{"style":332},[455],{"type":80,"value":456}," sensitiveData",{"type":69,"tag":192,"props":458,"children":459},{"style":205},[460],{"type":80,"value":461},":",{"type":69,"tag":192,"props":463,"children":464},{"style":211},[465],{"type":80,"value":368},{"type":69,"tag":192,"props":467,"children":468},{"style":205},[469],{"type":80,"value":470}," }\n",{"type":69,"tag":192,"props":472,"children":474},{"class":194,"line":473},9,[475,480],{"type":69,"tag":192,"props":476,"children":477},{"style":205},[478],{"type":80,"value":479},"}",{"type":69,"tag":192,"props":481,"children":482},{"style":211},[483],{"type":80,"value":343},{"type":69,"tag":76,"props":485,"children":486},{},[487],{"type":80,"value":488},"Then call your API route from any vue file:",{"type":69,"tag":181,"props":490,"children":493},{"className":183,"code":491,"filename":492,"language":186,"meta":61,"style":61},"const fetchSensitiveData = async () => {\n const { sensitiveData } = await useFetch('/api/bypass-rls')\n}\n","pages/index.vue",[494],{"type":69,"tag":137,"props":495,"children":496},{"__ignoreMap":61},[497,533,586],{"type":69,"tag":192,"props":498,"children":499},{"class":194,"line":195},[500,505,510,515,520,525,529],{"type":69,"tag":192,"props":501,"children":502},{"style":277},[503],{"type":80,"value":504},"const",{"type":69,"tag":192,"props":506,"children":507},{"style":211},[508],{"type":80,"value":509}," fetchSensitiveData ",{"type":69,"tag":192,"props":511,"children":512},{"style":205},[513],{"type":80,"value":514},"=",{"type":69,"tag":192,"props":516,"children":517},{"style":277},[518],{"type":80,"value":519}," async",{"type":69,"tag":192,"props":521,"children":522},{"style":205},[523],{"type":80,"value":524}," ()",{"type":69,"tag":192,"props":526,"children":527},{"style":277},[528],{"type":80,"value":301},{"type":69,"tag":192,"props":530,"children":531},{"style":205},[532],{"type":80,"value":306},{"type":69,"tag":192,"props":534,"children":535},{"class":194,"line":242},[536,540,544,548,552,556,560,565,569,573,578,582],{"type":69,"tag":192,"props":537,"children":538},{"style":277},[539],{"type":80,"value":315},{"type":69,"tag":192,"props":541,"children":542},{"style":205},[543],{"type":80,"value":208},{"type":69,"tag":192,"props":545,"children":546},{"style":211},[547],{"type":80,"value":456},{"type":69,"tag":192,"props":549,"children":550},{"style":205},[551],{"type":80,"value":219},{"type":69,"tag":192,"props":553,"children":554},{"style":205},[555],{"type":80,"value":325},{"type":69,"tag":192,"props":557,"children":558},{"style":199},[559],{"type":80,"value":381},{"type":69,"tag":192,"props":561,"children":562},{"style":266},[563],{"type":80,"value":564}," useFetch",{"type":69,"tag":192,"props":566,"children":567},{"style":332},[568],{"type":80,"value":274},{"type":69,"tag":192,"props":570,"children":571},{"style":205},[572],{"type":80,"value":403},{"type":69,"tag":192,"props":574,"children":575},{"style":232},[576],{"type":80,"value":577},"/api/bypass-rls",{"type":69,"tag":192,"props":579,"children":580},{"style":205},[581],{"type":80,"value":403},{"type":69,"tag":192,"props":583,"children":584},{"style":332},[585],{"type":80,"value":343},{"type":69,"tag":192,"props":587,"children":588},{"class":194,"line":252},[589],{"type":69,"tag":192,"props":590,"children":591},{"style":205},[592],{"type":80,"value":593},"}\n",{"type":69,"tag":595,"props":596,"children":597},"style",{},[598],{"type":80,"value":599},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":61,"searchDepth":242,"depth":242,"links":601},[],"markdown","content:4.usage:services:2.serverSupabaseServiceRole.md","content","4.usage/services/2.serverSupabaseServiceRole.md","4.usage/services/2.serverSupabaseServiceRole","md",[609,611],{"_path":35,"title":34,"description":610},"Make requests to the Supabase API on server side with the serverSupabaseClient service",{"_path":41,"title":40,"description":612},"Get your Supabase user's session from serverside with the serverSupabaseUser service",1724942526930] \ No newline at end of file diff --git a/usage/services/serversupabaseservicerole/index.html b/usage/services/serversupabaseservicerole/index.html index 32d15fee..76035e06 100644 --- a/usage/services/serversupabaseservicerole/index.html +++ b/usage/services/serversupabaseservicerole/index.html @@ -61,7 +61,7 @@ - + @@ -117,5 +117,5 @@ const { sensitiveData } = await useFetch('/api/bypass-rls') }
Made with Nuxt Studio
- - \ No newline at end of file + + \ No newline at end of file diff --git a/usage/services/serversupabasesession/_payload.json b/usage/services/serversupabasesession/_payload.json index 97a6d7a4..8c76e5a4 100644 --- a/usage/services/serversupabasesession/_payload.json +++ b/usage/services/serversupabasesession/_payload.json @@ -1 +1 @@ -[{"data":1,"prerenderedAt":678},["ShallowReactive",2],{"navigation":3,"/usage/services/serversupabasesession":58,"/usage/services/serversupabasesession-surround":672},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":41,"_dir":59,"_draft":60,"_partial":60,"_locale":61,"title":40,"description":62,"body":63,"_type":666,"_id":667,"_source":668,"_file":669,"_stem":670,"_extension":671},"services",false,"","Get your Supabase user's session from serverside with the serverSupabaseUser service",{"type":64,"children":65,"toc":664},"root",[66,91,111,131,303,308,454,468,658],{"type":67,"tag":68,"props":69,"children":72},"element","callout",{"color":70,"icon":71},"amber","i-heroicons-exclamation-triangle-20-solid",[73],{"type":67,"tag":74,"props":75,"children":76},"p",{},[77,80,89],{"type":78,"value":79},"text","This section assumes you're familiar with ",{"type":67,"tag":81,"props":82,"children":86},"a",{"href":83,"rel":84},"https://v3.nuxtjs.org/guide/concepts/server-engine",[85],"nofollow",[87],{"type":78,"value":88},"Nitro",{"type":78,"value":90},", the server engine powered by Nuxt.",{"type":67,"tag":74,"props":92,"children":93},{},[94,96,100,102,109],{"type":78,"value":95},"This function is similar to the ",{"type":67,"tag":81,"props":97,"children":98},{"href":25},[99],{"type":78,"value":24},{"type":78,"value":101}," composable but is used in ",{"type":67,"tag":81,"props":103,"children":106},{"href":104,"rel":105},"https://nuxt.com/docs/guide/directory-structure/server#server-routes",[85],[107],{"type":78,"value":108},"server routes",{"type":78,"value":110},".",{"type":67,"tag":74,"props":112,"children":113},{},[114,116,122,124,130],{"type":78,"value":115},"Define your server route and import the ",{"type":67,"tag":117,"props":118,"children":120},"code",{"className":119},[],[121],{"type":78,"value":40},{"type":78,"value":123}," from ",{"type":67,"tag":117,"props":125,"children":127},{"className":126},[],[128],{"type":78,"value":129},"#supabase/server",{"type":78,"value":110},{"type":67,"tag":132,"props":133,"children":138},"pre",{"className":134,"code":135,"filename":136,"language":137,"meta":61,"style":61},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","import { serverSupabaseSession } from '#supabase/server'\n\nexport default defineEventHandler(async (event) => {\n return await serverSupabaseSession(event)\n})\n","server/api/session.ts","ts",[139],{"type":67,"tag":117,"props":140,"children":141},{"__ignoreMap":61},[142,191,201,258,290],{"type":67,"tag":143,"props":144,"children":147},"span",{"class":145,"line":146},"line",1,[148,154,160,166,171,176,181,186],{"type":67,"tag":143,"props":149,"children":151},{"style":150},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[152],{"type":78,"value":153},"import",{"type":67,"tag":143,"props":155,"children":157},{"style":156},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[158],{"type":78,"value":159}," {",{"type":67,"tag":143,"props":161,"children":163},{"style":162},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[164],{"type":78,"value":165}," serverSupabaseSession",{"type":67,"tag":143,"props":167,"children":168},{"style":156},[169],{"type":78,"value":170}," }",{"type":67,"tag":143,"props":172,"children":173},{"style":150},[174],{"type":78,"value":175}," from",{"type":67,"tag":143,"props":177,"children":178},{"style":156},[179],{"type":78,"value":180}," '",{"type":67,"tag":143,"props":182,"children":184},{"style":183},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[185],{"type":78,"value":129},{"type":67,"tag":143,"props":187,"children":188},{"style":156},[189],{"type":78,"value":190},"'\n",{"type":67,"tag":143,"props":192,"children":194},{"class":145,"line":193},2,[195],{"type":67,"tag":143,"props":196,"children":198},{"emptyLinePlaceholder":197},true,[199],{"type":78,"value":200},"\n",{"type":67,"tag":143,"props":202,"children":204},{"class":145,"line":203},3,[205,210,215,221,226,232,237,243,248,253],{"type":67,"tag":143,"props":206,"children":207},{"style":150},[208],{"type":78,"value":209},"export",{"type":67,"tag":143,"props":211,"children":212},{"style":150},[213],{"type":78,"value":214}," default",{"type":67,"tag":143,"props":216,"children":218},{"style":217},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[219],{"type":78,"value":220}," defineEventHandler",{"type":67,"tag":143,"props":222,"children":223},{"style":162},[224],{"type":78,"value":225},"(",{"type":67,"tag":143,"props":227,"children":229},{"style":228},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[230],{"type":78,"value":231},"async",{"type":67,"tag":143,"props":233,"children":234},{"style":156},[235],{"type":78,"value":236}," (",{"type":67,"tag":143,"props":238,"children":240},{"style":239},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[241],{"type":78,"value":242},"event",{"type":67,"tag":143,"props":244,"children":245},{"style":156},[246],{"type":78,"value":247},")",{"type":67,"tag":143,"props":249,"children":250},{"style":228},[251],{"type":78,"value":252}," =>",{"type":67,"tag":143,"props":254,"children":255},{"style":156},[256],{"type":78,"value":257}," {\n",{"type":67,"tag":143,"props":259,"children":261},{"class":145,"line":260},4,[262,267,272,276,281,285],{"type":67,"tag":143,"props":263,"children":264},{"style":150},[265],{"type":78,"value":266}," return",{"type":67,"tag":143,"props":268,"children":269},{"style":150},[270],{"type":78,"value":271}," await",{"type":67,"tag":143,"props":273,"children":274},{"style":217},[275],{"type":78,"value":165},{"type":67,"tag":143,"props":277,"children":279},{"style":278},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[280],{"type":78,"value":225},{"type":67,"tag":143,"props":282,"children":283},{"style":162},[284],{"type":78,"value":242},{"type":67,"tag":143,"props":286,"children":287},{"style":278},[288],{"type":78,"value":289},")\n",{"type":67,"tag":143,"props":291,"children":293},{"class":145,"line":292},5,[294,299],{"type":67,"tag":143,"props":295,"children":296},{"style":156},[297],{"type":78,"value":298},"}",{"type":67,"tag":143,"props":300,"children":301},{"style":162},[302],{"type":78,"value":289},{"type":67,"tag":74,"props":304,"children":305},{},[306],{"type":78,"value":307},"Then call your api route from any vue file:",{"type":67,"tag":132,"props":309,"children":312},{"className":134,"code":310,"filename":311,"language":137,"meta":61,"style":61},"const session = ref(null)\n\nconst fetchSession = async () => {\n session.value = await $fetch('/api/session')\n}\n","pages/index.vue",[313],{"type":67,"tag":117,"props":314,"children":315},{"__ignoreMap":61},[316,352,359,393,446],{"type":67,"tag":143,"props":317,"children":318},{"class":145,"line":146},[319,324,329,334,339,343,348],{"type":67,"tag":143,"props":320,"children":321},{"style":228},[322],{"type":78,"value":323},"const",{"type":67,"tag":143,"props":325,"children":326},{"style":162},[327],{"type":78,"value":328}," session ",{"type":67,"tag":143,"props":330,"children":331},{"style":156},[332],{"type":78,"value":333},"=",{"type":67,"tag":143,"props":335,"children":336},{"style":217},[337],{"type":78,"value":338}," ref",{"type":67,"tag":143,"props":340,"children":341},{"style":162},[342],{"type":78,"value":225},{"type":67,"tag":143,"props":344,"children":345},{"style":156},[346],{"type":78,"value":347},"null",{"type":67,"tag":143,"props":349,"children":350},{"style":162},[351],{"type":78,"value":289},{"type":67,"tag":143,"props":353,"children":354},{"class":145,"line":193},[355],{"type":67,"tag":143,"props":356,"children":357},{"emptyLinePlaceholder":197},[358],{"type":78,"value":200},{"type":67,"tag":143,"props":360,"children":361},{"class":145,"line":203},[362,366,371,375,380,385,389],{"type":67,"tag":143,"props":363,"children":364},{"style":228},[365],{"type":78,"value":323},{"type":67,"tag":143,"props":367,"children":368},{"style":162},[369],{"type":78,"value":370}," fetchSession ",{"type":67,"tag":143,"props":372,"children":373},{"style":156},[374],{"type":78,"value":333},{"type":67,"tag":143,"props":376,"children":377},{"style":228},[378],{"type":78,"value":379}," async",{"type":67,"tag":143,"props":381,"children":382},{"style":156},[383],{"type":78,"value":384}," ()",{"type":67,"tag":143,"props":386,"children":387},{"style":228},[388],{"type":78,"value":252},{"type":67,"tag":143,"props":390,"children":391},{"style":156},[392],{"type":78,"value":257},{"type":67,"tag":143,"props":394,"children":395},{"class":145,"line":260},[396,401,405,410,415,419,424,428,433,438,442],{"type":67,"tag":143,"props":397,"children":398},{"style":162},[399],{"type":78,"value":400}," session",{"type":67,"tag":143,"props":402,"children":403},{"style":156},[404],{"type":78,"value":110},{"type":67,"tag":143,"props":406,"children":407},{"style":162},[408],{"type":78,"value":409},"value",{"type":67,"tag":143,"props":411,"children":412},{"style":156},[413],{"type":78,"value":414}," =",{"type":67,"tag":143,"props":416,"children":417},{"style":150},[418],{"type":78,"value":271},{"type":67,"tag":143,"props":420,"children":421},{"style":217},[422],{"type":78,"value":423}," $fetch",{"type":67,"tag":143,"props":425,"children":426},{"style":278},[427],{"type":78,"value":225},{"type":67,"tag":143,"props":429,"children":430},{"style":156},[431],{"type":78,"value":432},"'",{"type":67,"tag":143,"props":434,"children":435},{"style":183},[436],{"type":78,"value":437},"/api/session",{"type":67,"tag":143,"props":439,"children":440},{"style":156},[441],{"type":78,"value":432},{"type":67,"tag":143,"props":443,"children":444},{"style":278},[445],{"type":78,"value":289},{"type":67,"tag":143,"props":447,"children":448},{"class":145,"line":292},[449],{"type":67,"tag":143,"props":450,"children":451},{"style":156},[452],{"type":78,"value":453},"}\n",{"type":67,"tag":74,"props":455,"children":456},{},[457,459,466],{"type":78,"value":458},"Be careful, if you want to call this route on SSR, please read this ",{"type":67,"tag":81,"props":460,"children":463},{"href":461,"rel":462},"https://nuxt.com/docs/getting-started/data-fetching#isomorphic-fetch-and-fetch",[85],[464],{"type":78,"value":465},"section",{"type":78,"value":467},", you must send your browser cookies including your supabase token.",{"type":67,"tag":132,"props":469,"children":471},{"className":134,"code":470,"filename":311,"language":137,"meta":61,"style":61},"const session = ref(null)\n\nconst { data } = await useFetch('/api/session', {\n headers: useRequestHeaders(['cookie'])\n})\n\nsession.value = data\n",[472],{"type":67,"tag":117,"props":473,"children":474},{"__ignoreMap":61},[475,506,513,571,612,623,631],{"type":67,"tag":143,"props":476,"children":477},{"class":145,"line":146},[478,482,486,490,494,498,502],{"type":67,"tag":143,"props":479,"children":480},{"style":228},[481],{"type":78,"value":323},{"type":67,"tag":143,"props":483,"children":484},{"style":162},[485],{"type":78,"value":328},{"type":67,"tag":143,"props":487,"children":488},{"style":156},[489],{"type":78,"value":333},{"type":67,"tag":143,"props":491,"children":492},{"style":217},[493],{"type":78,"value":338},{"type":67,"tag":143,"props":495,"children":496},{"style":162},[497],{"type":78,"value":225},{"type":67,"tag":143,"props":499,"children":500},{"style":156},[501],{"type":78,"value":347},{"type":67,"tag":143,"props":503,"children":504},{"style":162},[505],{"type":78,"value":289},{"type":67,"tag":143,"props":507,"children":508},{"class":145,"line":193},[509],{"type":67,"tag":143,"props":510,"children":511},{"emptyLinePlaceholder":197},[512],{"type":78,"value":200},{"type":67,"tag":143,"props":514,"children":515},{"class":145,"line":203},[516,520,524,529,533,537,541,546,550,554,558,562,567],{"type":67,"tag":143,"props":517,"children":518},{"style":228},[519],{"type":78,"value":323},{"type":67,"tag":143,"props":521,"children":522},{"style":156},[523],{"type":78,"value":159},{"type":67,"tag":143,"props":525,"children":526},{"style":162},[527],{"type":78,"value":528}," data ",{"type":67,"tag":143,"props":530,"children":531},{"style":156},[532],{"type":78,"value":298},{"type":67,"tag":143,"props":534,"children":535},{"style":156},[536],{"type":78,"value":414},{"type":67,"tag":143,"props":538,"children":539},{"style":150},[540],{"type":78,"value":271},{"type":67,"tag":143,"props":542,"children":543},{"style":217},[544],{"type":78,"value":545}," useFetch",{"type":67,"tag":143,"props":547,"children":548},{"style":162},[549],{"type":78,"value":225},{"type":67,"tag":143,"props":551,"children":552},{"style":156},[553],{"type":78,"value":432},{"type":67,"tag":143,"props":555,"children":556},{"style":183},[557],{"type":78,"value":437},{"type":67,"tag":143,"props":559,"children":560},{"style":156},[561],{"type":78,"value":432},{"type":67,"tag":143,"props":563,"children":564},{"style":156},[565],{"type":78,"value":566},",",{"type":67,"tag":143,"props":568,"children":569},{"style":156},[570],{"type":78,"value":257},{"type":67,"tag":143,"props":572,"children":573},{"class":145,"line":260},[574,579,584,589,594,598,603,607],{"type":67,"tag":143,"props":575,"children":576},{"style":278},[577],{"type":78,"value":578}," headers",{"type":67,"tag":143,"props":580,"children":581},{"style":156},[582],{"type":78,"value":583},":",{"type":67,"tag":143,"props":585,"children":586},{"style":217},[587],{"type":78,"value":588}," useRequestHeaders",{"type":67,"tag":143,"props":590,"children":591},{"style":162},[592],{"type":78,"value":593},"([",{"type":67,"tag":143,"props":595,"children":596},{"style":156},[597],{"type":78,"value":432},{"type":67,"tag":143,"props":599,"children":600},{"style":183},[601],{"type":78,"value":602},"cookie",{"type":67,"tag":143,"props":604,"children":605},{"style":156},[606],{"type":78,"value":432},{"type":67,"tag":143,"props":608,"children":609},{"style":162},[610],{"type":78,"value":611},"])\n",{"type":67,"tag":143,"props":613,"children":614},{"class":145,"line":292},[615,619],{"type":67,"tag":143,"props":616,"children":617},{"style":156},[618],{"type":78,"value":298},{"type":67,"tag":143,"props":620,"children":621},{"style":162},[622],{"type":78,"value":289},{"type":67,"tag":143,"props":624,"children":626},{"class":145,"line":625},6,[627],{"type":67,"tag":143,"props":628,"children":629},{"emptyLinePlaceholder":197},[630],{"type":78,"value":200},{"type":67,"tag":143,"props":632,"children":634},{"class":145,"line":633},7,[635,640,644,649,653],{"type":67,"tag":143,"props":636,"children":637},{"style":162},[638],{"type":78,"value":639},"session",{"type":67,"tag":143,"props":641,"children":642},{"style":156},[643],{"type":78,"value":110},{"type":67,"tag":143,"props":645,"children":646},{"style":162},[647],{"type":78,"value":648},"value ",{"type":67,"tag":143,"props":650,"children":651},{"style":156},[652],{"type":78,"value":333},{"type":67,"tag":143,"props":654,"children":655},{"style":162},[656],{"type":78,"value":657}," data\n",{"type":67,"tag":659,"props":660,"children":661},"style",{},[662],{"type":78,"value":663},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":61,"searchDepth":193,"depth":193,"links":665},[],"markdown","content:4.usage:services:3.serverSupabaseSession.md","content","4.usage/services/3.serverSupabaseSession.md","4.usage/services/3.serverSupabaseSession","md",[673,676],{"_path":38,"title":674,"description":675},"serverServiceRole","Make requests with super admin rights to the Supabase API with the serverSupabaseServiceRole service",{"_path":44,"title":43,"description":677},"Get your Supabase user from serverside with the serverSupabaseUser service",1724940863140] \ No newline at end of file +[{"data":1,"prerenderedAt":678},["ShallowReactive",2],{"navigation":3,"/usage/services/serversupabasesession":58,"/usage/services/serversupabasesession-surround":672},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":41,"_dir":59,"_draft":60,"_partial":60,"_locale":61,"title":40,"description":62,"body":63,"_type":666,"_id":667,"_source":668,"_file":669,"_stem":670,"_extension":671},"services",false,"","Get your Supabase user's session from serverside with the serverSupabaseUser service",{"type":64,"children":65,"toc":664},"root",[66,91,111,131,303,308,454,468,658],{"type":67,"tag":68,"props":69,"children":72},"element","callout",{"color":70,"icon":71},"amber","i-heroicons-exclamation-triangle-20-solid",[73],{"type":67,"tag":74,"props":75,"children":76},"p",{},[77,80,89],{"type":78,"value":79},"text","This section assumes you're familiar with ",{"type":67,"tag":81,"props":82,"children":86},"a",{"href":83,"rel":84},"https://v3.nuxtjs.org/guide/concepts/server-engine",[85],"nofollow",[87],{"type":78,"value":88},"Nitro",{"type":78,"value":90},", the server engine powered by Nuxt.",{"type":67,"tag":74,"props":92,"children":93},{},[94,96,100,102,109],{"type":78,"value":95},"This function is similar to the ",{"type":67,"tag":81,"props":97,"children":98},{"href":25},[99],{"type":78,"value":24},{"type":78,"value":101}," composable but is used in ",{"type":67,"tag":81,"props":103,"children":106},{"href":104,"rel":105},"https://nuxt.com/docs/guide/directory-structure/server#server-routes",[85],[107],{"type":78,"value":108},"server routes",{"type":78,"value":110},".",{"type":67,"tag":74,"props":112,"children":113},{},[114,116,122,124,130],{"type":78,"value":115},"Define your server route and import the ",{"type":67,"tag":117,"props":118,"children":120},"code",{"className":119},[],[121],{"type":78,"value":40},{"type":78,"value":123}," from ",{"type":67,"tag":117,"props":125,"children":127},{"className":126},[],[128],{"type":78,"value":129},"#supabase/server",{"type":78,"value":110},{"type":67,"tag":132,"props":133,"children":138},"pre",{"className":134,"code":135,"filename":136,"language":137,"meta":61,"style":61},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","import { serverSupabaseSession } from '#supabase/server'\n\nexport default defineEventHandler(async (event) => {\n return await serverSupabaseSession(event)\n})\n","server/api/session.ts","ts",[139],{"type":67,"tag":117,"props":140,"children":141},{"__ignoreMap":61},[142,191,201,258,290],{"type":67,"tag":143,"props":144,"children":147},"span",{"class":145,"line":146},"line",1,[148,154,160,166,171,176,181,186],{"type":67,"tag":143,"props":149,"children":151},{"style":150},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[152],{"type":78,"value":153},"import",{"type":67,"tag":143,"props":155,"children":157},{"style":156},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[158],{"type":78,"value":159}," {",{"type":67,"tag":143,"props":161,"children":163},{"style":162},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[164],{"type":78,"value":165}," serverSupabaseSession",{"type":67,"tag":143,"props":167,"children":168},{"style":156},[169],{"type":78,"value":170}," }",{"type":67,"tag":143,"props":172,"children":173},{"style":150},[174],{"type":78,"value":175}," from",{"type":67,"tag":143,"props":177,"children":178},{"style":156},[179],{"type":78,"value":180}," '",{"type":67,"tag":143,"props":182,"children":184},{"style":183},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[185],{"type":78,"value":129},{"type":67,"tag":143,"props":187,"children":188},{"style":156},[189],{"type":78,"value":190},"'\n",{"type":67,"tag":143,"props":192,"children":194},{"class":145,"line":193},2,[195],{"type":67,"tag":143,"props":196,"children":198},{"emptyLinePlaceholder":197},true,[199],{"type":78,"value":200},"\n",{"type":67,"tag":143,"props":202,"children":204},{"class":145,"line":203},3,[205,210,215,221,226,232,237,243,248,253],{"type":67,"tag":143,"props":206,"children":207},{"style":150},[208],{"type":78,"value":209},"export",{"type":67,"tag":143,"props":211,"children":212},{"style":150},[213],{"type":78,"value":214}," default",{"type":67,"tag":143,"props":216,"children":218},{"style":217},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[219],{"type":78,"value":220}," defineEventHandler",{"type":67,"tag":143,"props":222,"children":223},{"style":162},[224],{"type":78,"value":225},"(",{"type":67,"tag":143,"props":227,"children":229},{"style":228},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[230],{"type":78,"value":231},"async",{"type":67,"tag":143,"props":233,"children":234},{"style":156},[235],{"type":78,"value":236}," (",{"type":67,"tag":143,"props":238,"children":240},{"style":239},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[241],{"type":78,"value":242},"event",{"type":67,"tag":143,"props":244,"children":245},{"style":156},[246],{"type":78,"value":247},")",{"type":67,"tag":143,"props":249,"children":250},{"style":228},[251],{"type":78,"value":252}," =>",{"type":67,"tag":143,"props":254,"children":255},{"style":156},[256],{"type":78,"value":257}," {\n",{"type":67,"tag":143,"props":259,"children":261},{"class":145,"line":260},4,[262,267,272,276,281,285],{"type":67,"tag":143,"props":263,"children":264},{"style":150},[265],{"type":78,"value":266}," return",{"type":67,"tag":143,"props":268,"children":269},{"style":150},[270],{"type":78,"value":271}," await",{"type":67,"tag":143,"props":273,"children":274},{"style":217},[275],{"type":78,"value":165},{"type":67,"tag":143,"props":277,"children":279},{"style":278},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[280],{"type":78,"value":225},{"type":67,"tag":143,"props":282,"children":283},{"style":162},[284],{"type":78,"value":242},{"type":67,"tag":143,"props":286,"children":287},{"style":278},[288],{"type":78,"value":289},")\n",{"type":67,"tag":143,"props":291,"children":293},{"class":145,"line":292},5,[294,299],{"type":67,"tag":143,"props":295,"children":296},{"style":156},[297],{"type":78,"value":298},"}",{"type":67,"tag":143,"props":300,"children":301},{"style":162},[302],{"type":78,"value":289},{"type":67,"tag":74,"props":304,"children":305},{},[306],{"type":78,"value":307},"Then call your api route from any vue file:",{"type":67,"tag":132,"props":309,"children":312},{"className":134,"code":310,"filename":311,"language":137,"meta":61,"style":61},"const session = ref(null)\n\nconst fetchSession = async () => {\n session.value = await $fetch('/api/session')\n}\n","pages/index.vue",[313],{"type":67,"tag":117,"props":314,"children":315},{"__ignoreMap":61},[316,352,359,393,446],{"type":67,"tag":143,"props":317,"children":318},{"class":145,"line":146},[319,324,329,334,339,343,348],{"type":67,"tag":143,"props":320,"children":321},{"style":228},[322],{"type":78,"value":323},"const",{"type":67,"tag":143,"props":325,"children":326},{"style":162},[327],{"type":78,"value":328}," session ",{"type":67,"tag":143,"props":330,"children":331},{"style":156},[332],{"type":78,"value":333},"=",{"type":67,"tag":143,"props":335,"children":336},{"style":217},[337],{"type":78,"value":338}," ref",{"type":67,"tag":143,"props":340,"children":341},{"style":162},[342],{"type":78,"value":225},{"type":67,"tag":143,"props":344,"children":345},{"style":156},[346],{"type":78,"value":347},"null",{"type":67,"tag":143,"props":349,"children":350},{"style":162},[351],{"type":78,"value":289},{"type":67,"tag":143,"props":353,"children":354},{"class":145,"line":193},[355],{"type":67,"tag":143,"props":356,"children":357},{"emptyLinePlaceholder":197},[358],{"type":78,"value":200},{"type":67,"tag":143,"props":360,"children":361},{"class":145,"line":203},[362,366,371,375,380,385,389],{"type":67,"tag":143,"props":363,"children":364},{"style":228},[365],{"type":78,"value":323},{"type":67,"tag":143,"props":367,"children":368},{"style":162},[369],{"type":78,"value":370}," fetchSession ",{"type":67,"tag":143,"props":372,"children":373},{"style":156},[374],{"type":78,"value":333},{"type":67,"tag":143,"props":376,"children":377},{"style":228},[378],{"type":78,"value":379}," async",{"type":67,"tag":143,"props":381,"children":382},{"style":156},[383],{"type":78,"value":384}," ()",{"type":67,"tag":143,"props":386,"children":387},{"style":228},[388],{"type":78,"value":252},{"type":67,"tag":143,"props":390,"children":391},{"style":156},[392],{"type":78,"value":257},{"type":67,"tag":143,"props":394,"children":395},{"class":145,"line":260},[396,401,405,410,415,419,424,428,433,438,442],{"type":67,"tag":143,"props":397,"children":398},{"style":162},[399],{"type":78,"value":400}," session",{"type":67,"tag":143,"props":402,"children":403},{"style":156},[404],{"type":78,"value":110},{"type":67,"tag":143,"props":406,"children":407},{"style":162},[408],{"type":78,"value":409},"value",{"type":67,"tag":143,"props":411,"children":412},{"style":156},[413],{"type":78,"value":414}," =",{"type":67,"tag":143,"props":416,"children":417},{"style":150},[418],{"type":78,"value":271},{"type":67,"tag":143,"props":420,"children":421},{"style":217},[422],{"type":78,"value":423}," $fetch",{"type":67,"tag":143,"props":425,"children":426},{"style":278},[427],{"type":78,"value":225},{"type":67,"tag":143,"props":429,"children":430},{"style":156},[431],{"type":78,"value":432},"'",{"type":67,"tag":143,"props":434,"children":435},{"style":183},[436],{"type":78,"value":437},"/api/session",{"type":67,"tag":143,"props":439,"children":440},{"style":156},[441],{"type":78,"value":432},{"type":67,"tag":143,"props":443,"children":444},{"style":278},[445],{"type":78,"value":289},{"type":67,"tag":143,"props":447,"children":448},{"class":145,"line":292},[449],{"type":67,"tag":143,"props":450,"children":451},{"style":156},[452],{"type":78,"value":453},"}\n",{"type":67,"tag":74,"props":455,"children":456},{},[457,459,466],{"type":78,"value":458},"Be careful, if you want to call this route on SSR, please read this ",{"type":67,"tag":81,"props":460,"children":463},{"href":461,"rel":462},"https://nuxt.com/docs/getting-started/data-fetching#isomorphic-fetch-and-fetch",[85],[464],{"type":78,"value":465},"section",{"type":78,"value":467},", you must send your browser cookies including your supabase token.",{"type":67,"tag":132,"props":469,"children":471},{"className":134,"code":470,"filename":311,"language":137,"meta":61,"style":61},"const session = ref(null)\n\nconst { data } = await useFetch('/api/session', {\n headers: useRequestHeaders(['cookie'])\n})\n\nsession.value = data\n",[472],{"type":67,"tag":117,"props":473,"children":474},{"__ignoreMap":61},[475,506,513,571,612,623,631],{"type":67,"tag":143,"props":476,"children":477},{"class":145,"line":146},[478,482,486,490,494,498,502],{"type":67,"tag":143,"props":479,"children":480},{"style":228},[481],{"type":78,"value":323},{"type":67,"tag":143,"props":483,"children":484},{"style":162},[485],{"type":78,"value":328},{"type":67,"tag":143,"props":487,"children":488},{"style":156},[489],{"type":78,"value":333},{"type":67,"tag":143,"props":491,"children":492},{"style":217},[493],{"type":78,"value":338},{"type":67,"tag":143,"props":495,"children":496},{"style":162},[497],{"type":78,"value":225},{"type":67,"tag":143,"props":499,"children":500},{"style":156},[501],{"type":78,"value":347},{"type":67,"tag":143,"props":503,"children":504},{"style":162},[505],{"type":78,"value":289},{"type":67,"tag":143,"props":507,"children":508},{"class":145,"line":193},[509],{"type":67,"tag":143,"props":510,"children":511},{"emptyLinePlaceholder":197},[512],{"type":78,"value":200},{"type":67,"tag":143,"props":514,"children":515},{"class":145,"line":203},[516,520,524,529,533,537,541,546,550,554,558,562,567],{"type":67,"tag":143,"props":517,"children":518},{"style":228},[519],{"type":78,"value":323},{"type":67,"tag":143,"props":521,"children":522},{"style":156},[523],{"type":78,"value":159},{"type":67,"tag":143,"props":525,"children":526},{"style":162},[527],{"type":78,"value":528}," data ",{"type":67,"tag":143,"props":530,"children":531},{"style":156},[532],{"type":78,"value":298},{"type":67,"tag":143,"props":534,"children":535},{"style":156},[536],{"type":78,"value":414},{"type":67,"tag":143,"props":538,"children":539},{"style":150},[540],{"type":78,"value":271},{"type":67,"tag":143,"props":542,"children":543},{"style":217},[544],{"type":78,"value":545}," useFetch",{"type":67,"tag":143,"props":547,"children":548},{"style":162},[549],{"type":78,"value":225},{"type":67,"tag":143,"props":551,"children":552},{"style":156},[553],{"type":78,"value":432},{"type":67,"tag":143,"props":555,"children":556},{"style":183},[557],{"type":78,"value":437},{"type":67,"tag":143,"props":559,"children":560},{"style":156},[561],{"type":78,"value":432},{"type":67,"tag":143,"props":563,"children":564},{"style":156},[565],{"type":78,"value":566},",",{"type":67,"tag":143,"props":568,"children":569},{"style":156},[570],{"type":78,"value":257},{"type":67,"tag":143,"props":572,"children":573},{"class":145,"line":260},[574,579,584,589,594,598,603,607],{"type":67,"tag":143,"props":575,"children":576},{"style":278},[577],{"type":78,"value":578}," headers",{"type":67,"tag":143,"props":580,"children":581},{"style":156},[582],{"type":78,"value":583},":",{"type":67,"tag":143,"props":585,"children":586},{"style":217},[587],{"type":78,"value":588}," useRequestHeaders",{"type":67,"tag":143,"props":590,"children":591},{"style":162},[592],{"type":78,"value":593},"([",{"type":67,"tag":143,"props":595,"children":596},{"style":156},[597],{"type":78,"value":432},{"type":67,"tag":143,"props":599,"children":600},{"style":183},[601],{"type":78,"value":602},"cookie",{"type":67,"tag":143,"props":604,"children":605},{"style":156},[606],{"type":78,"value":432},{"type":67,"tag":143,"props":608,"children":609},{"style":162},[610],{"type":78,"value":611},"])\n",{"type":67,"tag":143,"props":613,"children":614},{"class":145,"line":292},[615,619],{"type":67,"tag":143,"props":616,"children":617},{"style":156},[618],{"type":78,"value":298},{"type":67,"tag":143,"props":620,"children":621},{"style":162},[622],{"type":78,"value":289},{"type":67,"tag":143,"props":624,"children":626},{"class":145,"line":625},6,[627],{"type":67,"tag":143,"props":628,"children":629},{"emptyLinePlaceholder":197},[630],{"type":78,"value":200},{"type":67,"tag":143,"props":632,"children":634},{"class":145,"line":633},7,[635,640,644,649,653],{"type":67,"tag":143,"props":636,"children":637},{"style":162},[638],{"type":78,"value":639},"session",{"type":67,"tag":143,"props":641,"children":642},{"style":156},[643],{"type":78,"value":110},{"type":67,"tag":143,"props":645,"children":646},{"style":162},[647],{"type":78,"value":648},"value ",{"type":67,"tag":143,"props":650,"children":651},{"style":156},[652],{"type":78,"value":333},{"type":67,"tag":143,"props":654,"children":655},{"style":162},[656],{"type":78,"value":657}," data\n",{"type":67,"tag":659,"props":660,"children":661},"style",{},[662],{"type":78,"value":663},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":61,"searchDepth":193,"depth":193,"links":665},[],"markdown","content:4.usage:services:3.serverSupabaseSession.md","content","4.usage/services/3.serverSupabaseSession.md","4.usage/services/3.serverSupabaseSession","md",[673,676],{"_path":38,"title":674,"description":675},"serverServiceRole","Make requests with super admin rights to the Supabase API with the serverSupabaseServiceRole service",{"_path":44,"title":43,"description":677},"Get your Supabase user from serverside with the serverSupabaseUser service",1724942526936] \ No newline at end of file diff --git a/usage/services/serversupabasesession/index.html b/usage/services/serversupabasesession/index.html index 80e71bda..b05d7051 100644 --- a/usage/services/serversupabasesession/index.html +++ b/usage/services/serversupabasesession/index.html @@ -61,7 +61,7 @@ - + @@ -121,5 +121,5 @@ session.value = data
Made with Nuxt Studio
- - \ No newline at end of file + + \ No newline at end of file diff --git a/usage/services/serversupabaseuser/_payload.json b/usage/services/serversupabaseuser/_payload.json index bec98cb7..b3ce8693 100644 --- a/usage/services/serversupabaseuser/_payload.json +++ b/usage/services/serversupabaseuser/_payload.json @@ -1 +1 @@ -[{"data":1,"prerenderedAt":677},["ShallowReactive",2],{"navigation":3,"/usage/services/serversupabaseuser":58,"/usage/services/serversupabaseuser-surround":672},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":44,"_dir":59,"_draft":60,"_partial":60,"_locale":61,"title":43,"description":62,"body":63,"_type":666,"_id":667,"_source":668,"_file":669,"_stem":670,"_extension":671},"services",false,"","Get your Supabase user from serverside with the serverSupabaseUser service",{"type":64,"children":65,"toc":664},"root",[66,91,111,131,303,308,454,468,658],{"type":67,"tag":68,"props":69,"children":72},"element","callout",{"color":70,"icon":71},"amber","i-heroicons-exclamation-triangle-20-solid",[73],{"type":67,"tag":74,"props":75,"children":76},"p",{},[77,80,89],{"type":78,"value":79},"text","This section assumes you're familiar with ",{"type":67,"tag":81,"props":82,"children":86},"a",{"href":83,"rel":84},"https://v3.nuxtjs.org/guide/concepts/server-engine",[85],"nofollow",[87],{"type":78,"value":88},"Nitro",{"type":78,"value":90},", the server engine powered by Nuxt.",{"type":67,"tag":74,"props":92,"children":93},{},[94,96,100,102,109],{"type":78,"value":95},"This function is similar to the ",{"type":67,"tag":81,"props":97,"children":98},{"href":28},[99],{"type":78,"value":27},{"type":78,"value":101}," composable but is used in ",{"type":67,"tag":81,"props":103,"children":106},{"href":104,"rel":105},"https://nuxt.com/docs/guide/directory-structure/server#server-routes",[85],[107],{"type":78,"value":108},"server routes",{"type":78,"value":110},".",{"type":67,"tag":74,"props":112,"children":113},{},[114,116,122,124,130],{"type":78,"value":115},"Define your server route and import the ",{"type":67,"tag":117,"props":118,"children":120},"code",{"className":119},[],[121],{"type":78,"value":43},{"type":78,"value":123}," from ",{"type":67,"tag":117,"props":125,"children":127},{"className":126},[],[128],{"type":78,"value":129},"#supabase/server",{"type":78,"value":110},{"type":67,"tag":132,"props":133,"children":138},"pre",{"className":134,"code":135,"filename":136,"language":137,"meta":61,"style":61},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","import { serverSupabaseUser } from '#supabase/server'\n\nexport default defineEventHandler(async (event) => {\n return await serverSupabaseUser(event)\n})\n","server/api/me.ts","ts",[139],{"type":67,"tag":117,"props":140,"children":141},{"__ignoreMap":61},[142,191,201,258,290],{"type":67,"tag":143,"props":144,"children":147},"span",{"class":145,"line":146},"line",1,[148,154,160,166,171,176,181,186],{"type":67,"tag":143,"props":149,"children":151},{"style":150},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[152],{"type":78,"value":153},"import",{"type":67,"tag":143,"props":155,"children":157},{"style":156},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[158],{"type":78,"value":159}," {",{"type":67,"tag":143,"props":161,"children":163},{"style":162},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[164],{"type":78,"value":165}," serverSupabaseUser",{"type":67,"tag":143,"props":167,"children":168},{"style":156},[169],{"type":78,"value":170}," }",{"type":67,"tag":143,"props":172,"children":173},{"style":150},[174],{"type":78,"value":175}," from",{"type":67,"tag":143,"props":177,"children":178},{"style":156},[179],{"type":78,"value":180}," '",{"type":67,"tag":143,"props":182,"children":184},{"style":183},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[185],{"type":78,"value":129},{"type":67,"tag":143,"props":187,"children":188},{"style":156},[189],{"type":78,"value":190},"'\n",{"type":67,"tag":143,"props":192,"children":194},{"class":145,"line":193},2,[195],{"type":67,"tag":143,"props":196,"children":198},{"emptyLinePlaceholder":197},true,[199],{"type":78,"value":200},"\n",{"type":67,"tag":143,"props":202,"children":204},{"class":145,"line":203},3,[205,210,215,221,226,232,237,243,248,253],{"type":67,"tag":143,"props":206,"children":207},{"style":150},[208],{"type":78,"value":209},"export",{"type":67,"tag":143,"props":211,"children":212},{"style":150},[213],{"type":78,"value":214}," default",{"type":67,"tag":143,"props":216,"children":218},{"style":217},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[219],{"type":78,"value":220}," defineEventHandler",{"type":67,"tag":143,"props":222,"children":223},{"style":162},[224],{"type":78,"value":225},"(",{"type":67,"tag":143,"props":227,"children":229},{"style":228},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[230],{"type":78,"value":231},"async",{"type":67,"tag":143,"props":233,"children":234},{"style":156},[235],{"type":78,"value":236}," (",{"type":67,"tag":143,"props":238,"children":240},{"style":239},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[241],{"type":78,"value":242},"event",{"type":67,"tag":143,"props":244,"children":245},{"style":156},[246],{"type":78,"value":247},")",{"type":67,"tag":143,"props":249,"children":250},{"style":228},[251],{"type":78,"value":252}," =>",{"type":67,"tag":143,"props":254,"children":255},{"style":156},[256],{"type":78,"value":257}," {\n",{"type":67,"tag":143,"props":259,"children":261},{"class":145,"line":260},4,[262,267,272,276,281,285],{"type":67,"tag":143,"props":263,"children":264},{"style":150},[265],{"type":78,"value":266}," return",{"type":67,"tag":143,"props":268,"children":269},{"style":150},[270],{"type":78,"value":271}," await",{"type":67,"tag":143,"props":273,"children":274},{"style":217},[275],{"type":78,"value":165},{"type":67,"tag":143,"props":277,"children":279},{"style":278},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[280],{"type":78,"value":225},{"type":67,"tag":143,"props":282,"children":283},{"style":162},[284],{"type":78,"value":242},{"type":67,"tag":143,"props":286,"children":287},{"style":278},[288],{"type":78,"value":289},")\n",{"type":67,"tag":143,"props":291,"children":293},{"class":145,"line":292},5,[294,299],{"type":67,"tag":143,"props":295,"children":296},{"style":156},[297],{"type":78,"value":298},"}",{"type":67,"tag":143,"props":300,"children":301},{"style":162},[302],{"type":78,"value":289},{"type":67,"tag":74,"props":304,"children":305},{},[306],{"type":78,"value":307},"Then call your api route from any vue file:",{"type":67,"tag":132,"props":309,"children":312},{"className":134,"code":310,"filename":311,"language":137,"meta":61,"style":61},"const user = ref(null)\n\nconst fetchMe = async () => {\n user.value = await $fetch('/api/me')\n}\n","pages/index.vue",[313],{"type":67,"tag":117,"props":314,"children":315},{"__ignoreMap":61},[316,352,359,393,446],{"type":67,"tag":143,"props":317,"children":318},{"class":145,"line":146},[319,324,329,334,339,343,348],{"type":67,"tag":143,"props":320,"children":321},{"style":228},[322],{"type":78,"value":323},"const",{"type":67,"tag":143,"props":325,"children":326},{"style":162},[327],{"type":78,"value":328}," user ",{"type":67,"tag":143,"props":330,"children":331},{"style":156},[332],{"type":78,"value":333},"=",{"type":67,"tag":143,"props":335,"children":336},{"style":217},[337],{"type":78,"value":338}," ref",{"type":67,"tag":143,"props":340,"children":341},{"style":162},[342],{"type":78,"value":225},{"type":67,"tag":143,"props":344,"children":345},{"style":156},[346],{"type":78,"value":347},"null",{"type":67,"tag":143,"props":349,"children":350},{"style":162},[351],{"type":78,"value":289},{"type":67,"tag":143,"props":353,"children":354},{"class":145,"line":193},[355],{"type":67,"tag":143,"props":356,"children":357},{"emptyLinePlaceholder":197},[358],{"type":78,"value":200},{"type":67,"tag":143,"props":360,"children":361},{"class":145,"line":203},[362,366,371,375,380,385,389],{"type":67,"tag":143,"props":363,"children":364},{"style":228},[365],{"type":78,"value":323},{"type":67,"tag":143,"props":367,"children":368},{"style":162},[369],{"type":78,"value":370}," fetchMe ",{"type":67,"tag":143,"props":372,"children":373},{"style":156},[374],{"type":78,"value":333},{"type":67,"tag":143,"props":376,"children":377},{"style":228},[378],{"type":78,"value":379}," async",{"type":67,"tag":143,"props":381,"children":382},{"style":156},[383],{"type":78,"value":384}," ()",{"type":67,"tag":143,"props":386,"children":387},{"style":228},[388],{"type":78,"value":252},{"type":67,"tag":143,"props":390,"children":391},{"style":156},[392],{"type":78,"value":257},{"type":67,"tag":143,"props":394,"children":395},{"class":145,"line":260},[396,401,405,410,415,419,424,428,433,438,442],{"type":67,"tag":143,"props":397,"children":398},{"style":162},[399],{"type":78,"value":400}," user",{"type":67,"tag":143,"props":402,"children":403},{"style":156},[404],{"type":78,"value":110},{"type":67,"tag":143,"props":406,"children":407},{"style":162},[408],{"type":78,"value":409},"value",{"type":67,"tag":143,"props":411,"children":412},{"style":156},[413],{"type":78,"value":414}," =",{"type":67,"tag":143,"props":416,"children":417},{"style":150},[418],{"type":78,"value":271},{"type":67,"tag":143,"props":420,"children":421},{"style":217},[422],{"type":78,"value":423}," $fetch",{"type":67,"tag":143,"props":425,"children":426},{"style":278},[427],{"type":78,"value":225},{"type":67,"tag":143,"props":429,"children":430},{"style":156},[431],{"type":78,"value":432},"'",{"type":67,"tag":143,"props":434,"children":435},{"style":183},[436],{"type":78,"value":437},"/api/me",{"type":67,"tag":143,"props":439,"children":440},{"style":156},[441],{"type":78,"value":432},{"type":67,"tag":143,"props":443,"children":444},{"style":278},[445],{"type":78,"value":289},{"type":67,"tag":143,"props":447,"children":448},{"class":145,"line":292},[449],{"type":67,"tag":143,"props":450,"children":451},{"style":156},[452],{"type":78,"value":453},"}\n",{"type":67,"tag":74,"props":455,"children":456},{},[457,459,466],{"type":78,"value":458},"Be careful, if you want to call this route on SSR, please read this ",{"type":67,"tag":81,"props":460,"children":463},{"href":461,"rel":462},"https://nuxt.com/docs/getting-started/data-fetching#isomorphic-fetch-and-fetch",[85],[464],{"type":78,"value":465},"section",{"type":78,"value":467},", you must send your browser cookies including your supabase token.",{"type":67,"tag":132,"props":469,"children":471},{"className":134,"code":470,"filename":311,"language":137,"meta":61,"style":61},"const user = ref(null)\n\nconst { data } = await useFetch('/api/me', {\n headers: useRequestHeaders(['cookie'])\n})\n\nuser.value = data\n",[472],{"type":67,"tag":117,"props":473,"children":474},{"__ignoreMap":61},[475,506,513,571,612,623,631],{"type":67,"tag":143,"props":476,"children":477},{"class":145,"line":146},[478,482,486,490,494,498,502],{"type":67,"tag":143,"props":479,"children":480},{"style":228},[481],{"type":78,"value":323},{"type":67,"tag":143,"props":483,"children":484},{"style":162},[485],{"type":78,"value":328},{"type":67,"tag":143,"props":487,"children":488},{"style":156},[489],{"type":78,"value":333},{"type":67,"tag":143,"props":491,"children":492},{"style":217},[493],{"type":78,"value":338},{"type":67,"tag":143,"props":495,"children":496},{"style":162},[497],{"type":78,"value":225},{"type":67,"tag":143,"props":499,"children":500},{"style":156},[501],{"type":78,"value":347},{"type":67,"tag":143,"props":503,"children":504},{"style":162},[505],{"type":78,"value":289},{"type":67,"tag":143,"props":507,"children":508},{"class":145,"line":193},[509],{"type":67,"tag":143,"props":510,"children":511},{"emptyLinePlaceholder":197},[512],{"type":78,"value":200},{"type":67,"tag":143,"props":514,"children":515},{"class":145,"line":203},[516,520,524,529,533,537,541,546,550,554,558,562,567],{"type":67,"tag":143,"props":517,"children":518},{"style":228},[519],{"type":78,"value":323},{"type":67,"tag":143,"props":521,"children":522},{"style":156},[523],{"type":78,"value":159},{"type":67,"tag":143,"props":525,"children":526},{"style":162},[527],{"type":78,"value":528}," data ",{"type":67,"tag":143,"props":530,"children":531},{"style":156},[532],{"type":78,"value":298},{"type":67,"tag":143,"props":534,"children":535},{"style":156},[536],{"type":78,"value":414},{"type":67,"tag":143,"props":538,"children":539},{"style":150},[540],{"type":78,"value":271},{"type":67,"tag":143,"props":542,"children":543},{"style":217},[544],{"type":78,"value":545}," useFetch",{"type":67,"tag":143,"props":547,"children":548},{"style":162},[549],{"type":78,"value":225},{"type":67,"tag":143,"props":551,"children":552},{"style":156},[553],{"type":78,"value":432},{"type":67,"tag":143,"props":555,"children":556},{"style":183},[557],{"type":78,"value":437},{"type":67,"tag":143,"props":559,"children":560},{"style":156},[561],{"type":78,"value":432},{"type":67,"tag":143,"props":563,"children":564},{"style":156},[565],{"type":78,"value":566},",",{"type":67,"tag":143,"props":568,"children":569},{"style":156},[570],{"type":78,"value":257},{"type":67,"tag":143,"props":572,"children":573},{"class":145,"line":260},[574,579,584,589,594,598,603,607],{"type":67,"tag":143,"props":575,"children":576},{"style":278},[577],{"type":78,"value":578}," headers",{"type":67,"tag":143,"props":580,"children":581},{"style":156},[582],{"type":78,"value":583},":",{"type":67,"tag":143,"props":585,"children":586},{"style":217},[587],{"type":78,"value":588}," useRequestHeaders",{"type":67,"tag":143,"props":590,"children":591},{"style":162},[592],{"type":78,"value":593},"([",{"type":67,"tag":143,"props":595,"children":596},{"style":156},[597],{"type":78,"value":432},{"type":67,"tag":143,"props":599,"children":600},{"style":183},[601],{"type":78,"value":602},"cookie",{"type":67,"tag":143,"props":604,"children":605},{"style":156},[606],{"type":78,"value":432},{"type":67,"tag":143,"props":608,"children":609},{"style":162},[610],{"type":78,"value":611},"])\n",{"type":67,"tag":143,"props":613,"children":614},{"class":145,"line":292},[615,619],{"type":67,"tag":143,"props":616,"children":617},{"style":156},[618],{"type":78,"value":298},{"type":67,"tag":143,"props":620,"children":621},{"style":162},[622],{"type":78,"value":289},{"type":67,"tag":143,"props":624,"children":626},{"class":145,"line":625},6,[627],{"type":67,"tag":143,"props":628,"children":629},{"emptyLinePlaceholder":197},[630],{"type":78,"value":200},{"type":67,"tag":143,"props":632,"children":634},{"class":145,"line":633},7,[635,640,644,649,653],{"type":67,"tag":143,"props":636,"children":637},{"style":162},[638],{"type":78,"value":639},"user",{"type":67,"tag":143,"props":641,"children":642},{"style":156},[643],{"type":78,"value":110},{"type":67,"tag":143,"props":645,"children":646},{"style":162},[647],{"type":78,"value":648},"value ",{"type":67,"tag":143,"props":650,"children":651},{"style":156},[652],{"type":78,"value":333},{"type":67,"tag":143,"props":654,"children":655},{"style":162},[656],{"type":78,"value":657}," data\n",{"type":67,"tag":659,"props":660,"children":661},"style",{},[662],{"type":78,"value":663},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":61,"searchDepth":193,"depth":193,"links":665},[],"markdown","content:4.usage:services:4.serverSupabaseUser.md","content","4.usage/services/4.serverSupabaseUser.md","4.usage/services/4.serverSupabaseUser","md",[673,675],{"_path":41,"title":40,"description":674},"Get your Supabase user's session from serverside with the serverSupabaseUser service",{"_path":48,"title":47,"description":676},"Demonstration of using Supabase with Nuxt.",1724940863147] \ No newline at end of file +[{"data":1,"prerenderedAt":677},["ShallowReactive",2],{"navigation":3,"/usage/services/serversupabaseuser":58,"/usage/services/serversupabaseuser-surround":672},[4,8,12,46,50,54],{"title":5,"_path":6,"icon":7},"Get Started","/get-started","i-heroicons-rocket-launch",{"title":9,"_path":10,"icon":11},"Authentication","/authentication","i-heroicons-lock-closed",{"title":13,"_path":14,"children":15,"icon":45},"Usage","/usage",[16,29],{"title":17,"_path":18,"children":19},"Vue composables","/usage/composables",[20,23,26],{"title":21,"_path":22},"useSupabaseClient","/usage/composables/usesupabaseclient",{"title":24,"_path":25},"useSupabaseSession","/usage/composables/usesupabasesession",{"title":27,"_path":28},"useSupabaseUser","/usage/composables/usesupabaseuser",{"title":30,"_path":31,"children":32},"Server services","/usage/services",[33,36,39,42],{"title":34,"_path":35},"serverSupabaseClient","/usage/services/serversupabaseclient",{"title":37,"_path":38},"serverSupabaseServiceRole","/usage/services/serversupabaseservicerole",{"title":40,"_path":41},"serverSupabaseSession","/usage/services/serversupabasesession",{"title":43,"_path":44},"serverSupabaseUser","/usage/services/serversupabaseuser","heroicons:book-open",{"title":47,"_path":48,"icon":49},"Demo","/demo","i-heroicons-computer-desktop-20-solid",{"title":51,"_path":52,"icon":53},"Changelog","/changelog","i-heroicons-bookmark",{"title":55,"_path":56,"icon":57},"Roadmap","/roadmap","i-heroicons-map",{"_path":44,"_dir":59,"_draft":60,"_partial":60,"_locale":61,"title":43,"description":62,"body":63,"_type":666,"_id":667,"_source":668,"_file":669,"_stem":670,"_extension":671},"services",false,"","Get your Supabase user from serverside with the serverSupabaseUser service",{"type":64,"children":65,"toc":664},"root",[66,91,111,131,303,308,454,468,658],{"type":67,"tag":68,"props":69,"children":72},"element","callout",{"color":70,"icon":71},"amber","i-heroicons-exclamation-triangle-20-solid",[73],{"type":67,"tag":74,"props":75,"children":76},"p",{},[77,80,89],{"type":78,"value":79},"text","This section assumes you're familiar with ",{"type":67,"tag":81,"props":82,"children":86},"a",{"href":83,"rel":84},"https://v3.nuxtjs.org/guide/concepts/server-engine",[85],"nofollow",[87],{"type":78,"value":88},"Nitro",{"type":78,"value":90},", the server engine powered by Nuxt.",{"type":67,"tag":74,"props":92,"children":93},{},[94,96,100,102,109],{"type":78,"value":95},"This function is similar to the ",{"type":67,"tag":81,"props":97,"children":98},{"href":28},[99],{"type":78,"value":27},{"type":78,"value":101}," composable but is used in ",{"type":67,"tag":81,"props":103,"children":106},{"href":104,"rel":105},"https://nuxt.com/docs/guide/directory-structure/server#server-routes",[85],[107],{"type":78,"value":108},"server routes",{"type":78,"value":110},".",{"type":67,"tag":74,"props":112,"children":113},{},[114,116,122,124,130],{"type":78,"value":115},"Define your server route and import the ",{"type":67,"tag":117,"props":118,"children":120},"code",{"className":119},[],[121],{"type":78,"value":43},{"type":78,"value":123}," from ",{"type":67,"tag":117,"props":125,"children":127},{"className":126},[],[128],{"type":78,"value":129},"#supabase/server",{"type":78,"value":110},{"type":67,"tag":132,"props":133,"children":138},"pre",{"className":134,"code":135,"filename":136,"language":137,"meta":61,"style":61},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","import { serverSupabaseUser } from '#supabase/server'\n\nexport default defineEventHandler(async (event) => {\n return await serverSupabaseUser(event)\n})\n","server/api/me.ts","ts",[139],{"type":67,"tag":117,"props":140,"children":141},{"__ignoreMap":61},[142,191,201,258,290],{"type":67,"tag":143,"props":144,"children":147},"span",{"class":145,"line":146},"line",1,[148,154,160,166,171,176,181,186],{"type":67,"tag":143,"props":149,"children":151},{"style":150},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[152],{"type":78,"value":153},"import",{"type":67,"tag":143,"props":155,"children":157},{"style":156},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[158],{"type":78,"value":159}," {",{"type":67,"tag":143,"props":161,"children":163},{"style":162},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[164],{"type":78,"value":165}," serverSupabaseUser",{"type":67,"tag":143,"props":167,"children":168},{"style":156},[169],{"type":78,"value":170}," }",{"type":67,"tag":143,"props":172,"children":173},{"style":150},[174],{"type":78,"value":175}," from",{"type":67,"tag":143,"props":177,"children":178},{"style":156},[179],{"type":78,"value":180}," '",{"type":67,"tag":143,"props":182,"children":184},{"style":183},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[185],{"type":78,"value":129},{"type":67,"tag":143,"props":187,"children":188},{"style":156},[189],{"type":78,"value":190},"'\n",{"type":67,"tag":143,"props":192,"children":194},{"class":145,"line":193},2,[195],{"type":67,"tag":143,"props":196,"children":198},{"emptyLinePlaceholder":197},true,[199],{"type":78,"value":200},"\n",{"type":67,"tag":143,"props":202,"children":204},{"class":145,"line":203},3,[205,210,215,221,226,232,237,243,248,253],{"type":67,"tag":143,"props":206,"children":207},{"style":150},[208],{"type":78,"value":209},"export",{"type":67,"tag":143,"props":211,"children":212},{"style":150},[213],{"type":78,"value":214}," default",{"type":67,"tag":143,"props":216,"children":218},{"style":217},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[219],{"type":78,"value":220}," defineEventHandler",{"type":67,"tag":143,"props":222,"children":223},{"style":162},[224],{"type":78,"value":225},"(",{"type":67,"tag":143,"props":227,"children":229},{"style":228},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[230],{"type":78,"value":231},"async",{"type":67,"tag":143,"props":233,"children":234},{"style":156},[235],{"type":78,"value":236}," (",{"type":67,"tag":143,"props":238,"children":240},{"style":239},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[241],{"type":78,"value":242},"event",{"type":67,"tag":143,"props":244,"children":245},{"style":156},[246],{"type":78,"value":247},")",{"type":67,"tag":143,"props":249,"children":250},{"style":228},[251],{"type":78,"value":252}," =>",{"type":67,"tag":143,"props":254,"children":255},{"style":156},[256],{"type":78,"value":257}," {\n",{"type":67,"tag":143,"props":259,"children":261},{"class":145,"line":260},4,[262,267,272,276,281,285],{"type":67,"tag":143,"props":263,"children":264},{"style":150},[265],{"type":78,"value":266}," return",{"type":67,"tag":143,"props":268,"children":269},{"style":150},[270],{"type":78,"value":271}," await",{"type":67,"tag":143,"props":273,"children":274},{"style":217},[275],{"type":78,"value":165},{"type":67,"tag":143,"props":277,"children":279},{"style":278},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[280],{"type":78,"value":225},{"type":67,"tag":143,"props":282,"children":283},{"style":162},[284],{"type":78,"value":242},{"type":67,"tag":143,"props":286,"children":287},{"style":278},[288],{"type":78,"value":289},")\n",{"type":67,"tag":143,"props":291,"children":293},{"class":145,"line":292},5,[294,299],{"type":67,"tag":143,"props":295,"children":296},{"style":156},[297],{"type":78,"value":298},"}",{"type":67,"tag":143,"props":300,"children":301},{"style":162},[302],{"type":78,"value":289},{"type":67,"tag":74,"props":304,"children":305},{},[306],{"type":78,"value":307},"Then call your api route from any vue file:",{"type":67,"tag":132,"props":309,"children":312},{"className":134,"code":310,"filename":311,"language":137,"meta":61,"style":61},"const user = ref(null)\n\nconst fetchMe = async () => {\n user.value = await $fetch('/api/me')\n}\n","pages/index.vue",[313],{"type":67,"tag":117,"props":314,"children":315},{"__ignoreMap":61},[316,352,359,393,446],{"type":67,"tag":143,"props":317,"children":318},{"class":145,"line":146},[319,324,329,334,339,343,348],{"type":67,"tag":143,"props":320,"children":321},{"style":228},[322],{"type":78,"value":323},"const",{"type":67,"tag":143,"props":325,"children":326},{"style":162},[327],{"type":78,"value":328}," user ",{"type":67,"tag":143,"props":330,"children":331},{"style":156},[332],{"type":78,"value":333},"=",{"type":67,"tag":143,"props":335,"children":336},{"style":217},[337],{"type":78,"value":338}," ref",{"type":67,"tag":143,"props":340,"children":341},{"style":162},[342],{"type":78,"value":225},{"type":67,"tag":143,"props":344,"children":345},{"style":156},[346],{"type":78,"value":347},"null",{"type":67,"tag":143,"props":349,"children":350},{"style":162},[351],{"type":78,"value":289},{"type":67,"tag":143,"props":353,"children":354},{"class":145,"line":193},[355],{"type":67,"tag":143,"props":356,"children":357},{"emptyLinePlaceholder":197},[358],{"type":78,"value":200},{"type":67,"tag":143,"props":360,"children":361},{"class":145,"line":203},[362,366,371,375,380,385,389],{"type":67,"tag":143,"props":363,"children":364},{"style":228},[365],{"type":78,"value":323},{"type":67,"tag":143,"props":367,"children":368},{"style":162},[369],{"type":78,"value":370}," fetchMe ",{"type":67,"tag":143,"props":372,"children":373},{"style":156},[374],{"type":78,"value":333},{"type":67,"tag":143,"props":376,"children":377},{"style":228},[378],{"type":78,"value":379}," async",{"type":67,"tag":143,"props":381,"children":382},{"style":156},[383],{"type":78,"value":384}," ()",{"type":67,"tag":143,"props":386,"children":387},{"style":228},[388],{"type":78,"value":252},{"type":67,"tag":143,"props":390,"children":391},{"style":156},[392],{"type":78,"value":257},{"type":67,"tag":143,"props":394,"children":395},{"class":145,"line":260},[396,401,405,410,415,419,424,428,433,438,442],{"type":67,"tag":143,"props":397,"children":398},{"style":162},[399],{"type":78,"value":400}," user",{"type":67,"tag":143,"props":402,"children":403},{"style":156},[404],{"type":78,"value":110},{"type":67,"tag":143,"props":406,"children":407},{"style":162},[408],{"type":78,"value":409},"value",{"type":67,"tag":143,"props":411,"children":412},{"style":156},[413],{"type":78,"value":414}," =",{"type":67,"tag":143,"props":416,"children":417},{"style":150},[418],{"type":78,"value":271},{"type":67,"tag":143,"props":420,"children":421},{"style":217},[422],{"type":78,"value":423}," $fetch",{"type":67,"tag":143,"props":425,"children":426},{"style":278},[427],{"type":78,"value":225},{"type":67,"tag":143,"props":429,"children":430},{"style":156},[431],{"type":78,"value":432},"'",{"type":67,"tag":143,"props":434,"children":435},{"style":183},[436],{"type":78,"value":437},"/api/me",{"type":67,"tag":143,"props":439,"children":440},{"style":156},[441],{"type":78,"value":432},{"type":67,"tag":143,"props":443,"children":444},{"style":278},[445],{"type":78,"value":289},{"type":67,"tag":143,"props":447,"children":448},{"class":145,"line":292},[449],{"type":67,"tag":143,"props":450,"children":451},{"style":156},[452],{"type":78,"value":453},"}\n",{"type":67,"tag":74,"props":455,"children":456},{},[457,459,466],{"type":78,"value":458},"Be careful, if you want to call this route on SSR, please read this ",{"type":67,"tag":81,"props":460,"children":463},{"href":461,"rel":462},"https://nuxt.com/docs/getting-started/data-fetching#isomorphic-fetch-and-fetch",[85],[464],{"type":78,"value":465},"section",{"type":78,"value":467},", you must send your browser cookies including your supabase token.",{"type":67,"tag":132,"props":469,"children":471},{"className":134,"code":470,"filename":311,"language":137,"meta":61,"style":61},"const user = ref(null)\n\nconst { data } = await useFetch('/api/me', {\n headers: useRequestHeaders(['cookie'])\n})\n\nuser.value = data\n",[472],{"type":67,"tag":117,"props":473,"children":474},{"__ignoreMap":61},[475,506,513,571,612,623,631],{"type":67,"tag":143,"props":476,"children":477},{"class":145,"line":146},[478,482,486,490,494,498,502],{"type":67,"tag":143,"props":479,"children":480},{"style":228},[481],{"type":78,"value":323},{"type":67,"tag":143,"props":483,"children":484},{"style":162},[485],{"type":78,"value":328},{"type":67,"tag":143,"props":487,"children":488},{"style":156},[489],{"type":78,"value":333},{"type":67,"tag":143,"props":491,"children":492},{"style":217},[493],{"type":78,"value":338},{"type":67,"tag":143,"props":495,"children":496},{"style":162},[497],{"type":78,"value":225},{"type":67,"tag":143,"props":499,"children":500},{"style":156},[501],{"type":78,"value":347},{"type":67,"tag":143,"props":503,"children":504},{"style":162},[505],{"type":78,"value":289},{"type":67,"tag":143,"props":507,"children":508},{"class":145,"line":193},[509],{"type":67,"tag":143,"props":510,"children":511},{"emptyLinePlaceholder":197},[512],{"type":78,"value":200},{"type":67,"tag":143,"props":514,"children":515},{"class":145,"line":203},[516,520,524,529,533,537,541,546,550,554,558,562,567],{"type":67,"tag":143,"props":517,"children":518},{"style":228},[519],{"type":78,"value":323},{"type":67,"tag":143,"props":521,"children":522},{"style":156},[523],{"type":78,"value":159},{"type":67,"tag":143,"props":525,"children":526},{"style":162},[527],{"type":78,"value":528}," data ",{"type":67,"tag":143,"props":530,"children":531},{"style":156},[532],{"type":78,"value":298},{"type":67,"tag":143,"props":534,"children":535},{"style":156},[536],{"type":78,"value":414},{"type":67,"tag":143,"props":538,"children":539},{"style":150},[540],{"type":78,"value":271},{"type":67,"tag":143,"props":542,"children":543},{"style":217},[544],{"type":78,"value":545}," useFetch",{"type":67,"tag":143,"props":547,"children":548},{"style":162},[549],{"type":78,"value":225},{"type":67,"tag":143,"props":551,"children":552},{"style":156},[553],{"type":78,"value":432},{"type":67,"tag":143,"props":555,"children":556},{"style":183},[557],{"type":78,"value":437},{"type":67,"tag":143,"props":559,"children":560},{"style":156},[561],{"type":78,"value":432},{"type":67,"tag":143,"props":563,"children":564},{"style":156},[565],{"type":78,"value":566},",",{"type":67,"tag":143,"props":568,"children":569},{"style":156},[570],{"type":78,"value":257},{"type":67,"tag":143,"props":572,"children":573},{"class":145,"line":260},[574,579,584,589,594,598,603,607],{"type":67,"tag":143,"props":575,"children":576},{"style":278},[577],{"type":78,"value":578}," headers",{"type":67,"tag":143,"props":580,"children":581},{"style":156},[582],{"type":78,"value":583},":",{"type":67,"tag":143,"props":585,"children":586},{"style":217},[587],{"type":78,"value":588}," useRequestHeaders",{"type":67,"tag":143,"props":590,"children":591},{"style":162},[592],{"type":78,"value":593},"([",{"type":67,"tag":143,"props":595,"children":596},{"style":156},[597],{"type":78,"value":432},{"type":67,"tag":143,"props":599,"children":600},{"style":183},[601],{"type":78,"value":602},"cookie",{"type":67,"tag":143,"props":604,"children":605},{"style":156},[606],{"type":78,"value":432},{"type":67,"tag":143,"props":608,"children":609},{"style":162},[610],{"type":78,"value":611},"])\n",{"type":67,"tag":143,"props":613,"children":614},{"class":145,"line":292},[615,619],{"type":67,"tag":143,"props":616,"children":617},{"style":156},[618],{"type":78,"value":298},{"type":67,"tag":143,"props":620,"children":621},{"style":162},[622],{"type":78,"value":289},{"type":67,"tag":143,"props":624,"children":626},{"class":145,"line":625},6,[627],{"type":67,"tag":143,"props":628,"children":629},{"emptyLinePlaceholder":197},[630],{"type":78,"value":200},{"type":67,"tag":143,"props":632,"children":634},{"class":145,"line":633},7,[635,640,644,649,653],{"type":67,"tag":143,"props":636,"children":637},{"style":162},[638],{"type":78,"value":639},"user",{"type":67,"tag":143,"props":641,"children":642},{"style":156},[643],{"type":78,"value":110},{"type":67,"tag":143,"props":645,"children":646},{"style":162},[647],{"type":78,"value":648},"value ",{"type":67,"tag":143,"props":650,"children":651},{"style":156},[652],{"type":78,"value":333},{"type":67,"tag":143,"props":654,"children":655},{"style":162},[656],{"type":78,"value":657}," data\n",{"type":67,"tag":659,"props":660,"children":661},"style",{},[662],{"type":78,"value":663},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":61,"searchDepth":193,"depth":193,"links":665},[],"markdown","content:4.usage:services:4.serverSupabaseUser.md","content","4.usage/services/4.serverSupabaseUser.md","4.usage/services/4.serverSupabaseUser","md",[673,675],{"_path":41,"title":40,"description":674},"Get your Supabase user's session from serverside with the serverSupabaseUser service",{"_path":48,"title":47,"description":676},"Demonstration of using Supabase with Nuxt.",1724942526943] \ No newline at end of file diff --git a/usage/services/serversupabaseuser/index.html b/usage/services/serversupabaseuser/index.html index 53bba207..30c2c7fd 100644 --- a/usage/services/serversupabaseuser/index.html +++ b/usage/services/serversupabaseuser/index.html @@ -61,7 +61,7 @@ - + @@ -121,5 +121,5 @@ user.value = data
Made with Nuxt Studio
- - \ No newline at end of file + + \ No newline at end of file