mirror of
https://github.com/haiwen/seahub.git
synced 2025-06-19 20:03:03 +00:00
10 lines
295 B
JavaScript
10 lines
295 B
JavaScript
|
import cookie from 'react-cookies';
|
||
|
import { SeafileAPI } from 'seafile-js';
|
||
|
import { siteRoot } from '../components/constants';
|
||
|
|
||
|
let seafileAPI = new SeafileAPI();
|
||
|
let xcsrfHeaders = cookie.load('sfcsrftoken');
|
||
|
seafileAPI.initForSeahubUsage({ siteRoot, xcsrfHeaders });
|
||
|
|
||
|
export { seafileAPI };
|