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

Dojo unsupported script types. #874

Closed
lethevimlet opened this issue Feb 13, 2016 · 2 comments
Closed

Dojo unsupported script types. #874

lethevimlet opened this issue Feb 13, 2016 · 2 comments

Comments

@lethevimlet
Copy link

Dojo Toolkit uses script type=”dojo/method” and script type=”dojo/aspect” since this is not a default MIME this will cause formatting issues.

dojo/method and dojo/aspect is highly used when working with Dojo Toolkit, as described in

https://dojotoolkit.org/reference-guide/1.10/dijit/Declaration.html

@lethevimlet
Copy link
Author

It can be easily fixed like so (line 502 of beautify-html.js)
tag_complete.search(/\b(text|application|dojo)\/(x-)?(javascript|ecmascript|jscript|livescript|(ld\+)?json|method|aspect)/) > -1))) {

Ideally js-beautify shouldn't attempt to format unknown types since in worst case scenario the formatting would be omitted while if wrong formatting is applied to an unknown type code will get messed up affecting its functionality.

@bitwiseman
Copy link
Member

@joselightware - Could you give an example of input, expected output, and actually output?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants