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

Overview

Code-Runner-Web-Component

ezgif-5-d9d9221610

A web component that allows you to run high level programming languages on your website via the public Piston API
Show your support!

Example and usage

You can view a demo of the Code Runner web component in use here.

How to use Code Runner:

Set a language attribute to a supported programming language & version attribute to the programming version you prefer to use - example below

<code-runner language="python" version="3"></code-runner>

include this script in your HTML document.

<script src="https://cdn.jsdelivr.net/gh/MarketingPipeline/Code-Runner-Web-Component/dist/code-runner-wc.min.js" defer></script> 

How to use Code Runner with Pre-Defined Code:

You can pre-define a code example to run, simply by inserting the code inside of a code-runner element like so -

<code-runner language="python" version="3">print('hello world')</code-runner>

Options

Attribute Meaning Default Required
language The programming language to execute code with Undefined Yes
version The programming language version to use Undefined Yes

Supported Languages

awk, bash, befunge93, brachylog, brainfuck, bqn, c, c++, cjam, clojure, cobol, coffeescript, cow, crystal, csharp, csharp.net, d, dart, dash, dragon, elixir, emacs, emojicode, erlang, file, forte, forth, fortran, freebasic, fsharp.net, fsi, go, golfscript, groovy, haskell, husk, iverilog, japt, java, javascript, jelly, julia, kotlin, lisp, llvm_ir, lolcode, lua, matl, nasm, nasm64, nim, ocaml, octave, osabie, paradoc, pascal, perl, php, ponylang, powershell, prolog, pure, pyth, python, python2, racket, raku, retina, rockstar, rscript, ruby, rust, scala, smalltalk, sqlite3, swift, typescript, basic, basic.net, vlang, vyxal, yeethon, zig,


Contributing GitHub

Want to improve this? Create a pull request with detailed changes / improvements! If approved you will be added to the list of contributors of this awesome project!

See also the list of contributors who participate in this project.

License GitHub

This project is licensed under the GPL-3.0 License - see the LICENSE.md file for details.

You might also like...

When a person that doesn't know how to create a programming language tries to create a programming language

When a person that doesn't know how to create a programming language tries to create a programming language

Kochanowski Online Spróbuj Kochanowskiego bez konfiguracji projektu! https://mmusielik.xyz/projects/kochanowski Instalacja Stwórz nowy projekt przez n

Dec 4, 2022

Cookbook Method is the process of learning a programming language by building up a repository of small programs that implement specific programming concepts.

Cookbook Method is the process of learning a programming language by building up a repository of small programs that implement specific programming concepts.

CookBook - Hacktoberfest Find the book you want to read next! PRESENTED BY What is CookBook? A cookbook in the programming context is collection of ti

Nov 17, 2022

Template Repository for making your own budder Module. CORE is not included, this is just for the module.

A quick copy of the "How to make your own module" section Check out the official budderAPI repository Template Repository for making your own budder M

Apr 3, 2022

🔥 Bon5R — Create static, blog-aware websites with pure MDX.

Bon5R Create static, blog-aware websites with pure MDX. Explore the docs » View Demo · Report Bug · Request Feature Table of Contents About The Projec

Jul 5, 2022

Multithread emulator. The wrun allows you to dynamically run a function inside a Web Worker on the client side, without the needing of a dedicated file

wrun This lib allows you to dynamically run a function inside a Web Worker on the client side, without the needing of a dedicated file. This means tha

Nov 5, 2022

Run a command, watch the filesystem, stop the process on file change and then run the command again...

hubmon Run a command, watch the filesystem, stop the process on file change and then run the command again... Install You can install this command lin

Jul 30, 2022

MerLoc is a live AWS Lambda function development and debugging tool. MerLoc allows you to run AWS Lambda functions on your local while they are still part of a flow in the AWS cloud remote.

MerLoc is a live AWS Lambda function development and debugging tool. MerLoc allows you to run AWS Lambda functions on your local while they are still part of a flow in the AWS cloud remote.

MerLoc MerLoc is a live AWS Lambda function development and debugging tool. MerLoc allows you to run AWS Lambda functions on your local while they are

Dec 21, 2022

A starter and demo project for Keycloakify v6 - Component level customization.

A starter and demo project for Keycloakify v6 - Component level customization.

A starter/demo project for Keycloakify ⚠️ Please read the two following notices ⚠️ This starter is for Component-level customization, if you only want

Dec 26, 2022
Comments
  • Web Component Started

    Web Component Started