Skip to content

Instantly share code, notes, and snippets.

View AhsanAyaz's full-sized avatar

Muhammad Ahsan Ayaz AhsanAyaz

View GitHub Profile
@AhsanAyaz
AhsanAyaz / angular-book-ai-agent-crew.md
Created July 6, 2026 09:04
The sanitized AI agent crew (Claude Code) that shipped an Angular v22 book update - definitions + the one discipline that made them work

The AI agent crew that shipped an Angular v22 book update

These are the sanitized definitions of the Claude Code agent crew from the case study "I Shipped an Angular v22 Book Update with a Crew of AI Agents. Here's the System" (https://blog.codewithahsan.dev/ai-agent-crew-book-update).

They are skeletons: the frontmatter shape, tools, and the core discipline of each agent, with project-specific strategy (pricing, coupons, sales targets, competitor research, internal paths) redacted. Drop a file per agent in .claude/agents/ and adapt to your own project.

@AhsanAyaz
AhsanAyaz / AGENTS.md
Last active September 27, 2025 10:40
Agents.md example for facebook reel

AGENTS.md – Project Sentinel (Operational Context)

Audience: Coding agents/codegen tools [6] Goal: Ensure all generated code adheres to security rules, stylistic patterns, and uses Model Context Protocol (MCP) servers for dependency validation and complex task decomposition [2, 17].

🛠 Setup and Environment Commands

The agent should use the following commands for automated execution and validation:

  • Install Dependencies: pnpm install [10]
@AhsanAyaz
AhsanAyaz / config for bash_aliases.txt
Last active March 29, 2025 00:46
Cloudways Pet Markt BE bash_aliases setup
cd && echo "export PATH='$PATH:/home/master/.nvm/versions/node/v22.14.0/lib/node_modules/npm'" >> ~/.bash_aliases
cd ~ && echo "export NODE_PATH='$NODE_PATH:/home/master/.nvm/versions/node/v22.14.0/lib/node_modules/npm/lib/node_modules'" >> ~/.bash_aliases
@AhsanAyaz
AhsanAyaz / gist:aec1096a3850e9a87bd70ae91230496a
Created November 12, 2024 08:40
ahsanayaz-vscode-extensions.txt
adam-bender.commit-message-editor
adpyke.codesnap
ahmadalli.vscode-nginx-conf
ahmadawais.shades-of-purple
alexkrechik.cucumberautocomplete
andrew-codes.cypress-snippets
angular.ng-template
anysphere.pyright
astro-build.astro-vscode
atian25.copy-syntax
@AhsanAyaz
AhsanAyaz / Spirograph.html
Created July 7, 2024 21:04
A simple web app showing how to create a spirograph with just html and javascript using SVG and line elements
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Spirograph</title>
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link
href="https://fonts.googleapis.com/css2?family=Nunito:ital,wght@0,200..1000;1,200..1000&display=swap"
@AhsanAyaz
AhsanAyaz / index.html
Created October 19, 2023 11:54
ReaveaJS Video Full Screen
<!-- Add this before your HTML's closing body tag -->
<script>
Reveal.initialize({
controls: true,
progress: true,
history: true,
center: true,
plugins: [
RevealMarkdown,
@AhsanAyaz
AhsanAyaz / user.service.spec-with-mock-users.ts
Created July 19, 2023 07:58
Snippet for ng-test-http-resp including mock users
it('should return expected user data (HttpClient called once)', () => {
const mockUsers: User[] = [
{
id: 1,
name: 'User A',
email: 'userA@example.com',
username: 'userA',
address: {
street: 'sample street 1',
suite: '123 ABC',
@AhsanAyaz
AhsanAyaz / counter.component.spec.ts
Last active June 26, 2023 01:58
Angular Cookbook ng-jest-services-stubs tests for CounterService
// replace the tests below
it('should call the CounterService.getFromStorage method on component init', () => {
jest.spyOn(CounterServiceMock, 'getFromStorage');
component.ngOnInit();
expect(component.counterService.getFromStorage).toHaveBeenCalled();
});
it('should retrieve the last saved value from CounterService on component init', () => {
jest.spyOn(CounterServiceMock, 'getFromStorage').mockReturnValue(12);
component.counterService.saveToStorage(12);
@AhsanAyaz
AhsanAyaz / ng-cdk-overlay__styles.scss
Last active June 25, 2023 12:05
Angular CDK Overlay (with menu) Default CSS for Angular Cookbook Recipes
.cdk-overlay-container {
display: block;
&.z-index-top {
z-index: 2050;
}
}
.duplicate-modal-overlay {
z-index: 999;
}
@AhsanAyaz
AhsanAyaz / ng-cdk-popover-template.html
Last active November 2, 2023 16:11
ng-template for the ng-cdk-popover recipe in Angular Cookbook 2nd Edition
<ng-template cdkConnectedOverlay [cdkConnectedOverlayOrigin]="popoverMenuOrigin!"
[cdkConnectedOverlayOpen]="menuShown" [cdkConnectedOverlayHasBackdrop]="true"
(backdropClick)="closeMenu()"
[cdkConnectedOverlayPositions]="menuPositions"
cdkConnectedOverlayPanelClass="menu-popover"
>
<div class="menu-popover__list">
<div class="menu-popover__list__item">
Duplicate
</div>