Hi Alex,
Thank you for looking into this further to find out if there are any behaviour differences. I appreciate that. ??
Regarding whether you need to add the <script> </script> tags in your JS code block, the answer is yes.
When you change the code block editor language to JS for example, the editor will now be set to check for JavaScript errors. The thing is, the <script> tag is a HTML tag and will show an ‘ACE editor’ JS error when the editor is set to JS. Changing the language to HTML, you will see the error go away. It is a catch 22, so if you don’t want to add the <script> tag and instead write JS code straight into the code block, then you would need to create a code file instead.
You can click Master near the code block title, and then create a new code file. Set this code file as JS, which will save the file on your server as a .js file.
Then when you assign a page or post or whatever, CJT will load the code as a code file instead. This would be quicker then reading your JS code from a code block, which is stored in the database.
Search for Code Files in this webpage for more clarity.
https://css-javascript-toolbox.com/features/
I hope this makes sense.
Regards,
Damian Baker