-
Notifications
You must be signed in to change notification settings - Fork 0
/
astro.config.mjs
59 lines (58 loc) · 1.53 KB
/
astro.config.mjs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
import { defineConfig } from 'astro/config'
import tailwind from '@astrojs/tailwind'
import icon from 'astro-icon'
import starlight from '@astrojs/starlight'
import react from '@astrojs/react'
// https://astro.build/config
export default defineConfig({
integrations: [
tailwind(),
icon(),
starlight({
title: 'Adam Koszary docs',
disable404Route: true
}),
react(),
(await import('astro-compress')).default({
CSS: false,
HTML: {
'html-minifier-terser': {
removeAttributeQuotes: false
}
},
CSS: true,
Image: true,
JavaScript: true,
SVG: true
})
],
server: {
proxy: {
'/wp-admin': {
target: 'https://adamkoszary.co.uk',
changeOrigin: true,
rewrite: path => path.replace(/^\/wp-admin/, '/wp-admin')
},
'/wp-content': {
target: 'https://adamkoszary.co.uk',
changeOrigin: true,
rewrite: path => path.replace(/^\/wp-content/, '/wp-content')
},
'/wp-includes': {
target: 'https://adamkoszary.co.uk',
changeOrigin: true,
rewrite: path => path.replace(/^\/wp-includes/, '/wp-includes')
},
'/wp-json': {
target: 'https://adamkoszary.co.uk',
changeOrigin: true,
rewrite: path => path.replace(/^\/wp-json/, '/wp-json')
},
'/wp-login.php': {
target: 'https://adamkoszary.co.uk',
changeOrigin: true,
rewrite: path => path.replace(/^\/wp-login\.php/, '/wp-login.php')
}
}
}
})