oraoto / pib

PHP in Browser (powered by WebAssembly)
https://oraoto.github.io/pib/
Apache License 2.0
956 stars 112 forks source link

A more generic and practical output #36

Open the-liquid-metal opened 4 years ago

the-liquid-metal commented 4 years ago

I guess that people want to use it like this way:

<script type="text/php">
    // php code here
</script>

so, make it as generic as possible and register it to packagist.org.

Rather than instruct people how to build it, it is more reasonable to provide the output. If my output is the same output as yours, why do i have to build my self while we have the same needs: a common php engine. Let your output be the "official" one.

Goddard commented 4 years ago

Do you have any experience submitting packages to packagist.org?

the-liquid-metal commented 4 years ago

I guest this question is for @oraoto:

Do you have any experience submitting packages to packagist.org?

More fundamental question: Is "a generic and practical output" not your original goal and prevent you submitting package to packagist.org?

Well, your work opens the door for people who dream for a long time replacing javascript with php.

seanmorris commented 4 years ago

Do you have any experience submitting packages to packagist.org?

Its already on npm under php-wasm. I don't think it makes sense to put this on packagist as its a php binding for javascript, so I see it as more of a JS package than a PHP one.

seanmorris commented 4 years ago

Also my fork implements PHP script tags: https://github.com/seanmorris/php-wasm

seanmorris commented 4 years ago

My changes have been pulled into the main branch.

uuf6429 commented 2 years ago

I'd like this functionality as well, especially since <?php makes IDEs and servers go crazy trying to render PHP.

Unfortunately, I get mixed messages from the points above - is this functionality implemented in oraoto/pib or not? Either way, neither original repo nor the fork show an example without the PHP open tag (and, while at it, they also incorrectly show the 'equal' (in the html tag) surrounded with space.