Skip to content

Commit

Permalink
fix issue with apostrophes in titles
Browse files Browse the repository at this point in the history
  • Loading branch information
amzn-tomjoht committed Nov 2, 2017
1 parent 090f067 commit 8a0f37d
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 7 deletions.
2 changes: 1 addition & 1 deletion _includes/topnav.html
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
searchInput: document.getElementById('search-input'),
resultsContainer: document.getElementById('results-container'),
dataSource: '{{ "search.json" }}',
searchResultTemplate: '<li><a href="{url}" title="{{page.title | replace: "\'", "\"}}">{title}</a></li>',
searchResultTemplate: '<li><a href="{url}" title="{{page.title | escape }}">{title}</a></li>',
noResultsText: '{{site.data.strings.search_no_results_text}}',
limit: 10,
fuzzy: true,
Expand Down
2 changes: 1 addition & 1 deletion index.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
title: Getting started with the Documentation Theme for Jekyll
title: "Getting started with the Documentation's Theme for Jekyll"
keywords: sample homepage
tags: [getting_started]
sidebar: mydoc_sidebar
Expand Down
2 changes: 1 addition & 1 deletion js/jekyll-search.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions pages/mydoc/mydoc_about.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
title: About the theme author
title: About the theme's author
keywords: documentation theme, jekyll, technical writers, help authoring tools, hat replacements
last_updated: July 3, 2016
tags: [getting_started]
Expand All @@ -9,7 +9,7 @@ permalink: mydoc_about.html
folder: mydoc
---

My name is Tom Johnson, and I'm a technical writer, blogger, and podcaster based in San Jose, California. My blog is here: [http://idratherbewriting.com](http://idratherbewriting.com). I write several posts there a week. See [my blog's about page](http://idratherbewriting.com/aboutme/) for more details about me.
My name is Tom Johnson, and I'm a technical writer, blogger, and podcaster based in San Jose, California. For more details, see my [technical writing blog](http://idratherbewriting.com) and my [course on API documentation](http://idratherbewriting.com/learnapidoc/). See [my blog's about page](http://idratherbewriting.com/aboutme/) for more details about me.

I have used this theme and variations of it for various documentation projects. This theme has undergone several major iterations, and now it's fairly stable and full of all the features that I need. You are welcome to use it for your documentation projects for free.

Expand Down
5 changes: 3 additions & 2 deletions pages/mydoc/mydoc_search_configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@ If this happens, go directly to the search.json file in your browser, and then c
The search.json file already tries to strip out content that would otherwise make the JSON invalid.

## Including the body field in search
I've found that include the `body` field in the search creates too many problems, and so I've removed `body` from the search. You can see the results of including the `body` by adding this along with the other fields in search.json:

I've found that including the `body` field in the search creates too many problems, and so I've removed `body` from the search. You can see the results of including the `body` by adding this along with the other fields in search.json:

{% raw %}
```json
Expand Down Expand Up @@ -114,6 +115,6 @@ Where you see `{url}` and `{title}`, the search is retrieving the values for the
## More robust search
For more robust search, consider integrating either [Algolia](http://algolia.com) or [Swifttype](http://swiftype.com).
Overall, the built-in search only works for small documentation projects. If you have more robust search needs, consider integrating [Google Custom Search](https://cse.google.com/cse/), [Algolia](http://algolia.com), or [Swifttype](http://swiftype.com).
{% include links.html %}

0 comments on commit 8a0f37d

Please sign in to comment.