Skip to content

Commit

Permalink
Remove most Blackfriday references
Browse files Browse the repository at this point in the history
  • Loading branch information
bep committed May 31, 2022
1 parent bfbe5aa commit 82cf083
Show file tree
Hide file tree
Showing 6 changed files with 2 additions and 42 deletions.
1 change: 0 additions & 1 deletion content/en/content-management/cross-references.md
Expand Up @@ -126,4 +126,3 @@ refLinksNotFoundURL
[lists]: /templates/lists/
[output formats]: /templates/output-formats/
[shortcode]: /content-management/shortcodes/
[bfext]: /content-management/formats/#blackfriday-extensions
3 changes: 0 additions & 3 deletions content/en/content-management/formats.md
Expand Up @@ -29,7 +29,6 @@ The current list of content formats in Hugo:
| Name | Markup identifiers | Comment |
| ------------- | ------------- |-------------|
| Goldmark | md, markdown, goldmark |Note that you can set the default handler of `md` and `markdown` to something else, see [Configure Markup](/getting-started/configuration-markup/).{{< new-in "0.60.0" >}} |
| Blackfriday | blackfriday |Blackfriday will eventually be deprecated.|
|Emacs Org-Mode|org|See [go-org](https://github.com/niklasfasching/go-org).|
|AsciiDoc|asciidocext, adoc, ad|Needs [Asciidoctor][ascii] installed.|
|RST|rst|Needs [RST](https://docutils.sourceforge.io/rst.html) installed.|
Expand Down Expand Up @@ -128,8 +127,6 @@ Markdown syntax is simple enough to learn in a single sitting. The following are

[`emojify` function]: /functions/emojify/
[ascii]: https://asciidoctor.org/
[bfconfig]: /getting-started/configuration/#configuring-blackfriday-rendering
[blackfriday]: https://github.com/russross/blackfriday
[config]: /getting-started/configuration/
[developer tools]: /tools/
[emojis]: https://www.webpagefx.com/tools/emoji-cheat-sheet/
Expand Down
25 changes: 0 additions & 25 deletions content/en/content-management/multilingual.md
Expand Up @@ -140,31 +140,6 @@ Press Ctrl+C to stop

Live reload and `--navigateToChanged` between the servers work as expected.

### Taxonomies and Blackfriday

Taxonomies and [Blackfriday configuration][config] can also be set per language:

{{< code-toggle file="config" >}}
[Taxonomies]
tag = "tags"

[blackfriday]
angledQuotes = true
hrefTargetBlank = true

[languages]
[languages.en]
weight = 1
title = "English"
[languages.en.blackfriday]
angledQuotes = false

[languages.fr]
weight = 2
title = "Français"
[languages.fr.Taxonomies]
plaque = "plaques"
{{</ code-toggle >}}

## Translate Your Content

Expand Down
2 changes: 1 addition & 1 deletion content/en/functions/anchorize.md
Expand Up @@ -13,7 +13,7 @@ workson: []
relatedfuncs: [humanize]
---

If [Goldmark](https://gohugo.io/getting-started/configuration-markup#goldmark) is set as `defaultMarkdownHandler`, the sanitizing logic adheres to the setting [`markup.goldmark.parser.autoHeadingIDType`](https://gohugo.io/getting-started/configuration-markup#goldmark). If [Blackfriday](https://gohugo.io/getting-started/configuration-markup#blackfriday) is set as `defaultMarkdownHandler`, this template function uses the [`SanitizedAnchorName` logic from Blackfriday](https://github.com/russross/blackfriday#sanitized-anchor-names) (the same applies when `markup.goldmark.parser.autoHeadingIDType` is set to `blackfriday`).
If [Goldmark](https://gohugo.io/getting-started/configuration-markup#goldmark) is set as `defaultMarkdownHandler`, the sanitizing logic adheres to the setting [`markup.goldmark.parser.autoHeadingIDType`](https://gohugo.io/getting-started/configuration-markup#goldmark).

Since the `defaultMarkdownHandler` and this template function use the same sanitizing logic, you can use the latter to determine the ID of a header for linking with anchor tags.

Expand Down
10 changes: 1 addition & 9 deletions content/en/getting-started/configuration-markup.md
Expand Up @@ -77,16 +77,8 @@ Note that attributes in [code fences](/content-management/syntax-highlighting/#h
````

autoHeadingIDType ("github") {{< new-in "0.62.2" >}}
: The strategy used for creating auto IDs (anchor names). Available types are `github`, `github-ascii` and `blackfriday`. `github` produces GitHub-compatible IDs, `github-ascii` will drop any non-Ascii characters after accent normalization, and `blackfriday` will make the IDs work as with [Blackfriday](#blackfriday), the default Markdown engine before Hugo 0.60. Note that if Goldmark is your default Markdown engine, this is also the strategy used in the [anchorize](/functions/anchorize/) template func.
: The strategy used for creating auto IDs (anchor names). Available types are `github`, `github-ascii` and `blackfriday`. `github` produces GitHub-compatible IDs, `github-ascii` will drop any non-Ascii characters after accent normalization, and `blackfriday` will make the IDs comptible with [Blackfriday](#blackfriday), the default Markdown engine before Hugo 0.60. Note that if Goldmark is your default Markdown engine, this is also the strategy used in the [anchorize](/functions/anchorize/) template func.

### Blackfriday


[Blackfriday](https://github.com/russross/blackfriday) was Hugo's default Markdown rendering engine, now replaced with Goldmark. But you can still use it: Just set `defaultMarkdownHandler` to `blackfriday` in your top level `markup` config.

This is the default config:

{{< code-toggle config="markup.blackFriday" />}}

### Highlight

Expand Down
3 changes: 0 additions & 3 deletions content/en/getting-started/configuration.md
Expand Up @@ -121,9 +121,6 @@ The directory where Hugo finds asset files used in [Hugo Pipes](/hugo-pipes/). {
### baseURL
Hostname (and path) to the root, e.g. https://bep.is/

### blackfriday
See [Configure Blackfriday](/getting-started/configuration-markup#blackfriday)

### build
See [Configure Build](#configure-build)

Expand Down

0 comments on commit 82cf083

Please sign in to comment.