You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have bunch of JavaScript functions, all loaded in memory inside a python code, and I need to validate their syntax without writing them down in .js files.
I was looking for a python package that could perform this task for me, and found this package. I tried to use javascript package for my goal, but was not sure if there is any way that I could only check syntax with that in python.
P.S.: JSHint/prettier work OK if I write each function in a file and then call something like os.system("jshint --verbose sample.js"), but writing the js functions in file is expensive and takes a lot of time. So, looking for a method/package that can do the same without writing the codes in file.
The text was updated successfully, but these errors were encountered:
If you want to use something from the JS side (that maybe more up to date/maintained), you can checkout the TypeScript AST parser, or use Babel's parser, with JSPyBridge usage demonstrated here:
I have bunch of JavaScript functions, all loaded in memory inside a python code, and I need to validate their syntax without writing them down in .js files.
I was looking for a python package that could perform this task for me, and found this package. I tried to use
javascript
package for my goal, but was not sure if there is any way that I could only check syntax with that in python.P.S.: JSHint/prettier work OK if I write each function in a file and then call something like os.system("jshint --verbose sample.js"), but writing the js functions in file is expensive and takes a lot of time. So, looking for a method/package that can do the same without writing the codes in file.
The text was updated successfully, but these errors were encountered: