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

String continuations are not recommended #2566

Open
furkan3ayraktar opened this issue Jan 8, 2024 · 2 comments
Open

String continuations are not recommended #2566

furkan3ayraktar opened this issue Jan 8, 2024 · 2 comments

Comments

@furkan3ayraktar
Copy link

According to the Google JavaScript Style Guide, string continuations are not recommended.

When using shepherd from ClojureScript (which uses Google's Closure Compiler), we get several warnings during compilation due to the line continuations used in the below file:

return `M${w},${h}\
H0\
V0\
H${w}\
V${h}\
Z\
M${x + topLeft},${y}\
a${topLeft},${topLeft},0,0,0-${topLeft},${topLeft}\
V${height + y - bottomLeft}\
a${bottomLeft},${bottomLeft},0,0,0,${bottomLeft},${bottomLeft}\
H${width + x - bottomRight}\
a${bottomRight},${bottomRight},0,0,0,${bottomRight}-${bottomRight}\
V${y + topRight}\
a${topRight},${topRight},0,0,0-${topRight}-${topRight}\
Z`;
}

Is there a way to implement the same functionality without using line continuations?

@sirmspencer
Copy link

I see the same thing.

@chuckcarpenter
Copy link
Contributor

I know it's been a bit, but open to suggestions or PRs @furkan3ayraktar @sirmspencer ?

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