mirror of
https://github.com/jupyterhub/jupyterhub.git
synced 2025-10-09 19:13:03 +00:00
Add React Admin and modify AdminHandler
This commit is contained in:
10
jsx/src/util/jhapiUtil.js
Normal file
10
jsx/src/util/jhapiUtil.js
Normal file
@@ -0,0 +1,10 @@
|
||||
export const jhapiRequest = (endpoint, method, data) => {
|
||||
return fetch("/hub/api" + endpoint, {
|
||||
method: method,
|
||||
json: true,
|
||||
headers: {
|
||||
"Content-Type": "application/json",
|
||||
},
|
||||
body: data ? JSON.stringify(data) : null,
|
||||
});
|
||||
};
|
Reference in New Issue
Block a user