Last active
January 4, 2017 22:19
-
-
Save zzarcon/9b5b5e1e15aee9682de930cf141a0713 to your computer and use it in GitHub Desktop.
Webcomponent custom styles example
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** @jsx h */ | |
/* | |
Component A passing custom styles to sk-tags | |
*/ | |
import { Component, h } from 'skatejs'; | |
class A extends Component { | |
renderCallback() { | |
const tagStyles = ` | |
.tag { | |
background-color: red; | |
} | |
.wrapper { | |
border: 1px solid black; | |
} | |
`; | |
return <sk-tags styles={tagStyles} /> | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@treshugart updated, I removed the
skatepark-core
just to not confuse people. Do you think that the gist makes sense now or is just too simple and doesn't add value to the article? Maybe we can just get rid of it.