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

Apply postcss transforms for tagged template css #4

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

felipeccastro
Copy link

Atom will enable the syntax highlighting for css if the tagged template is named css (instead of csjs).
I know this is kind of out of the scope of this repo, but it's such a minor change that it doesn't seem necessary to keep a separate project just for that.

Atom will enable the syntax highlighting for css if the tagged template is named `css` (instead of `csjs`).
I know this is kind of out of the scope of this repo, but it's such a minor change that it doesn't seem necessary to keep a separate project just for that.
@rtsao
Copy link
Owner

rtsao commented Oct 15, 2016

Cool! I think making the tag name configurable seems like a good idea (as opposed to being hardcoded to csjs)

Could you update your PR so it can be passed in via config (like plugins are) as opposed to hardcoding css?

Perhaps something like:

{
  "plugins": [["csjs-postcss", {
    "tagName": "css"
  }]]
}

And a test case for this would be nice to have as well!

@arturi
Copy link

arturi commented Mar 17, 2017

Hi! Thanks so much for the transform. And csjs. I added the option, but also renamed the transform, since I’m using it without csjs (with this https://github.com/arturi/template-css) and I think it could be useful for any other package doing css in template strings. What do you think: https://github.com/arturi/babel-plugin-template-strings-postcss? Should I publish a separate version, or should I add tests and send a PR? Are you interested in making the transform not csjs-specific, letting it run free?

@rtsao
Copy link
Owner

rtsao commented Mar 17, 2017

@arturi Yeah, I see no reason for this to be CSJS-specific. Happy to merge in a PR!

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.

3 participants