Skip to content

Commit

Permalink
feat: move search from pagefind to algolia
Browse files Browse the repository at this point in the history
  • Loading branch information
mehalter committed Oct 16, 2023
1 parent 654b95c commit a09660e
Show file tree
Hide file tree
Showing 5 changed files with 379 additions and 1 deletion.
17 changes: 17 additions & 0 deletions .prettierrc.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
/** @type {import("prettier").Config} */
const config = {
plugins: [
"prettier-plugin-astro",
"prettier-plugin-tailwindcss", // MUST come last
],
overrides: [
{
files: "*.astro",
options: {
parser: "astro",
},
},
],
};

export default config;
11 changes: 11 additions & 0 deletions astro.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ export default defineConfig({
site: "https://docs.astronvim.com",
defaultLocale: "root",
locales,
components: {
Search: "./src/components/Search.astro",
},
integrations: [
starlight({
title: "AstroNvim Docs",
Expand Down Expand Up @@ -95,6 +98,14 @@ export default defineConfig({
href: "/manifest.webmanifest",
},
},
{
tag: "link",
attrs: {
rel: "preconnect",
href: "https://JXZNTZ86UN-dsn.algolia.net",
crossorigin: true,
},
},
{
tag: "script",
attrs: {
Expand Down
7 changes: 6 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,18 @@
"@astrojs/starlight": "^0.11.1",
"@astrojs/starlight-tailwind": "^2.0.0",
"@astrojs/tailwind": "^5.0.2",
"@docsearch/css": "^3.5.2",
"@docsearch/js": "^3.5.2",
"astro": "^3.3.0",
"sharp": "^0.32.6",
"tailwindcss": "^3.3.3"
},
"devDependencies": {
"@netlify/plugin-lighthouse": "^5.0.0",
"netlify-plugin-checklinks": "^4.1.1",
"netlify-plugin-submit-sitemap": "^0.4.0"
"netlify-plugin-submit-sitemap": "^0.4.0",
"prettier": "^3.0.3",
"prettier-plugin-astro": "^0.12.0",
"prettier-plugin-tailwindcss": "^0.5.6"
}
}
Loading

0 comments on commit a09660e

Please sign in to comment.