Skip to content

Instantly share code, notes, and snippets.

View aneudy1702's full-sized avatar

Aneudy Abreu aneudy1702

View GitHub Profile
@aneudy1702
aneudy1702 / dont-div-the-buttons.md
Last active March 30, 2024 02:35
Step into the world of semantic HTML with this guide! Discover the key to unlocking accessible, interactive web elements without relying on <div>s. Perfect for engineers ready to tackle hands-on coding challenges and elevate their understanding of accessibility's role in modern web development.

Disclaimer: This write-up is the first part of a valuable two-part series. While it provides comprehensive resources and requirements to understand the impact of semantic HTML on accessibility, it does not include code solutions. Part 2, which is equally important, will delve into the coding aspect, offering detailed solutions. This version is tailored for workshop use, encouraging hands-on learning and problem-solving.


Don't <div /> Your <button />s

image: a humorous depiction of someone mistakenly using divs as buttons

Here's the 🏃 TL:DR 🏃 version for the speed readers:

@aneudy1702
aneudy1702 / gh-actions-automated-releases.md
Last active January 30, 2024 21:15
Streamlining Software Releases: Combining GitHub Actions with Semantic-Release and Release-Please

DALL·E 2024-01-30 15 48 08 - A modern, digital landscape-oriented illustration symbolizing software automation and GitHub Actions, without any text  The image should convey the es

Streamlining Software Releases: Combining GitHub Actions with Semantic-Release and Release-Please

TL;DR - Summary

Discover streamlined software release processes using GitHub Actions with 'semantic-release' and 'release-please.' This guide compares these tools for different project types, offering practical insights and resources for mastering automated releases.


@aneudy1702
aneudy1702 / Automating_Release_Process_via_Github_Actions.md
Last active January 30, 2024 01:45
Unlock the potential of automated software releases with our in-depth analysis of Semantic-Release vs Release-Please. Discover how these powerful GitHub Actions can transform your development workflow, whether for web applications or libraries. Our comprehensive guide delves into the nuances of each tool, offering practical insights to streamlin…

Automating your Release Process via GitHub Actions

Introduction

In the fast-paced world of software development, efficiency and automation are key. Automating your release process using GitHub Actions can significantly streamline your workflow. This article explores two powerful tools: semantic-release and release-please, focusing on their integration with GitHub Actions.

Semantic-Release as a GitHub Action

semantic-release automates the versioning and package publishing process based on Semantic Versioning principles. Integrated with GitHub Actions, it offers a seamless workflow for software release.

@aneudy1702
aneudy1702 / choosing-release-automation-tool.md
Created January 24, 2024 19:07
When choosing between semantic-release and release-please for managing versioning and releases in your web applications and libraries, several key factors come into play. Below is a technical comparison of both, along with their suitability for different use cases.

DALL·E 2024-01-24 14 00 31 - Create an image symbolizing the software release process and automation in a corporate environment  The image should feature elements like a streamlin

When using both semantic-release and release-please as GitHub Actions, it's important to understand how each tool integrates with GitHub's workflow and automation features. Here's an exploration of how each tool functions within the GitHub Actions framework:

Semantic-Release as a GitHub Action

Integration with GitHub Actions:

  • semantic-release can be set up as a GitHub Action to automate release processes within your GitHub repositories.
  • The action will typically run on specific triggers, like a push to the main branch or a merged pull request.
function maskNumbers(fullNumber, lastCharactersLen){
const last4Digits = fullNumber.slice(-lastCharactersLen);
const maskedNumber = last4Digits.padStart(fullNumber.length, '*');
return last4Digits.padStart(fullNumber.length, '*');
// Expected output: "************5581"
}
@aneudy1702
aneudy1702 / PreventVerticalScrollingWhileSwiping.jsx
Last active March 26, 2020 23:23
React component to lock window scroll while users are horizontally swiping within the container. for example when swiping through a carousel.
import React, { useRef } from 'react';
import get from 'lodash.get';
import throttle from 'lodash.throttle';
const getTouchEndX = event => get(event, 'changedTouches[0].screenX') || 0;
const preventDefault = event => {
event.preventDefault();
event.returnValue = false;
return false;
};
@aneudy1702
aneudy1702 / machine.js
Created September 3, 2019 16:20
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
@aneudy1702
aneudy1702 / averageBetweenTwoHexColors.js
Last active August 1, 2019 18:31
A function that takes 2 colors as arguments and returns the average color.
/**
*
Write a function that takes 2 colors as arguments and returns the average color.
- The parameters will be two 6-digit hexadecimal strings. This does not need to be validated.
- The return value should be a 6-digit hexadecimal string.
- The hexadecimal strings represent colors in RGB, much like in CSS.
- The average color is to be determined by taking the arithmetic mean for each component: red, green and blue.
**/
/**