Feat(Nui): Nui send event | Close button

This commit is contained in:
chip committed 2020-08-28 00:22:25 +02:00
1 parent 3a213ea308
commit 5ae9f99f42
3 files changed
+31 -1

No files matched your search

+17
View File
@@ -0,0 +1,17 @@
export default {
async send(event, data = {}) {
// /// #if DEBUG
//return new Promise(resolve => setTimeout(resolve, 100));
// /// #endif
/* eslint-disable no-unreachable */
return fetch(`http://new-phone-who-dis/${event}`, {
method: "post",
headers: {
"Content-type": "application/json; charset=UTF-8",
},
body: JSON.stringify(data),
});
/* eslint-enable no-unreachable */
},
};