how do i call js file from html file?

i tried to call js script from local to html file, but it is not loaded why?
No description
No description
6 Replies
Cyb3r-Jak3
Cyb3r-Jak36d ago
Yeah that isn't going to work. HTML can't import javascript, it will just tell to browser to make a requests to get the javascript file. This seems more like you want Pages than workers
sakty
saktyOP6d ago
what do you mean by page?
Cyb3r-Jak3
Cyb3r-Jak36d ago
Cloudflare's website hosting: https://developers.cloudflare.com/pages/
Cloudflare Docs
Cloudflare Pages documentation · Cloudflare Pages docs
Deploy your Pages project by connecting to your Git provider, uploading prebuilt assets directly to Pages with Direct Upload or using C3 from the command line.
sakty
saktyOP6d ago
what's the difference with worker
Cyb3r-Jak3
Cyb3r-Jak36d ago
Pages is built to handle websites
sakty
saktyOP6d ago
ah so it can import the function in html file?

Did you find this page helpful?