mirror of
https://github.com/woodchen-ink/clash-and-dashboard.git
synced 2025-07-18 14:01:56 +08:00
Update: add some apis
This commit is contained in:
parent
f40da55557
commit
4dacafb285
@ -124,6 +124,22 @@ export class JsBridge {
|
|||||||
)
|
)
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public ping () {
|
||||||
|
return this.callHandler('ping')
|
||||||
|
}
|
||||||
|
|
||||||
|
public readConfigString () {
|
||||||
|
return this.callHandler('readConfigString')
|
||||||
|
}
|
||||||
|
|
||||||
|
public getPasteboard () {
|
||||||
|
return this.callHandler('getPasteboard')
|
||||||
|
}
|
||||||
|
|
||||||
|
public setPasteboard (data: string) {
|
||||||
|
return this.callHandler('setPasteboard', data)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export function setupJsBridge (callback) {
|
export function setupJsBridge (callback) {
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import * as React from 'react'
|
import * as React from 'react'
|
||||||
import { render } from 'react-dom'
|
import { render } from 'react-dom'
|
||||||
import { AppContainer } from 'react-hot-loader'
|
import { AppContainer } from 'react-hot-loader'
|
||||||
import App from './components/App'
|
import App from '@components/App'
|
||||||
|
|
||||||
const rootEl = document.getElementById('root')
|
const rootEl = document.getElementById('root')
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user