Searchlight for react.
npm install -S @jswork/react-searchlight
Name | Type | Required | Default | Description |
---|---|---|---|---|
className | string | false | - | The extended className for component. |
options | object | false | - | The default options for react-draggable. |
- import css
@import "~@jswork/react-searchlight/dist/style.css";
// or use sass
@import "~@jswork/react-searchlight/dist/style.scss";
// customize your styles:
$react-searchlight-options: ()
- import js
import ReactDemokit from '@jswork/react-demokit';
import React from 'react';
import ReactDOM from 'react-dom';
import ReactSearchlight from '@jswork/react-searchlight';
import './assets/style.scss';
class App extends React.Component {
render() {
return (
<ReactDemokit
className="p-3 app-container"
url="https://github.com/afeiship/react-searchlight">
<h1 className="text-center mb-5 text-white text-2xl">
Searchlight for react.
</h1>
<iframe width="100%" src="https://m.baidu.com"></iframe>
<ReactSearchlight />
</ReactDemokit>
);
}
}
ReactDOM.render(<App />, document.getElementById('app'));
Code released under the MIT license.