Skip to content

Commit 5ccea1a

Browse files
committed
docs: disable Carbon and BuySell ads
1 parent 2ccfdf1 commit 5ccea1a

3 files changed

Lines changed: 3 additions & 36 deletions

File tree

docs/.vuepress/client.ts

Lines changed: 1 addition & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -29,27 +29,12 @@ export default defineClientConfig({
2929
}
3030
}
3131

32-
router.addRoute('/', {
33-
path: '/ads.txt',
34-
redirect: '',
35-
beforeEnter: () => {
36-
window.location.replace('https://cdn4.buysellads.net/ads.txt')
37-
}
38-
})
39-
40-
router.addRoute('/', {
41-
path: '/app-ads.txt',
42-
redirect: '',
43-
beforeEnter: () => {
44-
window.location.replace('https://cdn4.buysellads.net/app-ads.txt')
45-
}
46-
})
4732
}
4833
})
4934

5035
declare global {
5136
const __VUEPRESS_SSR__: boolean
52-
const _bsa: any
37+
5338

5439
interface Window {
5540
MonacoEnvironment?: import('monaco-editor').Environment | undefined

docs/.vuepress/config.ts

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -178,17 +178,7 @@ function getHead(): HeadConfig[] {
178178
['meta', { name: 'twitter:image', content: 'https://fusejs.io/assets/img/logo.png' }]
179179
]
180180

181-
const scripts: [HeadTagNonEmpty, HeadAttrsConfig, string][] = [
182-
`
183-
(function(){
184-
var bsa_optimize=document.createElement('script');
185-
bsa_optimize.type='text/javascript';
186-
bsa_optimize.async=true;
187-
bsa_optimize.src='https://cdn4.buysellads.net/pub/fusejs.js?'+(new Date()-new Date()%600000);
188-
(document.getElementsByTagName('head')[0]||document.getElementsByTagName('body')[0]).appendChild(bsa_optimize);
189-
})();
190-
`
191-
].map<[HeadTagNonEmpty, HeadAttrsConfig, string]>((content) => [
181+
const scripts: [HeadTagNonEmpty, HeadAttrsConfig, string][] = ([] as string[]).map<[HeadTagNonEmpty, HeadAttrsConfig, string]>((content) => [
192182
'script',
193183
{},
194184
content

docs/.vuepress/layouts/Layout.vue

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,7 @@
11
<template>
2-
<ParentLayout>
3-
<template #sidebar-top>
4-
<Suspense>
5-
<CarbonAds />
6-
<template #fallback>Loading ads...</template>
7-
</Suspense>
8-
</template>
9-
</ParentLayout>
2+
<ParentLayout />
103
</template>
114

125
<script setup>
136
import ParentLayout from '@vuepress/theme-default/layouts/Layout.vue'
14-
import CarbonAds from './components/CarbonAds.vue'
157
</script>

0 commit comments

Comments
 (0)