Skip to content

Instantly share code, notes, and snippets.

View margauxflores's full-sized avatar
🖐️
Looking for fun projects to help out with!

Margaux Flores margauxflores

🖐️
Looking for fun projects to help out with!
View GitHub Profile
@margauxflores
margauxflores / .env
Created May 18, 2024 01:12
morag env
# Environment variables declared in this file are automatically made available to Prisma.
# See the documentation for more detail: https://pris.ly/d/prisma-schema#accessing-environment-variables-from-the-schema
# Prisma supports the native connection string format for PostgreSQL, MySQL, SQLite, SQL Server, MongoDB and CockroachDB.
# See the documentation for all the connection string options: https://pris.ly/d/connection-strings
DATABASE_URL="postgresql://morag_admin:J3tisnsd9@localhost:5432/morag?schema=public"
API_BASE_URL="http://localhost:3000"
NEXT_PUBLIC_API_URL="http://localhost:3000"
@margauxflores
margauxflores / delete.cue
Created March 5, 2024 05:03
Sample Call
package resolvers
import (
schema "github.com/tailor-inc/platform-core-services/cmd/tailorctl/schema/v1:pipeline"
"{{ .Values.cue.package }}/{{ .Values.cue.dist }}/directory:directories"
"{{ .Values.cue.package }}/{{ .Values.cue.dist }}/pipeline:settings"
)
// input moveToDeletedWorkrecordInput
// id: ID!
@margauxflores
margauxflores / escape.json
Last active February 22, 2024 15:45
Karabiner Elements - Escape Key to Back Tick and Tilde and Escape + Ctrl to Escape
{
"description": "Escape Key",
"manipulators": [
{
"from": {
"key_code": "escape",
"modifiers": {
"mandatory": [
"left_control"
]
@margauxflores
margauxflores / middleware.ts
Created September 13, 2023 01:14
Next.js Redirect All Pages to Index Page
import { NextResponse, type NextRequest } from 'next/server';
export function middleware(req: NextRequest) {
const { pathname } = req.nextUrl;
if (pathname == '/') {
return NextResponse.next();
}
return NextResponse.redirect(new URL('/', req.url));
:root {
--color-secondary: #5c1c93;
--color-alert: #fafa4d;
--color-black: black;
--color-black2: #1a1a1a;
--color-white: white;
--color-grey-1: #141414;
--color-grey-2: #4b4b4b;
--color-grey-3: #adadad;
--color-grey-4: #5a5a5a;
import React from 'react';
import styles from './DocsLayout.module.css';
import { Header, HeaderType } from '~/components/_shared/Header';
type DocsLayoutProps = HasChildrenProps;
export const Layout: React.FC<LayoutProps> = ({ children }) => {
return (
<>
<Header layout={HeaderType.DOCSLAYOUT} />
@margauxflores
margauxflores / README.md
Last active June 25, 2022 13:26
README file

Frobots Client

The frobots_client repository contains the scenic elements that you need to run the FUBARs arena to develop your own Frobots locally.

Getting Started

1. Clone the repository

git clone [email protected]:Bittoku/frobots_client.git

2. Get a Bearer Token

var lua_script = (function() {
var tmp;
var G = lua_newtable2(lua_core);
for (var i in lua_libs) {
G.str[i] = lua_newtable2(lua_libs[i]);
}
G.str['arg'] = lua_newtable();
G.str['_G'] = G;
G.str['module'] = function (name) {
lua_createmodule(G, name, slice(arguments, 1));
@margauxflores
margauxflores / AutoMapperProfile.cs
Last active January 2, 2022 20:29
AutoMapper Problem
// Vessel from Models does not work
using Citadel.Models;
// Vessel from Entities works
using Vessel = Citadel.Entities.Vessel;
namespace Citadel
{
public class AutoMapperProfile : Profile
{
@margauxflores
margauxflores / passingDataThroughVueRouter.vue
Last active July 10, 2023 06:59
Passing Data Through Vue Router
# Use case:
# I have a route where there's an ID parameter and I want to be able to pass data through Vue Router.
# Code setup is Vue + TypeScript using vue-class-component
# Home.vue template section
# This list is rendered after fetching data from an API call.
<template>
<li v-for="item in items" :key="item.id" @click.prevent="goToItem(item)">...</li>
</template>