Improve the word count Tag helper to include images.
See original GitHub issueThe <post-read-time />
TagHelper is used to calculate the number of minutes we guess it will take to read the article. This calculation uses a simple arithmetic around the number of words Post.Content.
There is a hypothesis that suggests we should also include 30 seconds per image in the post.
The task here is to find the number of images in Post.Content and add it to the number of minutes calculated on line 24 in the following TagHelper:
\source\DasBlog.Web.UI\TagHelpers\Post\PostReadTimeTagHelper.cs
Issue Analytics
- State:
- Created 2 years ago
- Comments:5 (5 by maintainers)
Top Results From Across the Web
Pick path in Tag Helper attribute
Lets say I want to create a custom ImageTagHelper, which loads the image name from a database field and generates an IMG. As...
Read more >Solved: Using power automate to tag images uploaded into s...
Hello everyone. I already have the AI builder models. And need to build a flow that tags images uploaded into sharepoint using the...
Read more >Kentico Xperience 13 Beta 3 - Page Builder Tag Helpers in ...
The attributes of the Tag Helper element are being assigned C# expressions, the expressions are longer in character count, and there is more ......
Read more >Handlebars Helpers Reference
Handlebars Helpers Reference. This article is a reference for Stencil supported Handlebars (opens in a new tab) helpers. It includes custom helpers ......
Read more >Advanced configuration
helper_image, (Advanced) The default helper image used to clone repositories and upload artifacts. helper_image_flavor, Sets the helper image flavor ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Hey @poppastring
Thank you very much for clarifying! I believe I got into a possible solution.
I will do a PR for your review.
Thanks @poppastring!!
As I said, I am pretty new in C#, so I think I might have a solution. But I would like to check with you first, if I am in the right path, if possible: var images = dasBlogSettings.Post.Content.HtmlTagContext(img).Count(); var imgMinutes = images*30/60;
Thank you in advance, Thais