Skip to content

Commit

Permalink
Core - Finalize SSR support, Pkg - Deploy to Cloudflare
Browse files Browse the repository at this point in the history
  • Loading branch information
smastrom committed Nov 15, 2023
1 parent fb4c191 commit 9269987
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 4 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Turn your boring fixed header into a smart one with three lines of code.

<br />

**Demo:** [Website](https://vue-use-fixed-header.netlify.app/)**Examples:** [Vue 3](https://stackblitz.com/edit/vitejs-vite-nc7ey2?file=index.html,src%2Fcomponents%2FPage.vue) - [Nuxt 3](https://stackblitz.com/edit/nuxt-starter-zbtjes?file=layouts%2Fdefault.vue)
**Demo:** [Website](https://vue-use-fixed-header.pages.dev/)**Examples:** [Vue 3](https://stackblitz.com/edit/vitejs-vite-nc7ey2?file=index.html,src%2Fcomponents%2FPage.vue) - [Nuxt 3](https://stackblitz.com/edit/nuxt-starter-zbtjes?file=layouts%2Fdefault.vue)

<br />

Expand Down
2 changes: 1 addition & 1 deletion packages/vue-use-fixed-header/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"nuxt-3",
"nuxt"
],
"homepage": "https://vue-use-fixed-header.netlify.app/",
"homepage": "https://vue-use-fixed-header.pages.dev/",
"bugs": {
"url": "https://github.com/smastrom/vue-use-fixed-header/issues"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/vue-use-fixed-header/src/useFixedHeader.ts
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,7 @@ export function useFixedHeader(
watch(
() => [unref(target), getRoot(), isReduced.value, unref(options.watch)],
([headerEl, rootEl, isReduced], _, onCleanup) => {
const shouldInit = !isReduced && !isSSR && headerEl && (rootEl || rootEl === null)
const shouldInit = !isReduced && headerEl && (rootEl || rootEl === null)

if (shouldInit) {
addResizeObserver()
Expand Down
3 changes: 3 additions & 0 deletions playground/nuxt.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,8 @@ export default defineNuxtConfig({
app: {
head: getHead(),
},
nitro: {
preset: 'cloudflare-pages',
},
css: ['@/assets/global.css'],
})
2 changes: 1 addition & 1 deletion playground/utils/head.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ export function getHead() {
{
hid: 'og:url',
property: 'og:url',
content: 'https://vue-use-fixed-header.netlify.app',
content: 'https://vue-use-fixed-header.pages.dev',
},
{
hid: 'twitter:title',
Expand Down

0 comments on commit 9269987

Please sign in to comment.