weshop-segment-en
v0.0.1
Published
<p align="center"> <img src="https://weshop-ai-image-va-1322216870.cos.na-ashburn.myqcloud.com/20240913-191647.jpeg" /> </p>
Readme
React + TypeScript + Vite
A simple component for making elements segment.
<Segment apiKey="111" taskId="222" handleMask={handleMask}></Segment>For more information about apiKey and taskId, please check https://open.weshop.ai/authorization/apikey
| Version | Compatibility | | ------- | ------------- | | 0.x | React 18+ |
Installing
$ npm install weshop-segment-en// ES6
import Segment from 'weshop-segment-en' // The defaultSegment Usage
View the Demo at example/App.tsx
import Segment from 'weshop-segment-en'
import './index.less'
function App() {
const handleMask = (mask: string) => {
console.log(`This mask is:${mask}`)
}
return (
<div className="App">
<div className="segment">
<div className="segment-content">
<Segment apiKey="111" taskId="222" handleMask={handleMask}></Segment>
</div>
</div>
</div>
)
}
export default App<Segment> Props:
{
apiKey: string,
taskId: string,
handleMask: (mask: string) => void
}Run Demo
$ npm install
$ npm run devLicense
MIT
