Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request] Not counting comments with %% #61

Closed
nomad101 opened this issue Dec 13, 2022 · 7 comments
Closed

[Feature Request] Not counting comments with %% #61

nomad101 opened this issue Dec 13, 2022 · 7 comments

Comments

@nomad101
Copy link

nomad101 commented Dec 13, 2022

Hello, thanks for updating this plugin!

I have the option 'Don't Count Comments' on, but comments in a file are still being counted if I use the %% ... %% to wrap text with. If I use <!-- ... --> it works as expected.

As far as I understand, Obsidian markdown recognises %%

Using %% in-line is neater, and doesn't interfere with reading the text compared to <!--
Would you please consider updating the plugin?

Many thanks

@lukeleppan
Copy link
Owner

Hi thank you for notifying me. It looks like I forgot to make that setting do anything. I am currently reworking metrics and how they can be stored and displayed. I will then work on sanitisation options like this one which will apply to all the metrics. I will keep you informed as progress progresses.

@ReaderGuy42
Copy link

This would be cool :)

@Gewerd-Strauss
Copy link

I've been taking a look as well so far, but I haven't found a suitable needle for this yet, unfortunately.

I figured how to remove html comments properly: /(?=<!--)([\s\S]*?)-->/g, using the modified getCharacterCount() I proposed in my comment in 48.

Maybee I'll try and find a suitable needle in the coming days, but as I don't ever used %%-comments, I might not do so anyways.

@nomad101
Copy link
Author

nomad101 commented Feb 9, 2023

Thanks for looking into this. I appreciate you have limited time. (If I could code, I'd try myself).

If its any help, the dataview plugin doesn't count words wrapped with %%. (But otherwise it's overkill).

@lukeleppan
Copy link
Owner

Not counting comments, has been thrown back in.

@ReaderGuy42
Copy link

Great, thank you! Quick question, what does the !!! indicate when you hover over the status bar?

@nicolascoffman
Copy link

I see this has been marked as completed, but I'm having issues with %% still being counted. Should I be looking for a different fix?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants