How to package `Meshsense` application?

Hello,

I have recently started exploring LoRa networking and Meshtastic.

Out-of-context question: are there people into LoRa and/or Meshtastic in this community?

I would like to package Meshsense for Nix/Nixpkgs. The sources are on GitHub, and the author publishes an AppImage on their website.

I could take the easy route and package the AppImage, but the download URLs do not contain the version number. That means they may change on each new release and potentially break the Nix package (even if development does not seem very fast).

So I would prefer to build the Electron application directly from source. I am not very familiar with packaging Electron apps in Nix yet, so if you have any pointers (good examples in nixpkgs, docs, or common pitfalls), I would really appreciate your help.

If you would like to dive in, here is the package.nix draft I have started from:

pkgs/by-name/me/meshsense/package.nix
{
  lib,
  stdenv,
  fetchFromGitHub,
}:

stdenv.mkDerivation (finalAttrs: {
  pname = "meshsense";
  version = "1.0.18";

  src = fetchFromGitHub {
    owner = "Affirmatech";
    repo = "Meshsense";
    tag = "v${finalAttrs.version}";
    hash = "sha256-f0wxBdP6cToKgxeBfaZz9/qvXHDek1w54TRSYUKaNTM=";
  };

  meta = {
    description = "Directly connects to your Meshtastic node via Bluetooth or WiFi and continuously provides information to assess the health of your mesh network";
    mainProgram = "meshsense";
    homepage = "https://github.com/Affirmatech/MeshSense";
    license = lib.licenses.gpl3Only;
    maintainers = with lib.maintainers; [ drupol ];
    platforms = [ "x86_64-linux" ];
  };
})

Quite complex electron application build using yarn: nixpkgs/pkgs/by-name/jo/joplin-desktop/package.nix at nixos-unstable · NixOS/nixpkgs · GitHub

No idea if that helps.