Skip to content

Add basic CSS macro.#3

Draft
Conner-PYS wants to merge 11 commits intovidhanio:mainfrom
Probably-Yes-Software-LLC:css-macro
Draft

Add basic CSS macro.#3
Conner-PYS wants to merge 11 commits intovidhanio:mainfrom
Probably-Yes-Software-LLC:css-macro

Conversation

@Conner-PYS
Copy link
Contributor

Draft PR; open to suggestions for wider support of more CSS syntax.

@vidhanio
Copy link
Owner

vidhanio commented Aug 3, 2023

@Conner-PYS thanks!

yeah, there is definitely some prior discussion that has been done here.

currently, the best solution using my library is to use a Node::UnsafeText (or unsafe_text! and just put your css in a in that node.

the problem, as you mentioned in your example, is that TokenStreams are whitespace-agnostic, so we cannot recreate some css attr-name faithfully.

there is a potential workaround that has been discussed here, using a trick where you retrieve the source text of the macro invocation and reconstruct the RawText exactly as it was written.

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

Successfully merging this pull request may close these issues.

2 participants