Skip to content

Commit

Permalink
feat!: replace algolia with local search (#1488)
Browse files Browse the repository at this point in the history
* feat!: replace algolia with local search

* fix: type module

* fix: only change config extension to .mts
  • Loading branch information
g1eny0ung authored Aug 9, 2023
1 parent d5c144c commit 8e6f954
Show file tree
Hide file tree
Showing 3 changed files with 932 additions and 376 deletions.
33 changes: 13 additions & 20 deletions docs/.vitepress/config.ts → docs/.vitepress/config.mts
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,12 @@ export default defineConfig({

socialLinks: [
{ icon: 'github', link: 'https://github.com/intlify/vue-i18n-next' },
{ icon: 'twitter', link: 'https://twitter.com/intlify' },
{ icon: 'twitter', link: 'https://twitter.com/intlify' }
],

editLink: {
pattern: 'https://github.com/intlify/vue-i18n-next/edit/master/docs/:path',
pattern:
'https://github.com/intlify/vue-i18n-next/edit/master/docs/:path',
text: 'Edit this page on GitHub'
},

Expand All @@ -33,19 +34,11 @@ export default defineConfig({

carbonAds: {
code: 'CWYDVK37',
placement: 'vue-i18nintlifydev',
placement: 'vue-i18nintlifydev'
},

// TODO: we need to upgrade?
// @ts-ignore
algolia: {
appId: 'BH4D9OD16A',
apiKey: '3a9e93ba1069de0ece2ae100daf8f6ea',
indexName: 'vue-i18n',
searchParameters : {
facetFilters: ['language:en-US']
},
// algoliaOptions: { facetFilters: ['tags:guide,api'] }
search: {
provider: 'local',
},

nav: nav(),
Expand Down Expand Up @@ -78,7 +71,7 @@ function nav() {
},
{
text: 'v9.x',
items: [{ text: 'v8.x', link: 'https://kazupon.github.io/vue-i18n/' }],
items: [{ text: 'v8.x', link: 'https://kazupon.github.io/vue-i18n/' }]
},
{
text: 'Changelog',
Expand All @@ -99,7 +92,7 @@ function sidebarGuide() {
},
{
text: 'Getting Started',
link: '/guide/',
link: '/guide/'
},
{
text: 'Installation',
Expand All @@ -117,7 +110,7 @@ function sidebarGuide() {
items: [
{
text: 'Message Format Syntax',
link: '/guide/essentials/syntax',
link: '/guide/essentials/syntax'
},
{
text: 'Pluralization',
Expand Down Expand Up @@ -171,19 +164,19 @@ function sidebarGuide() {
},
{
text: 'Composition API',
link: '/guide/advanced/composition',
link: '/guide/advanced/composition'
},
{
text: 'TypeScript Support',
link: '/guide/advanced/typescript',
link: '/guide/advanced/typescript'
},
{
text: 'Web components',
link: '/guide/advanced/wc',
link: '/guide/advanced/wc'
},
{
text: 'Optimization',
link: '/guide/advanced/optimization',
link: '/guide/advanced/optimization'
}
]
},
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@
"trash-cli": "^5.0.0",
"tslib": "^2.5.3",
"typescript": "^5.1.3",
"vitepress": "^1.0.0-alpha.76",
"vitepress": "1.0.0-rc.4",
"vitest": "^0.31.1",
"vue": "3.3.4",
"vue-i18n": "workspace:*"
Expand Down
Loading

0 comments on commit 8e6f954

Please sign in to comment.