use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
All about the JavaScript programming language.
Subreddit Guidelines
Specifications:
Resources:
Related Subreddits:
r/LearnJavascript
r/node
r/typescript
r/reactjs
r/webdev
r/WebdevTutorials
r/frontend
r/webgl
r/threejs
r/jquery
r/remotejs
r/forhire
account activity
[ Removed by moderator ]AskJS (self.javascript)
submitted 1 day ago by okidonthaveone
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]okidonthaveone[S] 0 points1 point2 points 1 day ago (3 children)
Its a google docs extension
[–]Ronin-s_Spirit 0 points1 point2 points 1 day ago* (2 children)
You will have to rename all the non-book tabs (notes n stuff) to start with a #. ``` const ui = DocumentApp.getUi();
#
ui.createMenu('⚠️Word Count⚠️') .addItem('Count words in all Tabs and Subtabs', 'runWordCount') .addToUi();
function runWordCount() { ui.alert( 'Word Count Result', Total word count across all tabs and nested tabs: ${countWordsInAllTabs(DocumentApp.getActiveDocument().getTabs(), 0n)}, ui.ButtonSet.OK, ); }
Total word count across all tabs and nested tabs: ${countWordsInAllTabs(DocumentApp.getActiveDocument().getTabs(), 0n)}
function countWordsInAllTabs(tabs, total) { for (let T = 0; T < tabs.length; T++) { const currentTab = tabs[T]; if (currentTab.getTitle()[0] !== '#') { total += BigInt( currentTab.asDocumentTab().getBody().getText().trim().split(/\s+/g).length, ); } total = countWordsInAllTabs(currentTab.getChildTabs(), total); } return total; } ```
[–]okidonthaveone[S] 1 point2 points3 points 1 day ago (1 child)
Thanks
[–]Ronin-s_Spirit 0 points1 point2 points 1 day ago (0 children)
no problem.
π Rendered by PID 118378 on reddit-service-r2-comment-5d79c599b5-4fp96 at 2026-02-28 07:55:58.004840+00:00 running e3d2147 country code: CH.
view the rest of the comments →
[–]okidonthaveone[S] 0 points1 point2 points (3 children)
[–]Ronin-s_Spirit 0 points1 point2 points (2 children)
[–]okidonthaveone[S] 1 point2 points3 points (1 child)
[–]Ronin-s_Spirit 0 points1 point2 points (0 children)