There’s a github file with a cool slot machine game I want to use in my bubble app. I feel like I’ve confirmed that HTML, javascript and CSS can all be used in bubble but what about these other ones below like dockerfile? Will this whole mix of codes from the screenshot below be possible to implement on bubble?
My hope is to just copy all these github files into the root directory on my app and then use the HTML element to house it all, with the CSS and javascript(and hopefully that other stuff) getting referenced by it from the root directory. Is that feasible? just using the html element like the index.html and having bubble render a slot machine?
Sorry if this is word salad I’m not at all familiar with coding and just trying to find a way to get a visually appealing if still simple game into bubble.
haha nice its you! yes I had read that thread, thank you for it. That’s why I was sure I could use those 3 and also where I got the idea to house everything in the html element.
The comment about needing some HTML knowledge to put it all together sent me off on a little journey lol. That’s where this question comes from. I see in the index.html they have the css referenced already but not the javascript. Can I put all the files from github into the root directory on bubble and just have the script tags referencing those js files? Or do I need to just put all the relevant javascript into the html element directly?
It all seems vaguely doable but I’m so unqualified to be sure, may just be misunderstanding a lot
Substitute the line <link rel="stylesheet" href="./style.css"> with the content of the style.css file (add <style></style> tags around it)
I followed this to the letter and it made everything blank. I hadn’t added the js yet but still, the unaltered index.html code was showing some elements previously.
yeah they seem to be the same as I got by digging through the download. I appreciate you trying to help I think I just need to study HTML more to be able to put this puzzle back together. A lot of the index.html isn’t referencing the other files directly its referencing hosting URLs and I’m just in over my head with the edits.
2 closing questions if you could:
Can I upload css and js files to the root directory of a bubble app so the HTML element can reference them? or should I always aim to put the full code right in the html?
in your experience does that code look like it should work in bubble or am I wasting my time?
Thanks so much for the advice I really appreciate this forum
In the link I gave, index.html has links to css and js files.
Yes, you can.
It looks like more work than usual because they generate the resulting html+css+js by using a framework (webpack), which makes the code less readable. Possible but too much work.
That’s ok. But make sure you update the content of the files (image URLs). First upload the images, then update the image paths in JS and CSS files in your local to see if they work in your local. Then, you can upload the JS and CSS file. Try again in your local by referring to the uploaded files in the HTML. Finally, create the HTML element with the file content in Bubble.
After you download these files to your computer (local), it works in your computer by just opening index.html. then, you do what I said in my previous reply and open index.html in your computer again after the changes. And continue on.
so I’ll be using my local system to test if the files work and get the HTML file edited right? then repeat the process with the bubble root directory in place of local?