<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Nugraha Fikri on Medium]]></title>
        <description><![CDATA[Stories by Nugraha Fikri on Medium]]></description>
        <link>https://medium.com/@nugrahafikri?source=rss-4310c124c0ba------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*Q-VQ6-DuWYrFqMspIHUv2w.jpeg</url>
            <title>Stories by Nugraha Fikri on Medium</title>
            <link>https://medium.com/@nugrahafikri?source=rss-4310c124c0ba------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 17 Nov 2026 22:25:49 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@nugrahafikri/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Lesson learned developing app inside jira using Forge, Vite and Vuejs]]></title>
            <link>https://medium.com/@nugrahafikri/lesson-learned-developing-app-inside-jira-using-forge-vite-and-vuejs-2858b477aecc?source=rss-4310c124c0ba------2</link>
            <guid isPermaLink="false">https://medium.com/p/2858b477aecc</guid>
            <dc:creator><![CDATA[Nugraha Fikri]]></dc:creator>
            <pubDate>Mon, 31 Oct 2022 16:02:03 GMT</pubDate>
            <atom:updated>2022-11-11T03:31:59.479Z</atom:updated>
            <content:encoded><![CDATA[<p>it’s our story trying to create a forge app for Atlassian codegeist 2022.</p><h3>Intro</h3><p>Atlassian forge is an awesome development tool. you can create jira apps and even test on your localhost directly on their UI. If you are Reactjs developer it would be really easy to get started, get your feet wet and get the development workflow ready “out of the box”.</p><p>but we are team of a Vuejs developer, even though you can use Forge with custom UI event with oldschool html+jquery stack you can develop your UI and deploy to Atlassian Forge without any problem, but you will miss many convenience that modern frontend tooling offer such as hot reloading, compressing, chunking and code splitting.</p><p>here are some lesson learned that we learn through our journey learning from creating and rebuilding our feature in <a href="http://bannerbite.com/">Bannerbiter</a> inside Jira with Forge and custom UI</p><h3>Lesson 1: setting up vite with vuejs</h3><p>As we are using an older version of vite and vue3 at first when we try to setup a project and start coding and try the hot reloading module it doesn’t work as it used to. we need to manually reload when we change nested components. but after we upgrade from version</p><pre>“vite”: “2.8.1”,<br>“vue”: “3.2.31”,<br>“@vitejs/plugin-vue”: “1.10.2”,</pre><p>to the version</p><pre>“vite”: “3.1.0”,<br>“vue”: “3.2.37”,<br>“@vitejs/plugin-vue”: “3.1.0”,</pre><p>everything works well, hot reloading works and we can code as we used to. so we recommend to use this configuration for vue and vite for minimum requirement if you want to start develop Forge Custom UI with vuejs.</p><h3>Lesson 2: Deploying and collaborate between coder</h3><p>at first we thought deploying would be easy and no problem after upgrading but how wrong we are when we found that deploy is finished successfully but when we try anything all we get is 404 error in our index.js</p><p>After searching in Atlassian docs we coulnd find any but after we dig deeper in ReactJs hello world in Forge example we then understand that they use ``./’’ instead of “/’’ vite default setting for vuejs.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/598/0*gFHvUwXJhzewJzX3" /><figcaption>default vite using “/”</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/609/0*3xYwwbaWJxTCxksT" /><figcaption>Forge build standard using“./”</figcaption></figure><p>we add this config to match Forge deployment standard.</p><p>The second problem we had after deploying was collaboration. We recommend you to add automated version naming printed in your frontend when developing your Forge with many coders that can deploy directly. because someone can build an older version or forgot to build before deploying and cause some headache. This one is our honest mistake. Without proper communication it can be solved.</p><h3>Lesson 3: Permission tips and trick</h3><p>at first we thought it’s silly and lazy but later when we develop more and more we feel the need to share to the world that if you in development mode and trying many things at once consider to just add * in your manifest or we recommend to create dev-manifest.yml with permission *.</p><p>because when you develop and try many cdn or library for the sake of experiment * is a time boost to your day to day development. just make sure don’t put * on your production env manifest 😉.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/345/0*xKXUgswsBBcZvpOK" /><figcaption>more stars more freedom 😉</figcaption></figure><h3>Lesson 4: Forge web trigger</h3><p>We spend almost a week just getting our head around this feature. maybe we are stupid, or maybe this runtime in Forge is still under documented.</p><p>There is little to no documentation near the request and response model and what are we supposed to do with that. but we finnaly can solve this response format with just</p><pre>const buildOutput = (data, body = ‘’, statusCode = 200, statusText = ‘OK’) =&gt; ({ <br>body: JSON.stringify({ data: data }),<br>headers: {<br> ‘Content-Type’: [‘application/json’],<br>},<br> statusCode,<br> statusText,<br>});</pre><p>turns out all you need is only body, headers with content-type, statusCode and statusText. we always use body parser with expressJS to handle this format for granted and then punished by confusion 😅</p><p>Next, what’s weird about web triggers is when you send a form. it’s not parsed and takes raw form.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/318/0*u_8UYK8zWIPlA68G" /><figcaption>raw like this 🍖</figcaption></figure><p>we recommend you to wrap your object around {} and stringify before sending.</p><pre>formData.append(‘file’, JSON.stringify({YourData}));</pre><p>we know it’s weird but it’s easier because you can use regex to find {} and ignore the rest. we have try several library but still this is the best we can do for now, if you know better solution please kindly tell us 🙇</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2858b477aecc" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>