Skip to content

Using the sample code in react triggers a style violation #15

Open
@j4y

Description

@j4y

I used the code from the documentation:

<BootstrapSwitchButton
    checked={false}
    onlabel='Admin User'
    onstyle='danger'
    offlabel='Regular User'
    offstyle='success'
    style='w-100 mx-3'
    onChange={(checked: boolean) => {
        this.setState({ isUserAdmin: checked })
    }}
/>

And it produced a style violation:

./src/App.js
  Line 102:  Style prop value must be an object  react/style-prop-object
  Line 112:  Style prop value must be an object  react/style-prop-object
  Line 122:  Style prop value must be an object  react/style-prop-object
  Line 132:  Style prop value must be an object  react/style-prop-object

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