UNPKG

create-jd-app

Version:

Create modern type safed Solid web application within seconds

42 lines (41 loc) 1.18 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const packages_1 = require("../../helpers/packages"); const config = (ctx) => ({ files: [ { path: `${__dirname}/utils/getSchema`, type: "exec", to: `${ctx.userDir}/prisma/schema.prisma`, ignorePrettier: true, }, { path: `${__dirname}/files/client.txt`, to: `${ctx.userDir}/src/server/db.ts`, }, !ctx.installers.includes("AuthJS") ? { path: `${__dirname}/files/api.txt`, to: `${ctx.userDir}/src/routes/api/notes.ts`, } : undefined, ], scripts: { push: "prisma db push", postinstall: "prisma generate", }, env: [ { key: "DATABASE_URL", type: "string()", defaulValue: "file:./db.sqlite", kind: "server", }, ], pkgs: (0, packages_1.withPackages)({ dev: "prisma", normal: "@prisma/client", }), commands: `${ctx.pkgManager === "npm" ? "npx" : "pnpm"} prisma db push`, }); exports.default = config;