Skip to content

Instantly share code, notes, and snippets.

View wiesson's full-sized avatar

Arne Wiese wiesson

View GitHub Profile
---
name: svelte5-migration-fixer
description: Use this agent when you need to scan and fix deprecated Svelte 5 patterns in your codebase, particularly after writing new code or modifying existing Svelte components. This includes fixing $derived usage patterns, SelectValue components, let:builder patterns, asChild props, and incorrect lucide icon imports. <example>Context: The user wants to ensure their recently modified Svelte components follow the latest Svelte 5 patterns.\nuser: "I've just updated the user profile component"\nassistant: "I'll review the component for any deprecated patterns"\n<commentary>Since code was recently modified, use the svelte5-migration-fixer agent to scan for and fix deprecated patterns.</commentary>\nassistant: "Let me use the svelte5-migration-fixer agent to check for deprecated Svelte 5 patterns in the recently changed files"</example> <example>Context: User has written new Svelte components and wants to ensure they follow current best practices.\nuser: "Please create a new m
import * as React from "react";
class TimeField extends React.Component {
constructor(props) {
super(props);
this.state = {
value: "00:00 am",
isValid: true,
hour: 0,
minute: 0
function *fibonacci(n: number, current: number = 0, next: number = 1) {
if (n === 0) {
return current;
}
yield current;
yield *fibonacci(n-1, next, current + next);
}
@Path("people/{personId}")
private static class PersonResource {
@PathParam("personId")
protected long personId;
@GET
public Person getPerson() {
return null;
}

Keybase proof

I hereby claim:

  • I am wiesson on github.
  • I am wiesson (https://keybase.io/wiesson) on keybase.
  • I have a public key ASB3dBngrq8NoTDPP1gm8yCXtRFjkCgM14ng_jM0ZOqpQAo

To claim this, I am signing this object:

@wiesson
wiesson / AWS Swarm cluster.md
Created August 22, 2017 11:59
Create a Docker 1.12 Swarm cluster on AWS

This gist will drive you through creating a Docker 1.12 Swarm cluster (with Swarm mode) on AWS infrastructure.

Prerequisites

You need a few things already prepared in order to get started. You need at least Docker 1.12 set up. I was using the stable version of Docker for mac for preparing this guide.

$ docker --version
Docker version 1.12.0, build 8eab29e

You also need Docker machine installed.

@wiesson
wiesson / AWS Swarm cluster.md
Created August 22, 2017 11:28 — forked from ghoranyi/AWS Swarm cluster.md
Create a Docker 1.12 Swarm cluster on AWS

This gist will drive you through creating a Docker 1.12 Swarm cluster (with Swarm mode) on AWS infrastructure.

Prerequisites

You need a few things already prepared in order to get started. You need at least Docker 1.12 set up. I was using the stable version of Docker for mac for preparing this guide.

$ docker --version
Docker version 1.12.0, build 8eab29e

You also need Docker machine installed.

@wiesson
wiesson / .block
Last active June 6, 2017 13:48 — forked from mbostock/.block
Sankey Diagram
border: no
license: gpl-3.0
print({k: chr(k) for k in range(32, 128)})
from django.db.models import ImageField
from django.dispatch import receiver
from django.db import models
class ResponsiveImageField(ImageField):
def __init__(self, verbose_name=None, name=None, width_field=None, height_field=None, **kwargs):
super(ResponsiveImageField, self).__init__(verbose_name, name, width_field, height_field, **kwargs)
def save(self, *args, **kwargs):