Skip to content

How to Merge Themes #9

@raybooysen

Description

@raybooysen

I posted this on StackOverflow, unsure on the best forum for this:

If I'm using react-themeable, often I want a component like:

const styles = require('./component.css');

class Component extends React.Component {
  render() {
       let customTheme = this.props.theme;
       return <div className={styles.container}>Hi</div>;
  }
}

If I have a theme I pass into the component via props, is there a way with react-themeable where I can merge the theme from the css file AND the theme from the props.

This mean consumers can override bits of the theme they want.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions