Skip to content

Commit eb37b25

Browse files
committed
typo in words-sum shortcode
1 parent aac5541 commit eb37b25

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

_extensions/wordcount/wordcount.lua

+1-1
Original file line numberDiff line numberDiff line change
@@ -271,6 +271,6 @@ function Pandoc(el)
271271
print()
272272
-- modify meta data for words.lua
273273
el.meta = set_meta(el.meta)
274-
274+
275275
return el
276276
end

_extensions/wordcount/words.lua

+3-3
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,9 @@ return {
3737
if nargs == 0 then
3838
return pandoc.Str(0)
3939
end
40-
print(args)
41-
local arg = args[1][1].text
42-
print(arg)
40+
--print(args)
41+
local arg = args[1]
42+
--print(arg)
4343
if arg:match("body") then
4444
count = count + as_num(meta.wordcount_body_words, "wordcount_total_words")
4545
end

template.qmd

+1-1
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ Word counts can be directly included in your document with shortcodes, like so:[
7474

7575
- Use `{{{< words-note >}}}` to include a count of the words in the notes: **{{< words-note >}} words**. You can also reliably count words in the footnotes which would have previously been included in whichever section they were.[^2]
7676

77-
- Use `{{{< words-sum ARG >}}}` where `ARG` is some concatenation of the four countable areas: `body`, `ref`, `append`, and `note`. For example, `{{{< words-sum body-note >}}}` includes a count of the words in the body and notes (**{{{< words-sum body-note >}}} words**); `{{{< words-sum ref-append >}}}` includes a count of the words in the references and appendix (**{{{< words-sum ref-append >}}} words**)
77+
- Use `{{{< words-sum ARG >}}}` where `ARG` is some concatenation of the four countable areas: `body`, `ref`, `append`, and `note`. For example, `{{{< words-sum body-note >}}}` includes a count of the words in the body and notes (**{{< words-sum body-note >}} words**); `{{{< words-sum ref-append >}}}` includes a count of the words in the references and appendix (**{{< words-sum ref-append >}} words**)
7878

7979
[^1]: **NOTE** shortcodes `{{{< words-body >}}}`, `{{{< words-ref >}}}`, `{{{< words-append >}}}`, and `{{{< words-note >}}}` do not overlap their counts.
8080

0 commit comments

Comments
 (0)