LoopBack is an open source Node.js framework built on top of Express optimized for mobile, web, and other devices. Connect to multiple data sources, write business logic in Node.js, glue on top of your existing services and data, connect using JS, iOS & Android SDKs.
bajtos on add-node10
POST /api/Customers
with some irrelevant json data...
Hi people, ho are you ?
how can I select the fields to show on well Model ??
Regards
Hi
I am using loopback 4 for backend and react for front end.
when I make a request on API, it gives me blocked Cors.
I tried this :
let config = {
mode: 'cors',
cache: 'no-cache',
credentials: 'same-origin',
headers: {
'Access-Control-Allow-Origin': '*',
'Content-Type': 'application/json',
},
redirect: 'follow',
referrerPolicy: 'no-referrer',
}
const response = await axios.post(${API}/signUppatient
, obj, config);
but it didn't work
const config = {
name: 'ipfs',
connector: 'rest',
baseURL: 'http://localhost:5001/api/v0/',
crud: false,
operations: [
{
template: {
method: 'POST',
url: 'http://localhost:5001/api/v0/add',
headers: {
'content-type': 'multipart/form-data;'
},
query: {
'only-hash': true,
},
form: {
file: '{file}',
},
},
functions: {
getCID: ['file'],
},
},
{
template: {
method: 'POST',
url: 'http://localhost:5001/api/v0/bootstrap/list',
},
functions: {
getPeers: [],
},
},
],
};
export interface Ipfs {
getCID(file: Buffer): Promise<CID>,
getPeers(): Promise<unknown>
}
allowArray
in an option somewhere. However, I have not found where this option should be inserted. In the model json description I assume, but where?