MCPcopy Index your code
hub / github.com/reactstrap/reactstrap / onClick

Method onClick

src/DropdownToggle.js:40–55  ·  view source on GitHub ↗
(e)

Source from the content-addressed store, hash-verified

38 }
39
40 onClick(e) {
41 if (this.props.disabled || this.context.disabled) {
42 e.preventDefault();
43 return;
44 }
45
46 if (this.props.nav && !this.props.tag) {
47 e.preventDefault();
48 }
49
50 if (this.props.onClick) {
51 this.props.onClick(e);
52 }
53
54 this.context.toggle(e);
55 }
56
57 getRole() {
58 return this.context.menuRole || this.props['aria-haspopup'];

Callers

nothing calls this directly

Calls 1

toggleMethod · 0.45

Tested by

no test coverage detected