Thank you for your submission, an automated scan of your plugin code's revealed the following issues:

:Please remove the `main.js` file from the repo and add it to your .gitignore. Compiled release files shouldn't get mixed with source code in your commits and should go to the releases files instead.

[[1](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L386)][[2](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L407)][[3](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/view.ts#L360)][[4](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/main.ts#L639)][[5](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/main.ts#L662)]:You should change all instances of `var` to either `const` or `let`. `var` has function-level scope, so it can easily lead to bugs if you're not careful. Here's a pretty good guide with examples of why not to use `var`: [why `var` is obsolete](https://javascript.plainenglish.io/4-reasons-why-var-is-considered-obsolete-in-modern-javascript-a30296b5f08f)

[[1](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/view.ts#L320)][[2](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/view.ts#L327)]:You should avoid assigning styles via JavaScript or in HTML and instead move all these styles into CSS so that they are more easily adaptable by themes and snippets.


[[1](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/view.ts#L332)]:Using `innerHTML`, `outerHTML` or similar API's is a security risk. Instead, use the DOM API or the Obsidian helper functions: <https://docs.obsidian.md/Plugins/User+interface/HTML+elements>

[[1](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/main.ts#L685)][[2](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/main.ts#L686)]:Do not detach leaves with your custom view in `onunload`, this is an antipattern, see: <https://docs.obsidian.md/Plugins/Releasing/Plugin+guidelines#Don't+detach+leaves+in+%60onunload%60>

[[1](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L105)][[2](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L127)][[3](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L135)][[4](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L152)][[5](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L188)][[6](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L209)][[7](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L215)][[8](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L224)][[9](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L249)][[10](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L251)][[11](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L254)][[12](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L264)][[13](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L265)][[14](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L268)][[15](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L274)][[16](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L275)][[17](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L290)][[18](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L304)][[19](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L310)][[20](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L321)][[21](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L322)][[22](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L334)][[23](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L419)][[24](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L423)][[25](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L427)][[26](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L435)][[27](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L459)][[28](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/utils.ts#L461)][[29](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/view_utils.ts#L38)][[30](https://github.com/MM-GO/UseSemaLogic/blob/b00c3ac13c3c3a9e5879009fffbfdac0c4b811b0/src/view_utils.ts#L43)] and more:You should consider limiting the number of `console.log`s in your code, to not pollute the dev console.



---



Do <b>NOT</b> open a new PR for re-validation. If you think some of these results are incorrect, please include `/skip` in your comment and the reason why you think the results are incorrect.
Once you have pushed all of the required changes, the bot will reevaluate your PR within 4 hours.