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

New line problem #74

Closed
maciekmaciej opened this issue Nov 18, 2017 · 4 comments
Closed

New line problem #74

maciekmaciej opened this issue Nov 18, 2017 · 4 comments

Comments

@maciekmaciej
Copy link

maciekmaciej commented Nov 18, 2017

Hi!
I encountered a little problem with new lines in property values.
In this example semicolon is inserted too early in the string:

https://codepen.io/asistapl/pen/zPpZgr?editors=0012

It can be avoided by escaping new line sign but it's not very intuitive and looks bad.
When writing grid layout rules it's common to use multi line strings in property values so it would be great if it could be solved.

Thanks!

@thysultan
Copy link
Owner

Related to #56.

It should work if you disable auto semi-colon insertion mode stylis.set(semicolon: true).

That said i do intend to improve the auto semi-colon insertion mode heuristics to take this into account.

@maciekmaciej
Copy link
Author

Thanks.
I'm using emotion so I don't have access to that setting.
I think they remove white space in tagged template literals but problem occurs when interpolating other strings where white space is preserved.

@thysultan
Copy link
Owner

Can you open an issue with emotion to disable ASI mode until this is fixed?

@thysultan
Copy link
Owner

Patched in 3.4.5

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

2 participants