Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

What's problem with this JSXBIN? #54

Open
mendax47 opened this issue Oct 26, 2022 · 5 comments
Open

What's problem with this JSXBIN? #54

mendax47 opened this issue Oct 26, 2022 · 5 comments

Comments

@mendax47
Copy link

mendax47 commented Oct 26, 2022

i have recently came across a JSXBIN when you try to decompile it it succesfully decompile but can't recompile with extended script it says illigal use of word "default" and also say illigal use of word "static"

@AngeloD2022
Copy link
Owner

Could you please send me the script in question?

@mendax47
Copy link
Author

lol.txt

rename -> txt -> jsxbin

@AngeloD2022
Copy link
Owner

The script you sent me somehow uses two reserved keywords in javascript: static (non-access modifier) and default (switch-case keyword) as member names in an object. While I don't know how they were compiled that way, I suggest refactoring the script so that they have a different name. This is otherwise not a decompiler problem, so I'll close this issue.

@venvw
Copy link

venvw commented Nov 10, 2024

@AngeloD2022 consider this
This valid .jsx

var foo = {
    "default": true, 
    "static": true
};

exports to following .jsxbin using vscode extension.

@JSXBIN@[email protected]@MyBbyBn0ABJAnASzDjGjPjPByBWzGiPjCjKjFjDjUCCzHjEjFjGjBjVjMjUDFctzG
jTjUjBjUjJjDEFctnftABB40BiAABAzAFByB

.jsx produced by jsxer

/*
* Decompiled with Jsxer
* Version: 1.7.3
* JSXBIN 2.0
*/

var foo = {default: true, static: true};

Execution of generated .jsx fails with SyntaxError: Illegal use of reserved word. Export back to .jsxbin also fails.

@AngeloD2022
Copy link
Owner

Interesting observation. I'll have to look further into this.

@AngeloD2022 AngeloD2022 reopened this Nov 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants