Hi,
Thanks for the attention. So, currently, I’m developing an app for hackathon event posted in devpost (specifically, the one hosted in here)
And, I’m having a difficulty trying to run these code
import api, { route } from '@forge/api';
const findProjects = async () => {
const user = api.asUser();
const endpoint = route('/rest/api/2/project');
const response = await user.requestJira(endpoint);
console.log(response);
};
(async () => {
await findProjects();
})().then(() => console.log('done'));
in my local, the code will throw an error
TypeError: proxy is undefined
createProxyFetch webpack://atlassian-dev-unleashed/./node_modules/@forge/api/out/api/fetch.js?:17
wrapRequestProduct webpack://atlassian-dev-unleashed/./node_modules/@forge/api/out/api/index.js?:22
So, I’m just wondering, is the issue caused by using webpack? If that’s the case, is there any workaround for this issue? there should be something I missed in here, so any feedback is definitely appreciated.
Thanks and have a nice day.
Regards,
Ivan