<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Agorakit</title>
    <description>The latest articles on DEV Community by Agorakit (@agorakit).</description>
    <link>https://dev.to/agorakit</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F161488%2F331bd74e-be9b-47bb-9b62-178128089988.png</url>
      <title>DEV Community: Agorakit</title>
      <link>https://dev.to/agorakit</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/agorakit"/>
    <language>en</language>
    <item>
      <title>How I suck at javascript and how I managed to avoid it as much as possible.</title>
      <dc:creator>Agorakit</dc:creator>
      <pubDate>Tue, 13 Jul 2021 06:19:06 +0000</pubDate>
      <link>https://dev.to/agorakit/how-i-suck-at-javascript-and-how-i-managed-to-avoid-it-as-much-as-possible-3cb4</link>
      <guid>https://dev.to/agorakit/how-i-suck-at-javascript-and-how-i-managed-to-avoid-it-as-much-as-possible-3cb4</guid>
      <description>&lt;p&gt;or How can a lonely backend developer survive in the ever changing landscape of frontend tooling ?&lt;/p&gt;

&lt;p&gt;I have been writing code since I’m 10 years old. At that time (late 80’s) all I had was a pocket calculator with some obscure basic language full of line numbers and goto’s. After that, Turbo Pascal, then Delphi, then Php, then Python with Zope (who knows Zope nowadays?) then back to PHP for the ease of hosting anywhere (I made my own cms like everyone at that time) then added Drupal to the stack, then Laravel for the real enlightenment (and back to python and C for hardware stuff on raspberry and arduino). But enough about my programmer’s path, this was just to say I’m not against learning new stuff :-)&lt;/p&gt;

&lt;p&gt;Why do I suck at JS ? Biased arguments follow :&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Debugging in the browser is painful for me, I never know which file and line number is giving me problems. Or is it because some npm installed package dependency broke it all? Or is it because I’m too old for this sh*** ?&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;I always fear doing a npm update (even installs sometimes give problems if you don’t have the correct npm version), I understand that’s because I don’t use it enough, but I told you I’m biased.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;I really dislike closures because I don’t fully understand the syntax and it looks ugly to my eyes.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;I can’t fully wrap my head around the concept of promises.&lt;br&gt;
Async programming is not my cup of tea either.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;I probably dislike the node run model but I don’t even know for sure, it’s too obscure.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;I love the backend. I love PHP.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;A few years ago, I started a project called “Agorakit”, it’s a groupware (communication &amp;amp; organization tool) for citizen collectives. It is developed/maintained mainly by one (me) but used by thousands of users on several instances. It is open source and available at &lt;a href="https://github.com/agorakit/agorakit"&gt;https://github.com/agorakit/agorakit&lt;/a&gt; (feel free to star it or dare I ask, contribute :-)). You can test a live instance on &lt;a href="https://app.agorakit.org"&gt;https://app.agorakit.org&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;In this world of ever changing frontend tooling, one might be tempted to use the latest and greatest stack. Speaking of stack, I’m not sure it’s really possible to be a “full stack developer” : I feel this is overrated and you can’t be a jack of all trades, but when you work almost alone on a project, you need to touch a lot of areas including user support, feature prioritization, mobile support, security, ease of use, etc. I really can’t be a jack of all trades.&lt;/p&gt;

&lt;p&gt;For frontend work I still needed to find a way to provide the kind of user experience javascript allows, and at some point, since this is not my job (Agorakit is a side project), I choose to limit my scope to Laravel, and needed a way to avoid “feature creep” my brain if this is a word. Javascript would not play a big part of this strategy.&lt;/p&gt;

&lt;p&gt;How can a lonely backend developer survive in the ever changing landscape of frontend tooling ?&lt;/p&gt;

&lt;p&gt;With all this said, Vue, React, SPA’s, even trusty Jquery or new Alpine are out of reach for my quest of simplicity (and my love for the backend).&lt;/p&gt;

&lt;p&gt;One of the emerging solutions is to rely on third party tools that hide complexity (but are themselves very complex) : Livewire is one example. I like the fact that it does a lot for me, but I also don’t like the fact that it does so much because then I rely on a big stack I don’t fully understand and when something fails you get to dig deep down to fix the bug. Back to Zope days it was the same problem : smart abstractions,  but when they leak, they break badly,  and you are on your own to fix the monster you just created.&lt;/p&gt;

&lt;p&gt;Since I’d prefer to keep the complexity low and not rely on a  (imho) very specific toolset, I decided to go the opposite way : HATEOAS&lt;/p&gt;

&lt;p&gt;HATEOAS is HTML over the wire (or more properly “Hypermedia as the Engine of Application State”).&lt;br&gt;
It is advocated by htmx, turbolinks (now hotwire/turbo). The idea is that you send html to the client and the client can directly use it, no need for complex json-&amp;gt;html transform on the client using javascript. Html after all is a structured language that can be used, queried, injected, transformed if needed and finally rendered by the browser.&lt;/p&gt;

&lt;p&gt;HTMX is a big proponent of this method, although it’s not strictly progressive app enhancement (you can’t remove it once you use it).&lt;/p&gt;

&lt;p&gt;But there is another hidden gem which is my secret weapon : &lt;a href="https://unpoly.com/"&gt;Unpoly JS&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Unpoly JS takes that philosophy one step further :&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;you create your server rendered html application as usual including links, forms, navigation, etc.&lt;/li&gt;
&lt;li&gt;When everything works “old style”, you just add a few html attributes to links and forms to magically, progressively transform your web application to a lookalike single page app.&lt;/li&gt;
&lt;li&gt;At any point you can even remove unpoly from your tooling, your app will still work!
&lt;/li&gt;
&lt;li&gt;Dare I say your app will still work with javascript disabled in the browser? (except for those js libs you use for fancy calendars, maps, dropdowns...)&lt;/li&gt;
&lt;li&gt;your testing toolkit does not even need to be JS aware for testing forms and links since your app does not rely on them. This means you can use a fast testing framework (no need to spin a complete headless browser for testing the app)&lt;/li&gt;
&lt;li&gt;This is what I call progressive app-feeling enhancement. OR progressive spa-fication of a server rendered app.&lt;/li&gt;
&lt;li&gt;You can optimize your backend to return only the html part that will be updated, unpoly will take care of parsing the html and inserting it in the page. Since “premature optimization is the root of all evils”, and since this is mostly needed for write operations (that are much less frequent), I almost never optimize the code.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Here is a small commit on Agorakit that enhances a classic server-side search page to a lovely, as you type, search page : &lt;a href="https://github.com/agorakit/agorakit/commit/0247f0c760dad2ccd27fb49aff60b615260f35b6#diff-c7eb4cf5ffcca2f641738388b14862d88e6f02ab38805afc957d9f4ad27fb1f6"&gt;https://github.com/agorakit/agorakit/commit/0247f0c760dad2ccd27fb49aff60b615260f35b6#diff-c7eb4cf5ffcca2f641738388b14862d88e6f02ab38805afc957d9f4ad27fb1f6&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;Test it live here : &lt;a href="https://app.agorakit.org/groups"&gt;https://app.agorakit.org/groups&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;Notice how only a few attributes are needed to make it work flawlessly. What those snippets do :&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;up-autosubmit allows the form to be auto submitted on user change&lt;/li&gt;
&lt;li&gt;up-delay defines the delay to wait after keypresses to avoid overloading the server&lt;/li&gt;
&lt;li&gt;up-target defines which part of the page must be updated&lt;/li&gt;
&lt;li&gt;up-reveal=”false” disables scrolling to the updated part of the page.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Unpoly recently released V2 of the library, I didn’t upgrade yet, but it seems quite easy to do and will provide very nice “infinite layers” support (create a company while creating a project kind of interactions).&lt;/p&gt;

&lt;p&gt;While this strategy will not work for all projects, in my specific case it really pays.&lt;/p&gt;

&lt;p&gt;Check out the git commits I mentioned, try Unpoly on your next project, trust the HTML, this might be the new-old way of the future.&lt;/p&gt;

&lt;p&gt;Originally published on my almost never updated blog (but I’m willing to write more articles like that if I get feedback) at &lt;a href="https://123piano.com"&gt;https://123piano.com&lt;/a&gt; &lt;/p&gt;

</description>
    </item>
    <item>
      <title>Agorakit is looking for developers</title>
      <dc:creator>Agorakit</dc:creator>
      <pubDate>Tue, 28 Apr 2020 14:58:18 +0000</pubDate>
      <link>https://dev.to/agorakit/agorakit-is-looking-for-developers-11l4</link>
      <guid>https://dev.to/agorakit/agorakit-is-looking-for-developers-11l4</guid>
      <description>&lt;p&gt;Agorakit, the open source groupware for collectives is in intense use due to covid-19 on the free hosted instance here : &lt;a href="https://app.agorakit.org"&gt;https://app.agorakit.org&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;Would you like to contribute to a cool Laravel 7 based project used by thousands of users? Would you like your contribution to help groups in need of better organization tool in this weird period?&lt;/p&gt;

&lt;p&gt;Your help will be highly appreciated and mentorship WILL be provided.&lt;/p&gt;

&lt;p&gt;Please read the contributing document here : &lt;a href="https://github.com/agorakit/agorakit/blob/master/CONTRIBUTING.md"&gt;https://github.com/agorakit/agorakit/blob/master/CONTRIBUTING.md&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Thank you !!!&lt;/p&gt;

</description>
      <category>opensource</category>
      <category>help</category>
      <category>contributorswanted</category>
      <category>laravel</category>
    </item>
    <item>
      <title>Agorakit is looking for more developers</title>
      <dc:creator>Agorakit</dc:creator>
      <pubDate>Wed, 08 May 2019 21:19:05 +0000</pubDate>
      <link>https://dev.to/agorakit/agorakit-is-looking-for-more-developers-1ana</link>
      <guid>https://dev.to/agorakit/agorakit-is-looking-for-more-developers-1ana</guid>
      <description>&lt;p&gt;Agorakit is web-based, open source groupware for citizens.&lt;br&gt;
By creating collaborative groups, people can discuss topics, organize events, store files and keep everyone updated as needed.&lt;br&gt;
Agorakit is a forum, calendar, file manager, mapping tool and email notifier. &lt;/p&gt;

&lt;p&gt;Fist have a look at our presentation website : &lt;a href="https://agorakit.org"&gt;https://agorakit.org&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Then, you'd like to contribute to agorakit? Thank you !&lt;/p&gt;

&lt;h2&gt;
  
  
  You are a communication &amp;amp; support person?
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Talk about the project to people who might need it&lt;/li&gt;
&lt;li&gt;Install it for non technical users/friends/groups&lt;/li&gt;
&lt;li&gt;Help on the translations / add new translations&lt;/li&gt;
&lt;li&gt;Write end users documentation&lt;/li&gt;
&lt;li&gt;Enhance the presentation website with pictures and better texts. It's all there waiting for your pull requests : &lt;a href="https://github.com/philippejadin/agorakit-website"&gt;https://github.com/philippejadin/agorakit-website&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Support existing users (I'm considering the creation of a support forum using... agorakit, let me know what you think)&lt;/li&gt;
&lt;li&gt;Send me an email if you use the tool or are considering it. I love feedback! (info (at) agorakit.org)&lt;/li&gt;
&lt;/ul&gt;

&lt;blockquote&gt;
&lt;p&gt;There are tons of way to contribute, everything is highly appreciated.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  You are a developer proficient with laravel/php/html/css/js?
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;You are a backend developer with experience of the Laravel framework: add new features, fix bug, write tests, document everything. I happily accept pull requests if they pass unit tests and follow the project philosophy&lt;/li&gt;
&lt;li&gt;You are a frontend developer with experience of the Laravel framework: the current UI is not pretty, make it brilliant. Fix UX as you see fit. I happily accept pull requests if they pass unit tests and follow the project philosophy. We don't want the project to become a one page app powered by the latest "à la mode" js framework.&lt;/li&gt;
&lt;li&gt;If you have some time to give to this project, there are already some issues to fix (see. &lt;a href="https://github.com/philippejadin/agorakit/issues"&gt;https://github.com/philippejadin/agorakit/issues&lt;/a&gt;). Whether you have one hour per day or one hour per month, help is really appreciated! And remember, "talk is silver, code is gold" :-)&lt;/li&gt;
&lt;li&gt;Let's talk in the issue queue if your idea involves big changes.&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>contributorswanted</category>
    </item>
  </channel>
</rss>
