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

Less 2.1.1 conflicts with RequireJS #2346

Closed
kirill-konshin opened this issue Dec 18, 2014 · 3 comments
Closed

Less 2.1.1 conflicts with RequireJS #2346

kirill-konshin opened this issue Dec 18, 2014 · 3 comments

Comments

@kirill-konshin
Copy link

Less data attributes parsing feature conflicts with RequireJS's data-main attribute on line JSON.parse(tag.dataset[opt]) because tag.dataset[opt] is not JSON, it is a link to another JS file:

<script data-main="js/main.js" src="bower/requirejs/require.js" type="text/javascript"></script>

See: PR #2243 (comment) - Support reading less options from its script tag data attributes

@kirill-konshin
Copy link
Author

Somehow magically issue can be fixed if I add one extra script tag, even empty:

<script data-main="js/main.js" src="bower/requirejs/require.js" type="text/javascript" defer="defer"></script>
<script defer="defer"></script>

@lejenome
Copy link
Contributor

This PR #2315 should fix it

@lukeapage
Copy link
Member

Sorry should have done a release sooner. I've done v2.1.2 - report back here if its not fixed.

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