diff --git a/src/constants/editor/languages.ts b/src/constants/editor/languages.ts index 5905618..9763145 100644 --- a/src/constants/editor/languages.ts +++ b/src/constants/editor/languages.ts @@ -1,8 +1,14 @@ -import { COriginal, CplusplusOriginal, PythonOriginal } from "devicons-react"; +import { + COriginal, + CplusplusOriginal, + JavaOriginal, + PythonOriginal, +} from "devicons-react"; export const SUPPORTED_LANGUAGES = [ { key: "c", value: "c", label: "C", icon: COriginal }, { key: "cpp", value: "cpp", label: "C++", icon: CplusplusOriginal }, + { key: "java", value: "java", label: "Java", icon: JavaOriginal }, { key: "python", value: "python", label: "Python", icon: PythonOriginal }, ]; diff --git a/src/constants/editor/values.ts b/src/constants/editor/values.ts index cf4e68c..d5aa1eb 100644 --- a/src/constants/editor/values.ts +++ b/src/constants/editor/values.ts @@ -14,6 +14,14 @@ using namespace std; int main() { cout << "Hello, World!"; return 0; +}`, + }, + { + key: "java", + value: `public class Main { + public static void main(String[] args) { + System.out.println("Hello, World!"); + } }`, }, {