Skip to content

Allow empty string to be passed to styleName. #34

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

Closed
AndrewSouthpaw opened this issue Jan 6, 2017 · 4 comments
Closed

Allow empty string to be passed to styleName. #34

AndrewSouthpaw opened this issue Jan 6, 2017 · 4 comments
Assignees
Labels

Comments

@AndrewSouthpaw
Copy link

I have a use case where I conditionally want to apply a style, e.g.

<div styleName={isReady : 'ready' : ''}>
  ...
</div>

Currently there's no way to accomplish this, because the plugin will explode looking for a CSS module that uses an empty string. Is there a way to short-circuit this case and give up?

@gajus gajus added the bug label Jan 6, 2017
@gajus gajus self-assigned this Jan 6, 2017
@gajus gajus closed this as completed in eabee89 Jan 6, 2017
@gajus
Copy link
Owner

gajus commented Jan 6, 2017

@AndrewSouthpaw fixed.

@AndrewSouthpaw
Copy link
Author

Thanks! I'm trying to download v2.1.4, but npm is saying it's invalid...

@gajus
Copy link
Owner

gajus commented Jan 6, 2017

Thanks! I'm trying to download v2.1.4, but npm is saying it's invalid...

Can you share the error log?

@AndrewSouthpaw
Copy link
Author

Weird, it fixed itself. :-/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants