Skip to content

Commit

Permalink
Merge pull request #40 from ITP2023/main
Browse files Browse the repository at this point in the history
OpenSearch implementation starter
  • Loading branch information
pastelsky authored Jan 20, 2024
2 parents 7047a0a + a5e4f07 commit 8bd9caa
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
6 changes: 6 additions & 0 deletions app/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,12 @@ export const viewport: Viewport = {
function Layout({ children }) {
return (
<html className={jetbrainsMono.className}>
<link
rel="search"
type="application/opensearchdescription+xml"
href="/opensearch.xml"
title="tsdocs"
/>
<body suppressHydrationWarning={true}>{children}</body>
</html>
);
Expand Down
10 changes: 10 additions & 0 deletions public/opensearch.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<OpenSearchDescription xmlns="http://a9.com/-/spec/opensearch/1.1/" xmlns:moz="http://www.mozilla.org/2006/browser/search/">
<ShortName>tsdocs</ShortName>
<Description>show tsdocs for</Description>
<Image width="32" height="32" type="image/png">https://tsdocs.dev/favicon-32x32.png</Image>
<Tags>tsdocs</Tags>
<Url type="text/html" template="https://tsdocs.dev/search/docs/{searchTerms}"/>
<Url type="application/opensearchdescription+xml" rel="self" template="https://tsdocs.dev/opensearch.xml" />
<moz:SearchForm>https://tsdocs.dev</moz:SearchForm>
</OpenSearchDescription>

0 comments on commit 8bd9caa

Please sign in to comment.