This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Module } from "@nestjs/common"; | |
import { PrismaService } from "./prisma.service"; | |
@Module({ | |
providers: [PrismaService], | |
exports: [PrismaService] | |
}) | |
export class PrismaModule {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM node:18-alpine as builder | |
WORKDIR /build | |
COPY . . | |
RUN yarn install | |
RUN rm -rf dist/ | |
RUN tsc | |
FROM node:18-alpine | |
WORKDIR /app | |
COPY package*.json ./ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM node:18-alpine as builder | |
WORKDIR /build | |
COPY . . | |
RUN npm install | |
RUN rm -rf dist/ | |
RUN tsc | |
FROM node:18-alpine | |
WORKDIR /app | |
COPY package*.json ./ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM swift:latest as builder | |
WORKDIR /root | |
COPY ./Package.* ./ | |
RUN swift package resolve | |
COPY . . | |
RUN swift build -c release | |
FROM swift:slim | |
COPY --from=builder /root/.build build | |
CMD ["build/release/<project-name>"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// AuthStore.ts | |
// web | |
// | |
// Created by d-exclaimation on 00:28. | |
// | |
/** | |
* Authentication InMemory storage. | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// MagicInput.tsx | |
// web | |
// | |
// Created by d-exclaimation on 11:54. | |
// | |
import React, { useMemo } from "react"; | |
type Props = { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Foundation | |
/// Intermediate data structure for non-schema based JSON value, using the power Swift's enum and its pattern matching | |
/// | |
/// ```swift | |
/// let jsVal: JsValue = .object(map: [ | |
/// "top_one": .string("ok"), | |
/// "top_two": .object(map: [ | |
/// "nested_one": .number(10), | |
/// "nested_two": .bool(false), |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Channel as PhoenixChannel, Socket } from "phoenix"; | |
import { useCallback, useContext, useEffect, useRef, createContext } from "react"; | |
// Initialize and connect server given the socket endpoint | |
const __socket__ = "fill this in" | |
const socket = new Socket(__socket__, {}); | |
socket.connect(); | |
export const SocketContext = createContext(socket); | |
/** |