
KrautScript lets you write JavaScript in German; Finally there is a way for Germans to code in their native language!
See it in action here.
- Include krautscript.js and krautscript.browser.js.
- Make sure your html is set to allow utf-8 characters (add
<meta charset="utf-8">in the<head>).
KrautScript supports the text/krautscript MIME type. Any script tag with that type will be compiled and run automatically:
<script type="text/krautscript">
wenn (x < 5) {
konsole.log("Ja!");
} sonst {
konsole.log("Nein!");
}
</script>You can also specify a src for your script tags:
<script type="text/krautscript" src="snaps.kraut"></script>KrautScript.germanToEnglish(code); // returns a string representing the translated codeKrautScript.englishToGerman(code); // returns a string representing the translated codeYou can see the translations over here. Feel free to submit a pull request!
To @pushmatrix for creating the original project.