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

i need tutorial about content-script on this repo #195

Open
RixkiSSS opened this issue Dec 8, 2023 · 3 comments
Open

i need tutorial about content-script on this repo #195

RixkiSSS opened this issue Dec 8, 2023 · 3 comments

Comments

@RixkiSSS
Copy link

RixkiSSS commented Dec 8, 2023

recently just try this repo for creating random extension for chrome (just learn new thing)

while some page I already tried, like popup, newtab, background script, but just look up the content-script that use original console log is not even running (checked on edge dev tool), the console log not even write anything...

what I already do:
npm i
npm run build <--- to build data
load unpackaged extension on my edge
// i dont get any console log

npm run build <-- i build again to make sure
npm run start <-- this even build with hot reload
load package again
// still not getting console log

i've already check, the code is not hot reloaded on webpack config
then I tried to reload package, and remove then re-add the package to browser but still no luck

this extension I intend to use on a production website (thru https, should i change the config use https ?), though I don't have any experience with webpack, then, just final one... can you explain me how the content-script can executed as expected ?

@RixkiSSS
Copy link
Author

RixkiSSS commented Dec 8, 2023

hmm... i think because I still learning, the code is able to run now... because it need to run when not using npm run start

but let me change the question then:
why node module like web3 or else is cause errors, i think other module can cause error to extension... teach me how to add module so i able to create better extension...

@BlakeHastings
Copy link

I ran into a similar issue and found an error in the console suggesting the issue was caused by socketJS opening an unsafe connection on a page that uses SSL. I flipped https to true in the webserver.js file in the utils folder and everything seems to be working now. Perhaps give that a try if you are still stuck with this issue.

@felixswang
Copy link

Thanks @BlakeHastings! Worked for me.

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

3 participants