React
HTMLPLUS elements are fully compatible with React library.
#
Install
Install HTMLPLUS package into React application.
npm install @htmlplus/ui
#
Usage
Import the reference of elements.
import '@htmlplus/ui';
const App = () => <plus-switch/>;
export default App;
#
Properties
To set properties and attributes.
import '@htmlplus/ui';
const App = () => <plus-switch disabled/>;
export default App;
#
Events
To handle event's callback.
import '@htmlplus/ui';
const App = () => <plus-switch onPlusChange={() => alert('The switch toggled!')} />;
export default App;