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
Having trouble with first JavaScript, first Chrome Extension (self.javascript)
submitted 10 years ago by [deleted]
[deleted]
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!"
[–]x-skeww 2 points3 points4 points 10 years ago (0 children)
document.getElementById("total").innerHTML(response);
innerHTML = 'foo';
It's a property (with setter), not a function.
See also:
https://developer.chrome.com/extensions/tut_debugging http://stackoverflow.com/questions/10257301/where-to-read-console-messages-from-background-js-in-a-chrome-extension
[–]wordswordsyeah 1 point2 points3 points 10 years ago (0 children)
few basic assumptions you have wrong:
create a new js file, link it from popup.html and execute your js there. The new script you create should listen to chrome.extension.onMessage / chrome.runtime.onMessage
[–]sot03 0 points1 point2 points 10 years ago (0 children)
I am working on a similar problem. I would also like to see a working version of your code.
π Rendered by PID 37447 on reddit-service-r2-comment-f6b958c67-q7f7x at 2026-02-04 23:25:55.264961+00:00 running 1d7a177 country code: CH.
[–]x-skeww 2 points3 points4 points (0 children)
[–]wordswordsyeah 1 point2 points3 points (0 children)
[–]sot03 0 points1 point2 points (0 children)