Skip to content

Commit

Permalink
Update to latest pagefind beta!
Browse files Browse the repository at this point in the history
  • Loading branch information
zachleat committed Sep 12, 2023
1 parent b1a3131 commit ec71de4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"build-production": "npm run get-new-data && NODE_ENV=production npx @11ty/eleventy && npm run create-search-index",
"start": "npx @11ty/eleventy --serve --quiet --port=8091 --incremental",
"start-production": "NODE_ENV=production npx @11ty/eleventy --serve --quiet --port=8091",
"create-search-index": "npx pagefind --source _site --glob \"{docs,blog}/**/*.html\"",
"create-search-index": "npx pagefind --site \"_site\" --glob \"{docs,blog}/**/*.html\"",
"get-new-data": "rm -rf ./src/_data/builtwith/ && npx degit github:11ty/11ty-community/built-with-eleventy src/_data/builtwith/",
"get-new-supporters": "eleventy && node node-supporters",
"format": "prettier --write '**/*.{js,css,html,md}'"
Expand Down Expand Up @@ -70,7 +70,7 @@
"netlify-plugin-cache": "^1.0.3",
"node-fetch": "^2.6.8",
"node-retrieve-globals": "^2.0.6",
"pagefind": "^0.12.0",
"pagefind": "1.0.0-beta.5",
"prettier": "^2.8.4",
"semver": "^7.5.4",
"short-hash": "^1.0.0",
Expand Down
3 changes: 2 additions & 1 deletion src/_includes/components/search.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ class Search {

async getLibrary() {
if(!this.pagefind) {
this.pagefind = await import("/_pagefind/pagefind.js");
this.pagefind = await import("/pagefind/pagefind.js");
this.pagefind.init();
}
return this.pagefind;
}
Expand Down

0 comments on commit ec71de4

Please sign in to comment.