This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { useUrlSearchParams as useVueUseUrlSearchParams } from '@vueuse/core' | |
const paramsInstances = new Map<string, ReturnType<typeof useVueUseUrlSearchParams>>() | |
export function useRouteQuery<T extends Record<string, any> = Record<string, any>>(key?: string) { | |
if (import.meta.server) { | |
return useRoute().query as T | |
} | |
const finalKey = key ?? window.location.pathname |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module.exports = { | |
pages: { | |
pageA: 'src/pageA.js', | |
pageB: 'src/pageB.js', | |
pageC: 'src/pageC.js', | |
}, | |
chainWebpack: config => { | |
const options = module.exports | |
const pages = options.pages |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script lang="ts"> | |
const iframes = new Map<string, { iframe: HTMLIFrameElement, src: string }>() | |
</script> | |
<script lang="ts" setup> | |
import { useAttrs, ref, shallowRef, watchEffect, onMounted, onBeforeUnmount } from 'vue' | |
import { useElementBounding } from '@vueuse/core' | |
defineOptions({ | |
inheritAttrs: false, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#tabbrowser-tabs { | |
visibility: collapse; | |
} | |
#navigator-toolbox { | |
display: flex; | |
flex-flow: row wrap; | |
} | |
#titlebar { | |
order: 1; | |
max-width: 44px; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"settings": { | |
"nativeScrollbars": true, | |
"nativeScrollbarsThin": true, | |
"nativeScrollbarsLeft": false, | |
"selWinScreenshots": true, | |
"updateSidebarTitle": true, | |
"markWindow": false, | |
"markWindowPreface": "[Sidebery] ", | |
"ctxMenuNative": true, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#tabbrowser-tabs { | |
visibility: collapse; | |
} | |
#navigator-toolbox { | |
display: flex; | |
flex-flow: row wrap; | |
} | |
#titlebar { | |
order: 1; | |
max-width: 146px; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export function useEagerComputed() { | |
const properties = [] | |
function eagerComputed(definitions) { | |
const computedProps = {} | |
for (const key in definitions) { | |
const effect = definitions[key] | |
properties.push({ key, effect }) | |
computedProps[key] = function () { | |
return this.$data[key] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
import { ref } from '@vue/composition-api' | |
import { onScrollBottom } from '@/scroll' | |
export default { | |
setup () { | |
function loadMore () { | |
// ... | |
} | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
=\s\(\) => import\([\s\n]*(\/\*.*?\*\/[\s\n]*)?'.*?\.vue'[\s\n]*\) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { updateLobby, subscribeToLobby } from './lobby' | |
// ... | |
updateLobby('some-id', { title: 'Foo' }) | |
subscribeToLobby('xxx-xxx-xxx') |
NewerOlder