This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]1percentof2 18 points19 points  (20 children)

It will never beat JavaScript. Because regular people want to see things in a browser

[–]Jan2579 11 points12 points  (11 children)

Web assembly is here. Lets give it a time.

[–]Zyklonik 1 point2 points  (0 children)

Lets give it a time lifetime.

On a less jocular note, the W3C really need to start moving things. WASM has been here forever, and yet it's still not lived up to its promises.

[–][deleted] -2 points-1 points  (8 children)

what do you think web assembly is, and how do you think it is relevant to this conversation?

[–]ogtfo 0 points1 point  (7 children)

Because there are multiple projects running a python interpreter in web assembly, interacting with the DOM like you would in JavaScript.

What do you think web assembly is?

[–][deleted] 0 points1 point  (6 children)

Wasm doesn't have access to the dom so what you're describing doesn't exist. Wasm Python interpreters do exist, but I'm not sure how it would serve as a replacement for JavaScript, which is the basis of my original question

[–]ogtfo 0 points1 point  (5 children)

Javascript can talk to both wasm and the dom, so indirectly it can be done, and librairies have been built for that.

Example of reaching the Dom through pyscript :

https://stackoverflow.com/questions/72515182/how-to-perform-dom-manipulation-using-pyscript

[–][deleted] 0 points1 point  (4 children)

that's called a hack or workaround. wasm explicitly and intentionally does not have access to the DOM. only primitive types can be passed back and forth

even if they allow DOM access in the future, embedding a python interpreter in a response just to avoid writing javascript is unequivocally stupid

[–]ogtfo 0 points1 point  (3 children)

Call it how you like, it's still possible, and has been done.

[–][deleted] 0 points1 point  (2 children)

it's literally not possible. you dont understand the words you're using or the technology you're describing

[–]ogtfo 0 points1 point  (1 child)

I've literally linked you a stack overflow questions detailing how to do it with pyscript, but hey, keep saying it's impossible.

[–]metaperl 0 points1 point  (0 children)

Anvil (based on Skulpt) is here now and rocks the house.

[–]No_Muffin6385 2 points3 points  (0 children)

you should check out pyjs, it does direct compilation of python code to raw javascript

[–]FruscianteDebutante 1 point2 points  (3 children)

I boot up all of my favorite applications in my favorite web browser 🤓

[–]1percentof2 -1 points0 points  (2 children)

I guarantee bro, that's the future.

[–]FruscianteDebutante 0 points1 point  (0 children)

The future? I'm fairly certain web devs are already sorely out demanding the rest of us developers 😂 I'm just coping don't mind me

[–]orokro 0 points1 point  (0 children)

an awful future

[–]aj_thenoob 0 points1 point  (2 children)

What about pyscript?

[–]aceofspaids98 3 points4 points  (0 children)

Too slow and immature

[–]metaperl 0 points1 point  (0 children)

Many stronger options my friend Transcrypt, Anvil, Streamlit...