<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Javascript on mm-dev</title>
    <link>https://mm-dev.rocks/tags/javascript/</link>
    <description>Recent content in Javascript on mm-dev</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en-gb</language>
    <lastBuildDate>Fri, 05 Apr 2024 12:18:03 +0100</lastBuildDate><atom:link href="https://mm-dev.rocks/tags/javascript/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Vanilla JS</title>
      <link>https://mm-dev.rocks/posts/vanilla-js/</link>
      <pubDate>Fri, 05 Apr 2024 12:18:03 +0100</pubDate>
      <guid>https://mm-dev.rocks/posts/vanilla-js/</guid>
      <description>&lt;h2 id=&#34;toolchain&#34;&gt;Toolchain&lt;/h2&gt;
&lt;p&gt;I enjoy using plain/vanilla JS where possible. For my own projects I try to avoid the sprawl and long build times of NPM.&lt;/p&gt;
&lt;p&gt;I do like to split my code up into separate modules though, and to be able to benefit from bundling/minification etc, for which I use &lt;em&gt;esbuild&lt;/em&gt;. I also want to be able to use &lt;em&gt;SCSS&lt;/em&gt; and &lt;em&gt;JSDoc&lt;/em&gt; for type annotations. So I do allow myself some minimal tooling (the cone and Flake).&lt;/p&gt;
&lt;p&gt;My setup looks like this&amp;hellip;&lt;/p&gt;
&lt;h3 id=&#34;esbuild---download-a-build&#34;&gt;esbuild - &lt;a href = &#34;https://esbuild.github.io/getting-started/#download-a-build&#34; target = &#34;_blank&#34; rel = &#34;nofollow noopener noreferrer&#34;&gt;Download a build&lt;/a&gt;&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;JS bundler&lt;br&gt;
&lt;em&gt;Combine separate modules into a single JS file, minifying/compressing if required&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Tree shaker&lt;br&gt;
&lt;em&gt;Avoid bloat by making sure only those modules/functions which are used get added&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;I use esbuild for most JS projects, so I installed a standalone build which can be run from anywhere &amp;mdash; but it can also be installed using npm or other methods.&lt;/p&gt;
&lt;h3 id=&#34;sass---how-to-install-sass&#34;&gt;SASS - &lt;a href = &#34;https://sass-lang.com/install&#34; target = &#34;_blank&#34; rel = &#34;nofollow noopener noreferrer&#34;&gt;How to Install SASS&lt;/a&gt;&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Compiler and bundler&lt;br&gt;
&lt;em&gt;Converts SASS/SCSS files into CSS&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;jsdoc---documentation&#34;&gt;JSDoc - &lt;a href = &#34;https://jsdoc.app/&#34; target = &#34;_blank&#34; rel = &#34;nofollow noopener noreferrer&#34;&gt;Documentation&lt;/a&gt;&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Automated documentation creation&lt;br&gt;
&lt;em&gt;HTML docs for your methods, classes and variables will be created based on your code comments&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Type annotations&lt;br&gt;
&lt;em&gt;Comments in your code can tell JSDoc which data types your code expects&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Type annotations you provide (in specially-formatted comments) will be used to automatically create detailed documentation for your project.&lt;/p&gt;
&lt;p&gt;Docs are created as HTML files, with lots of clickable cross-references. The files can be styled based on a templating system and CSS styling.&lt;/p&gt;
&lt;p&gt;Lots of modern editors/IDEs will also use your type annotations to provide type hints and draw attention to potential problems eg if you try to pass an argument of the wrong type you&amp;rsquo;ll get a warning.&lt;/p&gt;
&lt;h3 id=&#34;example-of-project-setup-using-tmuxvim&#34;&gt;Example of Project Setup Using Tmux/Vim&lt;/h3&gt;
&lt;p&gt;I usually write a simple bash script for most projects. I&amp;rsquo;ll run this script when I want to start a session of working on a specific project.&lt;/p&gt;
&lt;p&gt;Below is an example build script (for &lt;a href = &#34;https://mm-dev.rocks/posts/pipe-dream-web-game/&#34; title = &#34;Pipe Dream&#34; target = &#34;_blank&#34; rel = &#34;nofollow noopener noreferrer&#34;&gt;my &amp;lsquo;Pipe Dream&amp;rsquo; game&lt;/a&gt;) which does the following:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Enters the project directory&lt;/li&gt;
&lt;li&gt;Uses &lt;code&gt;tmux&lt;/code&gt; to open a few window panes/splits:
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;esbuild&lt;/strong&gt; watching for changes to JS&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;SASS&lt;/strong&gt; watching for changes to CSS&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;JSDoc&lt;/strong&gt; watching the &lt;code&gt;src&lt;/code&gt; directory (in reality I&amp;rsquo;d often skip this and run it manually on-demand, as it can be slow)&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;git&lt;/strong&gt; status, pane left open for commits etc&lt;/li&gt;
&lt;li&gt;A simple &lt;strong&gt;Python server&lt;/strong&gt; so I can test the app in a browser&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Opens a &lt;strong&gt;vim&lt;/strong&gt; session with the relevant source files ready for editing&lt;/li&gt;
&lt;/ol&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;cp&#34;&gt;#!/bin/bash
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;cp&#34;&gt;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c1&#34;&gt;# Open a JS project using esbuild, SASS and vim&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nv&#34;&gt;work_dir&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span class=&#34;nv&#34;&gt;$HOME&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt;/pipe-dream/
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;s1&#34;&gt;&amp;#39;tmux&amp;#39;&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    new-window -c &lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span class=&#34;nv&#34;&gt;$work_dir&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;esbuild src/main.js --outfile=www/js/pipe-dream.js --target=es6 --bundle --minify --sourcemap --global-name=PIPEDREAM --format=iife --watch&amp;#34;&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\;&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    split-window -c &lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span class=&#34;nv&#34;&gt;$work_dir&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;sass --watch src/scss/:www/css/&amp;#34;&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\;&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    split-window -c &lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span class=&#34;nv&#34;&gt;$work_dir&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;jsdoc src/ -c jsdoc.config&amp;#34;&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\;&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    split-window -c &lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span class=&#34;nv&#34;&gt;$work_dir&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;git status; bash -i&amp;#34;&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\;&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    split-window -c &lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span class=&#34;nv&#34;&gt;$work_dir&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;python -m http.server --directory www/&amp;#34;&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\;&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    &lt;span class=&#34;k&#34;&gt;select&lt;/span&gt;-layout even-vertical &lt;span class=&#34;se&#34;&gt;\;&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;se&#34;&gt;&lt;/span&gt;    new-window -c &lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span class=&#34;nv&#34;&gt;$work_dir&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;vim -S vim.Session&amp;#34;&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\;&lt;/span&gt; &lt;span class=&#34;se&#34;&gt;\
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h2 id=&#34;vim-configuration&#34;&gt;Vim Configuration&lt;/h2&gt;
&lt;p&gt;I&amp;rsquo;m one of those Vim people. People say its codebase is bloated but in use it always feels crisp and fast to me. Because of the way you manipulate text objects and leap around the page it somehow feels efficient on low-powered/slow devices, and works particularly well with &lt;a href = &#34;https://mm-dev.rocks/posts/oled-and-eink-4-life/intro/&#34; title = &#34;OLED and E-Ink&#34; target = &#34;_blank&#34; rel = &#34;nofollow noopener noreferrer&#34;&gt;e-ink devices&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Some people argue that they&amp;rsquo;re faster while using Vim than they are in other code editors. I&amp;rsquo;m not sure if I&amp;rsquo;m faster (I might be), but I&amp;rsquo;m from the school of thought that if your bottleneck when writing code is your typing speed, that might not be a good thing.&lt;/p&gt;
&lt;p&gt;More importantly for me, I like the way Vim makes you think about text, as beautifully described in this classic stackoverflow answer &amp;lsquo;&lt;a href = &#34;https://stackoverflow.com/questions/1218390/what-is-your-most-productive-shortcut-with-vim/1220118#1220118&#34; target = &#34;_blank&#34; rel = &#34;nofollow noopener noreferrer&#34;&gt;Your problem with Vim is that you don&amp;rsquo;t grok vi&lt;/a&gt;&amp;rsquo;.&lt;/p&gt;
&lt;p&gt;I don&amp;rsquo;t like my coding environment to be too noisy or intrusive, but there are some powerful IDE features available nowadays and I don&amp;rsquo;t want to cut off my nose to spite my face.&lt;/p&gt;
&lt;p&gt;Below is some info on some Vim plugins I use to help with JS development.&lt;/p&gt;
&lt;h3 id=&#34;coc-nvim---code-of-conquer-project-repo&#34;&gt;coc-nvim - &lt;a href = &#34;https://github.com/neoclide/coc.nvim&#34; target = &#34;_blank&#34; rel = &#34;nofollow noopener noreferrer&#34;&gt;Code of Conquer project repo&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;Although the &amp;rsquo;nvim&amp;rsquo; stands for Neovim (the popular Vim fork), COC also works very well in modern versions of normal Vim. This plugin allows VSCode-type IDE features, being based on the &lt;a href = &#34;https://en.wikipedia.org/wiki/Language_Server_Protocol&#34; target = &#34;_blank&#34; rel = &#34;nofollow noopener noreferrer&#34;&gt;Language Server Protocol&lt;/a&gt; standard.&lt;/p&gt;
&lt;p&gt;Very simply, a language server is a tool which understands a specific language, and can be used by your editor/IDE to analyse and give feedback on your code as you write it. It can do things like:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Syntax highlighting&lt;/li&gt;
&lt;li&gt;Code completion&lt;/li&gt;
&lt;li&gt;Draw attention to errors and give warnings about code&lt;/li&gt;
&lt;li&gt;Help when refactoring code&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;COC isn&amp;rsquo;t a language server itself but it allows you to install and maintain whichever servers you need for the languages you use.&lt;/p&gt;
&lt;p&gt;For example the language server I use for JS is &lt;a href = &#34;https://github.com/neoclide/coc-tsserver&#34; target = &#34;_blank&#34; rel = &#34;nofollow noopener noreferrer&#34;&gt;coc-tsserver&lt;/a&gt;. The &amp;rsquo;ts&amp;rsquo; stands for TypeScript but it works very well with standard JS too. Along with the benefits mentioned above, this language server allows you to use type-checking, like TypeScript but without the compilation step. It also provides documentation and hints on using standard built-in JS methods.&lt;/p&gt;
&lt;p&gt;You annotate your code by providing special comments in &lt;em&gt;JSDoc&lt;/em&gt; syntax. When these comments/annotations are present, COC and the language server give you lots of hints while writing code, and warn you if you try to provide arguments of the wrong type.&lt;/p&gt;
&lt;p&gt;Here is an example (from the &lt;a href = &#34;https://jsdoc.app/howto-es2015-classes&#34; target = &#34;_blank&#34; rel = &#34;nofollow noopener noreferrer&#34;&gt;official docs&lt;/a&gt;) showing what the &lt;em&gt;JSDoc&lt;/em&gt; syntax looks like:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-JavaScript&#34; data-lang=&#34;JavaScript&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;cm&#34;&gt;/** Class representing a point. */&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;kr&#34;&gt;class&lt;/span&gt; &lt;span class=&#34;nx&#34;&gt;Point&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;cm&#34;&gt;/**
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;cm&#34;&gt;     * Create a point.
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;cm&#34;&gt;     * @param {number} x - The x value.
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;cm&#34;&gt;     * @param {number} y - The y value.
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;cm&#34;&gt;     */&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;nx&#34;&gt;constructor&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;x&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;nx&#34;&gt;y&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;)&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;        &lt;span class=&#34;c1&#34;&gt;// ...
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c1&#34;&gt;&lt;/span&gt;    &lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;cm&#34;&gt;/**
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;cm&#34;&gt;     * Get the x value.
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;cm&#34;&gt;     * @return {number} The x value.
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;cm&#34;&gt;     */&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;nx&#34;&gt;getX&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;()&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;        &lt;span class=&#34;c1&#34;&gt;// ...
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c1&#34;&gt;&lt;/span&gt;    &lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;cm&#34;&gt;/**
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;cm&#34;&gt;     * Get the y value.
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;cm&#34;&gt;     * @return {number} The y value.
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;cm&#34;&gt;     */&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;nx&#34;&gt;getY&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;()&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;        &lt;span class=&#34;c1&#34;&gt;// ...
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c1&#34;&gt;&lt;/span&gt;    &lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;cm&#34;&gt;/**
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;cm&#34;&gt;     * Convert a string containing two comma-separated numbers into a point.
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;cm&#34;&gt;     * @param {string} str - The string containing two comma-separated numbers.
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;cm&#34;&gt;     * @return {Point} A Point object.
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;cm&#34;&gt;     */&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;kr&#34;&gt;static&lt;/span&gt; &lt;span class=&#34;nx&#34;&gt;fromString&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;str&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;)&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;        &lt;span class=&#34;c1&#34;&gt;// ...
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c1&#34;&gt;&lt;/span&gt;    &lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;em&gt;Sometimes the help is a little noisy though&amp;hellip;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;I love the functionality, but for me it&amp;rsquo;s a bit over-eager, eg if I&amp;rsquo;m half-way through typing a word I don&amp;rsquo;t need a popup telling me the word doesn&amp;rsquo;t exist.&lt;/p&gt;
&lt;p&gt;&lt;em&gt;coc-nvim&lt;/em&gt; does also provide a small symbol at the start of each line where it detects an error or wants to warn about something. So I like to leave the symbol visible, but hide the info popups by default. I add a keyboard shortcut so I can show/hide the explanation of the error/warning when I want to.&lt;/p&gt;
&lt;p&gt;To stop the popups:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-JSON&#34; data-lang=&#34;JSON&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c1&#34;&gt;// In ~/.vim/coc-settings.json
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c1&#34;&gt;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;  &lt;span class=&#34;err&#34;&gt;...&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;  &lt;span class=&#34;nt&#34;&gt;&amp;#34;diagnostic.enableMessage&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;jump&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;  &lt;span class=&#34;err&#34;&gt;...&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;To add the show/hide keyboard shortcuts to Vim:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-VimL&#34; data-lang=&#34;VimL&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c&#34;&gt;&amp;#34; In ~/.vimrc&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nx&#34;&gt;nmap&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;silent&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span class=&#34;nx&#34;&gt;gh&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;Plug&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;(&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;coc&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;float&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;hide&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;)&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nx&#34;&gt;nmap&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;silent&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span class=&#34;nx&#34;&gt;gl&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;Plug&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;(&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;coc&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;diagnostic&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;info&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;)&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h3 id=&#34;prettier&#34;&gt;Prettier&lt;/h3&gt;
&lt;p&gt;This &lt;a href = &#34;https://prettier.io/&#34; target = &#34;_blank&#34; rel = &#34;nofollow noopener noreferrer&#34;&gt;opinionated code formatter&lt;/a&gt; formats your code according to some fairly strict rules and has few configurable options (ie it&amp;rsquo;s their way or the highway).&lt;/p&gt;
&lt;p&gt;I think most people find at least some of the rules disagreeable, but the point of this kind of tool is that it does a &amp;lsquo;decent, not perfect&amp;rsquo; job, but provides a standard for formatting and removes the need for discussing, disagreement and wasted time.&lt;/p&gt;
&lt;p&gt;I found it a little annoying at first but then got over myself and prefer now to use it whenever possible.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Pipe Dream (Web Game)</title>
      <link>https://mm-dev.rocks/posts/pipe-dream-web-game/</link>
      <pubDate>Wed, 15 Nov 2023 16:04:45 +0000</pubDate>
      <guid>https://mm-dev.rocks/posts/pipe-dream-web-game/</guid>
      <description>&lt;p&gt;Pipe Dream is a game you can play in your browser &lt;a href = &#34;/pipe-dream&#34;&gt;here&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;You don&amp;rsquo;t need to log in or install anything and of course there are no ads/tracking.&lt;/p&gt;
&lt;p&gt;The game is about as simple as it gets. There are loads of blobs floating about &amp;mdash; avoid some of them and eat the others.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;To control the player&lt;/strong&gt; move your mouse pointer (or drag your finger) over the &lt;strong&gt;control area&lt;/strong&gt; - a rectangle on the right or bottom of the screen (depending on which way around your display is oriented)&lt;/li&gt;
&lt;li&gt;When you hit one of the &lt;strong&gt;avoid blobs&lt;/strong&gt; you lose &lt;strong&gt;health&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Each level gives you a different amount of &lt;strong&gt;time&lt;/strong&gt; to complete it&lt;/li&gt;
&lt;li&gt;To complete a level, eat all the &lt;strong&gt;edible blobs&lt;/strong&gt; before you run out of &lt;strong&gt;time&lt;/strong&gt;, or &lt;strong&gt;health&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;ul class=&#39;gallery&#39;&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_1&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_1&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-intro.png&#39; alt=&#39;Intro screen&#39; /&gt;
        &lt;span&gt;Intro screen&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_2&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_2&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-basic.png&#39; alt=&#39;Level BASIC&#39; /&gt;
        &lt;span&gt;Level BASIC&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_3&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_3&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-tooez.png&#39; alt=&#39;Level TOOEZ&#39; /&gt;
        &lt;span&gt;Level TOOEZ&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_4&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_4&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-jungl.png&#39; alt=&#39;Level JUNGL&#39; /&gt;
        &lt;span&gt;Level JUNGL&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_5&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_5&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-mauve.png&#39; alt=&#39;Level MAUVE&#39; /&gt;
        &lt;span&gt;Level MAUVE&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_6&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_6&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-rrred.png&#39; alt=&#39;Level RRRED&#39; /&gt;
        &lt;span&gt;Level RRRED&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_7&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_7&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-mustd.png&#39; alt=&#39;Level MUSTD&#39; /&gt;
        &lt;span&gt;Level MUSTD&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_8&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_8&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-mult1.png&#39; alt=&#39;Level MULT1&#39; /&gt;
        &lt;span&gt;Level MULT1&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_9&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_9&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-mult2.png&#39; alt=&#39;Level MULT2&#39; /&gt;
        &lt;span&gt;Level MULT2&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_10&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_10&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-merng.png&#39; alt=&#39;Level MERNG&#39; /&gt;
        &lt;span&gt;Level MERNG&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_11&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_11&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-dense.png&#39; alt=&#39;Level DENSE&#39; /&gt;
        &lt;span&gt;Level DENSE&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_12&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_12&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-reddd.png&#39; alt=&#39;Level REDDD&#39; /&gt;
        &lt;span&gt;Level REDDD&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_13&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_13&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-lmolv.png&#39; alt=&#39;Level LMOLV&#39; /&gt;
        &lt;span&gt;Level LMOLV&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_14&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_14&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-blrds.png&#39; alt=&#39;Level BLRDS&#39; /&gt;
        &lt;span&gt;Level BLRDS&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_15&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_15&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-gardn.png&#39; alt=&#39;Level GARDN&#39; /&gt;
        &lt;span&gt;Level GARDN&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_16&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_16&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-gnsmk.png&#39; alt=&#39;Level GNSMK&#39; /&gt;
        &lt;span&gt;Level GNSMK&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_17&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_17&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-strry.png&#39; alt=&#39;Level STRRY&#39; /&gt;
        &lt;span&gt;Level STRRY&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_18&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_18&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-pekmn.png&#39; alt=&#39;Level PEKMN&#39; /&gt;
        &lt;span&gt;Level PEKMN&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_19&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_19&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-swarm.png&#39; alt=&#39;Level SWARM&#39; /&gt;
        &lt;span&gt;Level SWARM&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_20&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_20&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-wista.png&#39; alt=&#39;Level WISTA&#39; /&gt;
        &lt;span&gt;Level WISTA&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_21&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_21&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-alien.png&#39; alt=&#39;Level ALIEN&#39; /&gt;
        &lt;span&gt;Level ALIEN&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_22&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_22&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-chpln.png&#39; alt=&#39;Level CHPLN&#39; /&gt;
        &lt;span&gt;Level CHPLN&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_23&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_23&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-oprtn.png&#39; alt=&#39;Level OPRTN&#39; /&gt;
        &lt;span&gt;Level OPRTN&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_Qe5h_24&#39; /&gt;
      &lt;label for=&#39;item_Qe5h_24&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/pipe-dream/pd-ntpor.png&#39; alt=&#39;Level NTPOR&#39; /&gt;
        &lt;span&gt;Level NTPOR&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;
&lt;/ul&gt;

</description>
    </item>
    
    <item>
      <title>dontdillydally (Web App)</title>
      <link>https://mm-dev.rocks/posts/dontdillydally-web-app/</link>
      <pubDate>Tue, 10 Oct 2023 13:17:52 +0100</pubDate>
      <guid>https://mm-dev.rocks/posts/dontdillydally-web-app/</guid>
      <description>&lt;p&gt;&lt;strong&gt;dontdillydally&lt;/strong&gt; helps you track time and money.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Aimed at the self-employed&lt;/li&gt;
&lt;li&gt;Focused on simplicity and ease of use&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;As this is a web app you don&amp;rsquo;t need to install it, just go to &lt;a href = &#34;https://dontdillydally.app&#34; target = &#34;_blank&#34; rel = &#34;nofollow noopener noreferrer&#34;&gt;dontdillydally.app&lt;/a&gt; to start using it immediately in your browser.&lt;/p&gt;
&lt;h2 id=&#34;how-to-use&#34;&gt;How to Use&lt;/h2&gt;
&lt;p&gt;&lt;img class=&#34;inline-icon&#34; src=&#34;https://mm-dev.rocks/images/dontdillydally/icon-linnet.png&#34; /&gt;
 &lt;strong&gt;Tap the bird at any time in the app to see the built-in guide&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;br&gt;
On the left-hand side of the app you will see icons which you can tap to change which section you&amp;rsquo;re on or perform other functions.&lt;/p&gt;






&lt;div class=&#34;expand-all-toggle&#34;&gt;
    &lt;label for=&#34;expandAllCheckbox_Ag43&#34;&gt;&lt;h3 id=&#34;tap-below-to-expand-each-section-and-learn-more-about-it&#34;&gt;Tap below to expand each section and learn more about it:&lt;/h3&gt;
&lt;span&gt;Expand all&lt;/span&gt;
      &lt;input id=&#34;expandAllCheckbox_Ag43&#34; type=&#34;checkbox&#34; onchange=&#34;setChildExpandedStates_Ag43();&#34;/&gt;
    &lt;/label&gt;
  
  &lt;script&gt;
    function setChildExpandedStates_Ag43() {
      var checkbox_el = document.getElementById(&#39;expandAllCheckbox_Ag43&#39;);
      var all = checkbox_el.parentNode.parentNode.getElementsByTagName(&#39;details&#39;);
      for (i = 0; i &lt; all.length; i++) { 
        all[i].open = checkbox_el.checked;
      }
    }
    window.addEventListener(&#39;load&#39;, () =&gt; {
      document.getElementById(&#39;expandAllCheckbox_Ag43&#39;).parentNode.parentNode.classList.add(&#39;js-visible&#39;);
      setChildExpandedStates_Ag43();
    });
  &lt;/script&gt;
&lt;details&gt;
&lt;summary&gt;&lt;span&gt;&lt;img class=&#34;inline-icon&#34; src=&#34;https://mm-dev.rocks/images/dontdillydally/icon-worksheet.png&#34; /&gt;
 Worksheet&lt;/span&gt;&lt;/summary&gt;

&lt;div&gt;
&lt;p&gt;This is the page you&amp;rsquo;ll use the most, it&amp;rsquo;s where you enter your hours worked and any money coming in or going out.&lt;/p&gt;
&lt;p&gt;A worksheet is made of &lt;strong&gt;entries&lt;/strong&gt;. An &lt;strong&gt;entry&lt;/strong&gt; is one of the following:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;time&lt;/strong&gt; spent on a specific job&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;money&lt;/strong&gt; spent on something (expenses)&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;money&lt;/strong&gt; coming in (income)&lt;/li&gt;
&lt;/ul&gt;
&lt;blockquote&gt;
&lt;p&gt;To add an entry, just tap on the date where you want to add it&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;Each &lt;strong&gt;entry&lt;/strong&gt; can have a &lt;strong&gt;client&lt;/strong&gt; and/or a &lt;strong&gt;job&lt;/strong&gt; selected. If you do this you&amp;rsquo;ll then be able to get a &lt;strong&gt;report&lt;/strong&gt; showing you how many hours you worked on that job/client, or how much money you made or spent.&lt;/p&gt;
&lt;p&gt;You can also add &lt;strong&gt;Notes&lt;/strong&gt; to an entry.&lt;/p&gt;
&lt;p&gt;&lt;em&gt;All data fields in an entry are optional, add as much or as little info as you like.&lt;/em&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;By default when you add a new &lt;strong&gt;entry&lt;/strong&gt; it will be a &lt;strong&gt;time&lt;/strong&gt; entry, and show a &lt;strong&gt;clock icon&lt;/strong&gt; next to it.&lt;/li&gt;
&lt;li&gt;If you tap the clock, the icon changes to a &lt;strong&gt;credit card&lt;/strong&gt; and the entry becomes a &lt;strong&gt;money&lt;/strong&gt; entry.&lt;/li&gt;
&lt;li&gt;To enter an expense, set the value of a money entry to something negative eg &lt;code&gt;-100.00&lt;/code&gt; means you spent 100.&lt;/li&gt;
&lt;/ul&gt;
&lt;ul class=&#39;gallery&#39;&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_e8Hs_1&#39; /&gt;
      &lt;label for=&#39;item_e8Hs_1&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/dontdillydally/time-entry-1.png&#39; alt=&#39;Worksheet: Time entry&#39; /&gt;
        &lt;span&gt;Worksheet: Time entry&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_e8Hs_2&#39; /&gt;
      &lt;label for=&#39;item_e8Hs_2&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_e8Hs_3&#39; /&gt;
      &lt;label for=&#39;item_e8Hs_3&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_e8Hs_4&#39; /&gt;
      &lt;label for=&#39;item_e8Hs_4&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;/label&gt;
    &lt;/li&gt;
&lt;/ul&gt;
&lt;/div&gt;
&lt;/details&gt;


&lt;details&gt;
&lt;summary&gt;&lt;span&gt;&lt;img class=&#34;inline-icon&#34; src=&#34;https://mm-dev.rocks/images/dontdillydally/icon-reports.png&#34; /&gt;
 Reports&lt;/span&gt;&lt;/summary&gt;

&lt;div&gt;
&lt;p&gt;Here you can get a clear view of everything entered into an entire worksheet, or narrow down on a specific job or client:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Choose a date range from within your worksheet&lt;/li&gt;
&lt;li&gt;Choose a specfic client or job&lt;/li&gt;
&lt;li&gt;Look at only money in/out (hide hours)&lt;/li&gt;
&lt;li&gt;Look at only hours worked (hide money)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Then you&amp;rsquo;ll be able to see:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;How much time you&amp;rsquo;ve spent&lt;/li&gt;
&lt;li&gt;How much you&amp;rsquo;ve earned&lt;/li&gt;
&lt;li&gt;A list of all worksheet entries matching your selection showing eg time, monetary values, notes&lt;/li&gt;
&lt;/ul&gt;
&lt;ul class=&#39;gallery&#39;&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_ZVCf_1&#39; /&gt;
      &lt;label for=&#39;item_ZVCf_1&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/dontdillydally/report-bs-1.png&#39; alt=&#39;Reports: &amp;#39;BendyStraw&amp;#39; job selection&#39; /&gt;
        &lt;span&gt;Reports: &amp;#39;BendyStraw&amp;#39; job selection&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_ZVCf_2&#39; /&gt;
      &lt;label for=&#39;item_ZVCf_2&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/dontdillydally/report-bs-2.png&#39; alt=&#39;Reports: &amp;#39;BendyStraw&amp;#39; job results&#39; /&gt;
        &lt;span&gt;Reports: &amp;#39;BendyStraw&amp;#39; job results&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_ZVCf_3&#39; /&gt;
      &lt;label for=&#39;item_ZVCf_3&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;/label&gt;
    &lt;/li&gt;
&lt;/ul&gt;
&lt;/div&gt;
&lt;/details&gt;


&lt;details&gt;
&lt;summary&gt;&lt;span&gt;&lt;img class=&#34;inline-icon&#34; src=&#34;https://mm-dev.rocks/images/dontdillydally/icon-jobs-clients.png&#34; /&gt;
 Jobs and Clients&lt;/span&gt;&lt;/summary&gt;

&lt;div&gt;
&lt;ul class=&#39;gallery float single-item&#39;&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_s9CR_1&#39; /&gt;
      &lt;label for=&#39;item_s9CR_1&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;/label&gt;
    &lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Jobs&lt;/strong&gt; and &lt;strong&gt;Clients&lt;/strong&gt; can be created and edited here, including:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;A name for the job or client&lt;/li&gt;
&lt;li&gt;Colours (foreground and background) used to represent the job or client in the app&lt;/li&gt;
&lt;/ul&gt;&lt;/div&gt;
&lt;/details&gt;

&lt;details&gt;
&lt;summary&gt;&lt;span&gt;&lt;img class=&#34;inline-icon&#34; src=&#34;https://mm-dev.rocks/images/dontdillydally/icon-settings.png&#34; /&gt;
 Settings&lt;/span&gt;&lt;/summary&gt;

&lt;div&gt;
&lt;/div&gt;
&lt;/details&gt;
&lt;/div&gt;







&lt;div class=&#34;expand-all-toggle&#34;&gt;
    &lt;label for=&#34;expandAllCheckbox_eYra&#34;&gt;&lt;h3 id=&#34;the-other-icons-perform-actions-immediately-without-changing-the-page&#34;&gt;The other icons perform actions immediately without changing the page:&lt;/h3&gt;
&lt;span&gt;Expand all&lt;/span&gt;
      &lt;input id=&#34;expandAllCheckbox_eYra&#34; type=&#34;checkbox&#34; onchange=&#34;setChildExpandedStates_eYra();&#34;/&gt;
    &lt;/label&gt;
  
  &lt;script&gt;
    function setChildExpandedStates_eYra() {
      var checkbox_el = document.getElementById(&#39;expandAllCheckbox_eYra&#39;);
      var all = checkbox_el.parentNode.parentNode.getElementsByTagName(&#39;details&#39;);
      for (i = 0; i &lt; all.length; i++) { 
        all[i].open = checkbox_el.checked;
      }
    }
    window.addEventListener(&#39;load&#39;, () =&gt; {
      document.getElementById(&#39;expandAllCheckbox_eYra&#39;).parentNode.parentNode.classList.add(&#39;js-visible&#39;);
      setChildExpandedStates_eYra();
    });
  &lt;/script&gt;

&lt;details&gt;
&lt;summary&gt;&lt;span&gt;&lt;img class=&#34;inline-icon&#34; src=&#34;https://mm-dev.rocks/images/dontdillydally/icon-maximise.png&#34; /&gt;
 Minimise/maximise menu&lt;/span&gt;&lt;/summary&gt;

&lt;div&gt;
&lt;blockquote&gt;
&lt;p&gt;Toggles whether the menu is minimised or maximised.&lt;/p&gt;&lt;/blockquote&gt;
&lt;table&gt;
  &lt;thead&gt;
      &lt;tr&gt;
          &lt;th style=&#34;text-align: right&#34;&gt;&lt;/th&gt;
          &lt;th style=&#34;text-align: left&#34;&gt;&lt;/th&gt;
      &lt;/tr&gt;
  &lt;/thead&gt;
  &lt;tbody&gt;
      &lt;tr&gt;
          &lt;td style=&#34;text-align: right&#34;&gt;&lt;strong&gt;Minimised&lt;/strong&gt;&lt;/td&gt;
          &lt;td style=&#34;text-align: left&#34;&gt;Show only icons&lt;/td&gt;
      &lt;/tr&gt;
      &lt;tr&gt;
          &lt;td style=&#34;text-align: right&#34;&gt;&lt;strong&gt;Maximised&lt;/strong&gt;&lt;/td&gt;
          &lt;td style=&#34;text-align: left&#34;&gt;Show icons + text labels&lt;/td&gt;
      &lt;/tr&gt;
  &lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;
&lt;/details&gt;

&lt;details&gt;
&lt;summary&gt;&lt;span&gt;&lt;img class=&#34;inline-icon&#34; src=&#34;https://mm-dev.rocks/images/dontdillydally/icon-sync.png&#34; /&gt;
 WebDAV sync&lt;/span&gt;&lt;/summary&gt;

&lt;div&gt;
&lt;p&gt;This is an experimental feature to sync your data to a WebDAV server so you can keep several devices in sync.&lt;/p&gt;
&lt;p&gt;It&amp;rsquo;s a work-in-progress and not really recommended for most users at this point.&lt;/p&gt;
&lt;/div&gt;
&lt;/details&gt;

&lt;details&gt;
&lt;summary&gt;&lt;span&gt;&lt;img class=&#34;inline-icon&#34; src=&#34;https://mm-dev.rocks/images/dontdillydally/icon-download.png&#34; /&gt;
 Download data as file&lt;/span&gt;&lt;/summary&gt;

&lt;div&gt;
Tap this to download all of your data and settings in a file. It will usually end up in your main &lt;code&gt;Downloads&lt;/code&gt; folder.&lt;/div&gt;
&lt;/details&gt;

&lt;details&gt;
&lt;summary&gt;&lt;span&gt;&lt;img class=&#34;inline-icon&#34; src=&#34;https://mm-dev.rocks/images/dontdillydally/icon-upload.png&#34; /&gt;
 Upload data file&lt;/span&gt;&lt;/summary&gt;

&lt;div&gt;
&lt;p&gt;If you have a file you previously downloaded you can bring that data back into the app with this button.&lt;/p&gt;
&lt;p&gt;When importing the data you will be given the option to &lt;code&gt;Merge&lt;/code&gt; or &lt;code&gt;Overwrite&lt;/code&gt; your current data.&lt;/p&gt;
&lt;/div&gt;
&lt;/details&gt;

&lt;details&gt;
&lt;summary&gt;&lt;span&gt;&lt;img class=&#34;inline-icon&#34; src=&#34;https://mm-dev.rocks/images/dontdillydally/icon-email.png&#34; /&gt;
 Email data to a preconfigured address&lt;/span&gt;&lt;/summary&gt;

&lt;div&gt;
You need to set an email address in &lt;code&gt;Settings&lt;/code&gt; for this option to work.
Your device also needs to know what to do with &lt;code&gt;mailto:&lt;/code&gt; links.&lt;/div&gt;
&lt;/details&gt;

&lt;details&gt;
&lt;summary&gt;&lt;span&gt;&lt;img class=&#34;inline-icon&#34; src=&#34;https://mm-dev.rocks/images/dontdillydally/icon-wipe.png&#34; /&gt;
 Wipe your data&lt;/span&gt;&lt;/summary&gt;

&lt;div&gt;
Completely wipe all of your data and start fresh.&lt;/div&gt;
&lt;/details&gt;


&lt;/div&gt;

&lt;h2 id=&#34;data-storage&#34;&gt;Data Storage&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Automatically saved continually while you work &lt;em&gt;The bird&amp;rsquo;s eye spins when changes are being saved, this is intentionally kept subtle but can be disabled in settings&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Your data is stored inside your browser and stays on your device, it never travels over the internet (unless you decide to send it via email) and is not stored on any servers&lt;/li&gt;
&lt;li&gt;Data uses a simple JSON format, it can be exported/imported as a file to move it between devices&lt;/li&gt;
&lt;/ul&gt;
</description>
    </item>
    
    <item>
      <title>Jumble Art Portfolio</title>
      <link>https://mm-dev.rocks/posts/jumble-art-portfolio/</link>
      <pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate>
      <guid>https://mm-dev.rocks/posts/jumble-art-portfolio/</guid>
      <description>&lt;p&gt;&lt;em&gt;Jumble&lt;/em&gt; is all of my art, all piled up on the metaphorical scrapheap where the modern world seems to have put art :)&lt;/p&gt;
&lt;p&gt;Just messing, this was actually a fun project where I got to learn a lot of 3D stuff that was new to me, and build some familiarity with Three.js (which is really nice). I also dipped my toe in to WASM modules for the first time and worked with Rapier physics engine.&lt;/p&gt;
&lt;h3 id=&#34;full-write-up-coming-soon&#34;&gt;Full write-up COMING SOON!&lt;/h3&gt;
&lt;ul class=&#39;gallery&#39;&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_jCIx_1&#39; /&gt;
      &lt;label for=&#39;item_jCIx_1&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/jumble/jumble-grab-4.webp&#39; alt=&#39;Paintings falling into pile&#39; /&gt;
        &lt;span&gt;Paintings falling into pile&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_jCIx_2&#39; /&gt;
      &lt;label for=&#39;item_jCIx_2&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/jumble/jumble-grab-2.webp&#39; alt=&#39;Zoomed-out pile&#39; /&gt;
        &lt;span&gt;Zoomed-out pile&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;&lt;li&gt;
      &lt;input type=&#39;checkbox&#39; id=&#39;item_jCIx_3&#39; /&gt;
      &lt;label for=&#39;item_jCIx_3&#39; aria-label=&#39;Expand image&#39; tabindex=&#39;0&#39;&gt;&lt;img src=&#39;https://mm-dev.rocks/images/jumble/jumble-grab-9.webp&#39; alt=&#39;Pile close-up&#39; /&gt;
        &lt;span&gt;Pile close-up&lt;/span&gt;&lt;/label&gt;
    &lt;/li&gt;
&lt;/ul&gt;

</description>
    </item>
    
  </channel>
</rss>
