1
0
mirror of https://github.com/quinton-ashley/java2js synced 2024-12-29 10:11:54 +01:00
This commit is contained in:
Quinton Ashley 2023-04-11 09:21:22 -05:00
parent c2a07d4cdd
commit e7e62c6ac8
2 changed files with 3 additions and 1 deletions

2
jdk.js
View File

@ -178,6 +178,8 @@
let className = file.slice(classLine + 13, file.indexOf('{', classLine + 13));
file = file.replaceAll(/\s+{/gm, ' {');
// workaround hack for converting triple quotes to a normal string
file = file.replace(/"""([^"]*)"""/gm, (match, p1) => {
return '(' + p1.replace(/( |\t){0,3}(.*)(\r*\n|$)/gm, '"$2\\n"+').slice(0, -1) + ')';

View File

@ -1,6 +1,6 @@
{
"name": "java2js",
"version": "1.2.19",
"version": "1.2.20",
"description": "Converts Java to JavaScript and runs it with a JS JDK",
"main": "jdk.js",
"scripts": {