Interface for a class Button
EmitType<Event>
Triggers once the component rendering is completed.
string
Defines the text content
of the Button element.
import { render } from "react-dom";
import "./index.css";
import * as React from "react";
import { ButtonComponent } from "@syncfusion/ej2-react-buttons";
import { SampleBase } from "./sample-base";
export class Default extends SampleBase {
content = "Normal";
render() {
return (
<ButtonComponent cssClass="e-primary" content={this.content}></ButtonComponent>
);}
}
render(<Default />, document.getElementById("sample"));
string
Defines class/multiple classes separated by a space in the Button element. The Button types, styles, and
size can be defined by using
this
.
import { render } from "react-dom";
import "./index.css";
import * as React from "react";
import { ButtonComponent } from "@syncfusion/ej2-react-buttons";
import { SampleBase } from "./sample-base";
export class Default extends SampleBase {
primary_class = "e-primary";
render() {
return (
<ButtonComponent cssClass={this.primary_class} content="Normal"></ButtonComponent>
);}
}
render(<Default />, document.getElementById("sample"));
boolean
Specifies a value that indicates whether the Button is disabled
or not.
boolean
Defines whether to allow the cross-scripting site or not.
boolean
Enable or disable persisting component’s state between page reloads.
boolean
Enable or disable rendering component in right to left direction.
string
Defines class/multiple classes separated by a space for the Button that is used to include an icon. Buttons can also include font icon and sprite image.
string
| IconPosition
Positions the icon before/after the text content in the Button. The possible values are:
boolean
Allows the appearance of the Button to be enhanced and visually appealing when set to true
.
boolean
Makes the Button toggle, when set to true
. When you click it, the state changes from normal to active.