MarketingPipeline / Code-Runner-Web-Component

A web component that allows you to run high level programming languages on your websites (static websites included!)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[Feature Request]: Support for nodejs and add html and css to javascript

bsde1234 opened this issue · comments

Hi,
Thanks for making this project. Please add support for nodejs. Also please add html and css support to javascript addon so that html, css and javascript can be used in one.

@bsde1234 - you are more than welcome! :)

First thing is first -

I do believe Node.js can be executed via the Piston API by using the language javascript

Please report results to me on this.

Second thing -

I am actually in the progress of adding features to implement addons / plugins - so other compilers & more can be added.

That said - I have not found a good compiler that is capable of handling HTML / CSS / JS in a sandboxed iframe environment. If you could recommend one - I could look at possibly taking a jab at this.

Though - if you are willing to provide some CSS that can be easily applied & as well tab functionality to help speed this feature request by chance (it would be more than appreciated) or even willing to create a plugin for this yourself -
it would be more than appreciated to have some contributors on this projects, to help with creating plugins like this!

If you can't help with the second request, you might have to wait awhile for me or someone else to implement this feature!

Thank you for your support as well to the repo! 👍

ps: feel free to share with your friends etc to help the project grow!

For javascript it gives error for following code console.log('Current version: ' + process.version); like

�[0m�[1m�[31merror�[0m: Uncaught ReferenceError: process is not defined
console.log('Current version: ' + process.version);
�[0m�[31m ^�[0m
at �[0m�[36mfile:///piston/jobs/168b0392-f191-4900-b784-8897482edfe9/file0.code�[0m:�[0m

Actually I am not an advanced developer to give a pull request. I will wait to someone will do that for you.

Thanks.

More than understandable!

Well in the mean time - please be sure to ⭐ the repo to show your continued support!

As for the Node.JS - pretty sure Node.JS is running fine - just the modules are not exposed to you properly. - I am not a Node.JS developer tho so hoping someone else can chime in here.

@bsde1234 I have actually been working on this. Lost a lot of work tho due to my computer crashing .-. but, keep a eye out!

Here is a sneak peak!

image

Keep in mind as well - you have no idea how much sending resources like that help me save time so thank you very much. 😄

ps; I seen you were wanting a PHP compiler + this way back on another repo. I will add a PHP compiler asap. But please again bare with me as my computer is literally old as a dinosaur. (Donations are more than welcome haha!)

Image looks nice. In your readme there is php in supported language. Don't you actually support it?

Image looks nice. In your readme there is php in supported language. Don't you actually support it?

Correct the current Web Component does support PHP but it is rendered via API and not client side. Adding a PHP compiler client side will allow for more REAL / TRUE like PHP compiling in the browser. 👍

ps; updated the demo to show PHP is currently supported + you can browse all the other supported languages / demo them! 👍

Thanks for the info. You will get more client side compiler at https://github.com/lyricat/code-knack

Hey @bsde1234,

Sorry for delay on this! I will try to make some updates regarding the HTML, CSS & JS playground ASAP.

That said you are good to go and use Node.js in the latest version! Just set the language attribute to node-js.

Other than that,
I hope your doing well. ✌️

ps; I will hopefully wrap up the request of adding the HTML, CSS & JS support in this library or maybe even another etc! Tho I will keep you posted!