Skip to content

anshukushwaha07/chrome-code-runner

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🚀 Code Runner Chrome Extension

Run C++, Java, Python, JavaScript, and more inside your browser — no IDE required. This extension uses Judge0 API (via RapidAPI) to compile & run code securely in a sandbox.

✨ Features

  • ✅ Run code instantly in a popup window
  • ✅ Supports multiple languages:
  • C / C++
  • Java
  • Python
  • JavaScript (NodeJS)
  • C#
  • ✅ Set & save your RapidAPI Key
  • ✅ Input box for custom test cases
  • ✅ Dark UI with Ace Editor (syntax highlighting)
  • ✅ Shortcut support for quick run (future update)

📦 Tech Stack

Component Used
Chrome Extension
JS / HTML / CSS
Ace Editor
Judge0 API via RapidAPI
LocalStorage for API key

🧠 How It Works

The extension sends your code and selected language to Judge0 API, which compiles/executes it and returns output.

Clone Repo

git clone https://github.com/anshukushwaha07/chrome-code-runner.git
cd chrome-code-runner

2️⃣ Install Extension in Chrome

  1. Open chrome://extensions/

  2. Turn on Developer Mode

  3. Click Load unpacked

  4. Select project folder

🔑 Add RapidAPI Key

  1. Visit: https://rapidapi.com/judge0-official/api/judge0-ce

  2. Subscribe to free plan

  3. Copy your API Key

  4. Click ⚙️ in extension → paste key → Save

🎯 Usage

  1. Open extension from Chrome toolbar

  2. Select language

  3. Type code

  4. (Optional) Add input

  5. Click Run Code

  6. View output below editor

🛠️ Folder Structure

📦chrome-code-runner
 ┣ 📂icons
 ┣ 📜manifest.json
 ┣ 📜popup.html
 ┣ 📜popup.js
 ┣ 📜styles.css
 ┗ 📜README.md

🚨 Current Limitations

Feature Status
Offline execution ❌ (Future: WebAssembly runtimes like Pyodide)
File input ⏳ Coming soon
Multi-file support ⏳ Coming soon

🚀 Future Updates

Feature Goal
Run code offline (WASM) Python, C++, NodeJS Local Runtime
Add AI Code Assist Auto-fix / explain code
Code History Save previous runs
VS Code Theme Dark+ / Light

🤝 Contributing

PRs welcome! If you want to help add WASM/offline execution, contact or open issue 👍

This project ships with Ace Editor's src-min build locally. Reason: Chrome extensions cannot load remote JS files (CDN) due to security (Content Security Policy), so Ace must be bundled inside the extension.

Source: https://github.com/ajaxorg/ace-builds

📜 License

MIT — free to modify & build on!

About

Chrome extension to run code snippets in-browser with multi-language support.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published