chore: upgrade turbo to version 2 (#2738)

This commit is contained in:
Matti Nannt
2024-06-07 07:59:44 +02:00
committed by GitHub
parent b49ca8087a
commit a269da4e1c
77 changed files with 889 additions and 450 deletions

View File

@@ -22,7 +22,7 @@
// Use 'postCreateCommand' to run commands after the container is created.
"postCreateCommand": "cp .env.example .env && sed -i '/^ENCRYPTION_KEY=/c\\ENCRYPTION_KEY='$(openssl rand -hex 32) .env && sed -i '/^NEXTAUTH_SECRET=/c\\NEXTAUTH_SECRET='$(openssl rand -hex 32) .env && pnpm install && pnpm db:migrate:dev",
"postAttachCommand": "pnpm dev --filter=web... --filter=demo...",
"postAttachCommand": "pnpm dev --filter=@formbricks/web... --filter=@formbricks/demo...",
// Comment out to connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
"remoteUser": "node"

2
.eslintignore Normal file
View File

@@ -0,0 +1,2 @@
node_modules/
packages/config-eslint/

View File

@@ -1,10 +0,0 @@
module.exports = {
root: true,
// This tells ESLint to load the config from the package `eslint-config-formbricks`
extends: ["formbricks"],
settings: {
next: {
rootDir: ["apps/*/"],
},
},
};

View File

@@ -49,20 +49,16 @@ runs:
run: cp .env.example .env
shell: bash
- name: Add E2E Testing Mode
- name: Fill ENCRYPTION_KE, ENTERPRISE_LICENSE_KEY and E2E_TESTING in .env
run: |
echo "E2E_TESTING=${{ inputs.e2e_testing_mode }}" >> $GITHUB_ENV
shell: bash
- name: Generate Random ENCRYPTION_KEY
run: |
SECRET=$(openssl rand -hex 32)
echo "ENCRYPTION_KEY=$SECRET" >> $GITHUB_ENV
echo "ENTERPRISE_LICENSE_KEY=$SECRET" >> $GITHUB_ENV
RANDOM_KEY=$(openssl rand -hex 32)
sed -i "s/ENCRYPTION_KEY=.*/ENCRYPTION_KEY=${RANDOM_KEY}/" .env
sed -i "s/ENTERPRISE_LICENSE_KEY=.*/ENTERPRISE_LICENSE_KEY=${RANDOM_KEY}/" .env
echo "E2E_TESTING=${{ inputs.e2e_testing_mode }}" >> .env
shell: bash
- run: |
pnpm build --filter=web...
pnpm build --filter=@formbricks/web...
if: steps.cache-build.outputs.cache-hit != 'true'
shell: bash

View File

@@ -31,4 +31,4 @@ jobs:
echo "ENCRYPTION_KEY=$SECRET" >> $GITHUB_ENV
- name: Build Formbricks-web
run: pnpm build --filter=web...
run: pnpm build --filter=@formbricks/web...

View File

@@ -40,7 +40,7 @@ jobs:
- name: Run App
run: |
NODE_ENV=test pnpm start --filter=web &
NODE_ENV=test pnpm start --filter=@formbricks/web &
for attempt in {1..20}; do
if [ $(curl -o /dev/null -s -w "%{http_code}" http://localhost:3000/health) -eq 200 ]; then
echo "Ready"

View File

@@ -25,10 +25,10 @@ jobs:
- name: create .env
run: cp .env.example .env
- name: Generate Random ENCRYPTION_KEY
- name: Generate Random ENCRYPTION_KEY and fill in .env
run: |
SECRET=$(openssl rand -hex 32)
echo "ENCRYPTION_KEY=$SECRET" >> $GITHUB_ENV
ENCRYPTION_KEY=$(openssl rand -hex 32)
sed -i "s/ENCRYPTION_KEY=.*/ENCRYPTION_KEY=${ENCRYPTION_KEY}/" .env
- name: Lint
run: pnpm lint

View File

@@ -25,10 +25,10 @@ jobs:
- name: create .env
run: cp .env.example .env
- name: Generate Random ENCRYPTION_KEY
- name: Generate Random ENCRYPTION_KEY and fill in .env
run: |
SECRET=$(openssl rand -hex 32)
echo "ENCRYPTION_KEY=$SECRET" >> $GITHUB_ENV
ENCRYPTION_KEY=$(openssl rand -hex 32)
sed -i "s/ENCRYPTION_KEY=.*/ENCRYPTION_KEY=${ENCRYPTION_KEY}/" .env
- name: Test
run: pnpm test

View File

@@ -1,4 +1,4 @@
const baseConfig = require("./packages/prettier-config/prettier-preset");
const baseConfig = require("./packages/config-prettier/prettier-preset");
module.exports = {
...baseConfig,

View File

@@ -1,4 +1,3 @@
module.exports = {
root: true,
extends: ["formbricks"],
extends: ["@formbricks/eslint-config/legacy-next.js"],
};

View File

@@ -19,7 +19,7 @@
"react-dom": "18.3.1"
},
"devDependencies": {
"eslint-config-formbricks": "workspace:*",
"@formbricks/tsconfig": "workspace:*"
"@formbricks/eslint-config": "workspace:*",
"@formbricks/config-typescript": "workspace:*"
}
}

View File

@@ -1,5 +1,5 @@
{
"extends": "@formbricks/tsconfig/nextjs.json",
"extends": "@formbricks/config-typescript/nextjs.json",
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx"],
"exclude": ["node_modules"]
}

View File

@@ -1,4 +1,3 @@
module.exports = {
root: true,
extends: ["formbricks"],
extends: ["@formbricks/eslint-config/legacy-next.js"],
};

View File

@@ -43,7 +43,6 @@ To be able to keep working on Formbricks over the coming years, we need to colle
Once you open a PR, you will get a message from the CLA bot to fill out the form. Please note that we can only get your contribution merged when we have a CLA signed by you.
## Setup Dev Environment
We currently officially support the below methods to set up your development environment for Formbricks.
@@ -425,7 +424,7 @@ This usually happens when the Formbricks Widget wasn't correctly or completely b
<CodeGroup title="Build js library first and then run again">
```bash
pnpm build --filter=js
pnpm build --filter=@formbricks/js
// Run the app again
pnpm dev
@@ -441,15 +440,15 @@ Since we're working with a monorepo structure, the repository can get quite big.
<CodeGroup title="Only run the required project">
```bash {{ title: 'Formbricks Web-App' }}
pnpm dev --filter=web...
pnpm dev --filter=@formbricks/web...
```
```bash {{ title: 'Formbricks Landing Page' }}
pnpm dev --filter=formbricks-com...
```bash {{ title: 'Formbricks Docs' }}
pnpm dev --filter=@formbricks/docs...
```
```bash {{ title: 'Formbricks Demo App' }}
pnpm dev --filter=demo...
pnpm dev --filter=@formbricks/demo...
```
</CodeGroup>
@@ -468,4 +467,3 @@ However, in our experience it's better to run `pnpm dev` than having two termina
This happens when you're using the Demo App and delete the Person within the Formbricks app which the widget is currently connected with. We're fixing it, but you can also just logout your test person and reload the page to get rid of it.
<MdxImage src={Logout} alt="Logout Person" quality="100" className="max-w-full rounded-lg sm:max-w-3xl" />

View File

@@ -65,9 +65,9 @@
"zustand": "^4.5.2"
},
"devDependencies": {
"@formbricks/tsconfig": "workspace:*",
"@formbricks/config-typescript": "workspace:*",
"@types/dompurify": "^3.0.5",
"@types/react-highlight-words": "^0.16.7",
"eslint-config-formbricks": "workspace:*"
"@formbricks/eslint-config": "workspace:*"
}
}

View File

@@ -1,5 +1,5 @@
{
"extends": "@formbricks/tsconfig/nextjs.json",
"extends": "@formbricks/config-typescript/nextjs.json",
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts", "../../packages/types/*.d.ts"],
"exclude": ["../../.env", "node_modules"],
"compilerOptions": {

View File

@@ -12,12 +12,13 @@
},
"dependencies": {
"@formbricks/ui": "workspace:*",
"eslint-plugin-react-refresh": "^0.4.7",
"react": "^18.3.1",
"react-dom": "^18.3.1"
},
"devDependencies": {
"@chromatic-com/storybook": "^1.5.0",
"@formbricks/tsconfig": "workspace:*",
"@formbricks/config-typescript": "workspace:*",
"@storybook/addon-essentials": "^8.1.5",
"@storybook/addon-interactions": "^8.1.5",
"@storybook/addon-links": "^8.1.5",

View File

@@ -1,5 +1,5 @@
/** @type {import('tailwindcss').Config} */
import base from "../../packages/tailwind-config/tailwind.config";
import base from "../../packages/config-tailwind/tailwind.config";
export default {
...base,

View File

@@ -1,4 +1,3 @@
module.exports = {
root: true,
extends: ["formbricks"],
extends: ["@formbricks/eslint-config/legacy-next.js"],
};

View File

@@ -48,8 +48,8 @@ COPY --from=builder /app/out/full/ .
RUN touch /app/apps/web/.env
# Build the project
RUN pnpm post-install --filter=web...
RUN pnpm turbo run build --filter=web...
RUN pnpm post-install --filter=@formbricks/web...
RUN pnpm turbo run build --filter=@formbricks/web...
# Extract Prisma version
RUN jq -r '.devDependencies.prisma' packages/database/package.json > /prisma_version.txt

View File

@@ -23,7 +23,7 @@
"@formbricks/js-core": "workspace:*",
"@formbricks/lib": "workspace:*",
"@formbricks/surveys": "workspace:*",
"@formbricks/tailwind-config": "workspace:*",
"@formbricks/config-tailwind": "workspace:*",
"@formbricks/types": "workspace:*",
"@formbricks/ui": "workspace:*",
"@hookform/resolvers": "^3.4.2",
@@ -69,13 +69,13 @@
"xlsx": "^0.18.5"
},
"devDependencies": {
"@formbricks/tsconfig": "workspace:*",
"@formbricks/config-typescript": "workspace:*",
"@neshca/cache-handler": "^1.3.2",
"@types/bcryptjs": "^2.4.6",
"@types/lodash": "^4.17.4",
"@types/markdown-it": "^14.1.1",
"@types/papaparse": "^5.3.14",
"@types/qrcode": "^1.5.5",
"eslint-config-formbricks": "workspace:*"
"@formbricks/eslint-config": "workspace:*"
}
}

View File

@@ -1,4 +1,4 @@
const base = require("../../packages/tailwind-config/tailwind.config");
const base = require("../../packages/config-tailwind/tailwind.config");
/** @type {import('tailwindcss').Config} */
module.exports = {

View File

@@ -1,5 +1,5 @@
{
"extends": "@formbricks/tsconfig/nextjs.json",
"extends": "@formbricks/config-typescript/nextjs.json",
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts", "../../packages/types/*.d.ts"],
"exclude": ["../../.env", "node_modules"],
"compilerOptions": {

View File

@@ -26,7 +26,7 @@
"format": "prettier --write \"**/*.{ts,tsx,md}\"",
"generate": "turbo run generate",
"lint": "turbo run lint",
"release": "turbo run build --filter=js... && turbo run build --filter=n8n-node... && changeset publish",
"release": "turbo run build --filter=@formbricks/js... && changeset publish",
"test": "turbo run test --no-cache",
"test:e2e": "playwright test",
"prepare": "husky install",
@@ -34,12 +34,13 @@
},
"devDependencies": {
"@playwright/test": "^1.44.1",
"eslint-config-formbricks": "workspace:*",
"@formbricks/eslint-config": "workspace:*",
"eslint": "^8.57.0",
"husky": "^9.0.11",
"lint-staged": "^15.2.5",
"rimraf": "^5.0.7",
"tsx": "^4.11.0",
"turbo": "^1.13.3"
"turbo": "^2.0.1"
},
"lint-staged": {
"(apps|packages)/**/*.{js,ts,jsx,tsx}": [
@@ -56,7 +57,7 @@
"engines": {
"node": ">=16.0.0"
},
"packageManager": "pnpm@9.1.3",
"packageManager": "pnpm@8.15.8",
"nextBundleAnalysis": {
"budget": 358400,
"budgetPercentIncreaseRed": 20,

View File

@@ -1,3 +1,4 @@
module.exports = {
extends: [ "turbo", "prettier"],
};
extends: ["@formbricks/eslint-config/legacy-library.js"],
parser: "@typescript-eslint/parser",
};

View File

@@ -30,13 +30,13 @@
"build": "tsc && vite build",
"build:dev": "pnpm build",
"go": "vite build --watch",
"lint": "eslint ./src --fix",
"lint": "eslint . --ext .ts,.js,.tsx,.jsx",
"clean": "rimraf .turbo node_modules dist"
},
"devDependencies": {
"@formbricks/tsconfig": "workspace:*",
"@formbricks/config-typescript": "workspace:*",
"@formbricks/types": "workspace:*",
"eslint-config-formbricks": "workspace:*",
"@formbricks/eslint-config": "workspace:*",
"terser": "^5.31.0",
"vite": "^5.2.11",
"vite-plugin-dts": "^3.9.1"

View File

@@ -1,6 +1,7 @@
{
"extends": "@formbricks/tsconfig/js-library.json",
"include": ["src", "package.json"],
"extends": "@formbricks/config-typescript/js-library.json",
"include": ["src"],
"exclude": ["dist", "build", "node_modules"],
"compilerOptions": {
"allowImportingTsExtensions": true,
"isolatedModules": true,

View File

@@ -0,0 +1,3 @@
# `@turbo/eslint-config`
Collection of internal eslint configurations.

View File

@@ -0,0 +1,3 @@
module.exports = {
extends: ["turbo", "prettier"],
};

View File

@@ -0,0 +1,3 @@
module.exports = {
extends: ["turbo", "prettier", "plugin:react-hooks/recommended"],
};

View File

@@ -0,0 +1,34 @@
const { resolve } = require("node:path");
const project = resolve(process.cwd(), "tsconfig.json");
/*
* This is a custom ESLint configuration for use with
* typescript packages.
*
* This config extends the Vercel Engineering Style Guide.
* For more information, see https://github.com/vercel/style-guide
*
*/
module.exports = {
extends: ["@vercel/style-guide/eslint/node", "@vercel/style-guide/eslint/typescript"].map(require.resolve),
parserOptions: {
project,
},
globals: {
React: true,
JSX: true,
},
settings: {
"import/resolver": {
typescript: {
project,
},
node: {
extensions: [".mjs", ".js", ".jsx", ".ts", ".tsx"],
},
},
},
ignorePatterns: ["node_modules/", "dist/"],
};

View File

@@ -0,0 +1,45 @@
const { resolve } = require("node:path");
const project = resolve(process.cwd(), "tsconfig.json");
/*
* This is a custom ESLint configuration for use with
* Next.js apps.
*
* This config extends the Vercel Engineering Style Guide.
* For more information, see https://github.com/vercel/style-guide
*
*/
module.exports = {
extends: [
"@vercel/style-guide/eslint/node",
"@vercel/style-guide/eslint/typescript",
"@vercel/style-guide/eslint/browser",
"@vercel/style-guide/eslint/react",
"@vercel/style-guide/eslint/next",
"eslint-config-turbo",
].map(require.resolve),
parserOptions: {
project,
},
globals: {
React: true,
JSX: true,
},
settings: {
"import/resolver": {
typescript: {
project,
},
node: {
extensions: [".mjs", ".js", ".jsx", ".ts", ".tsx"],
},
},
},
ignorePatterns: ["node_modules/", "dist/"],
// add rules configurations here
rules: {
"import/no-default-export": "off",
},
};

View File

@@ -0,0 +1,17 @@
{
"name": "@formbricks/eslint-config",
"version": "0.0.0",
"private": true,
"devDependencies": {
"@next/eslint-plugin-next": "^14.2.3",
"@typescript-eslint/eslint-plugin": "^7.10.0",
"@typescript-eslint/parser": "^7.10.0",
"@vercel/style-guide": "^5.2.0",
"eslint-config-next": "^14.2.3",
"eslint-config-prettier": "^9.1.0",
"eslint-config-turbo": "^2.0.0",
"eslint-plugin-react": "7.34.1",
"eslint-plugin-react-hooks": "^4.6.2",
"eslint-plugin-react-refresh": "^0.4.7"
}
}

49
packages/config-eslint/react.js vendored Normal file
View File

@@ -0,0 +1,49 @@
const { resolve } = require("node:path");
const project = resolve(process.cwd(), "tsconfig.json");
/*
* This is a custom ESLint configuration for use a library
* that utilizes React.
*
* This config extends the Vercel Engineering Style Guide.
* For more information, see https://github.com/vercel/style-guide
*
*/
module.exports = {
extends: [
"@vercel/style-guide/eslint/browser",
"@vercel/style-guide/eslint/typescript",
"@vercel/style-guide/eslint/react",
].map(require.resolve),
parserOptions: {
project,
},
globals: {
JSX: true,
},
settings: {
"import/resolver": {
typescript: {
project,
},
node: {
extensions: [".mjs", ".js", ".jsx", ".ts", ".tsx"],
},
},
},
ignorePatterns: ["node_modules/", "dist/", ".eslintrc.js", "**/*.css"],
// add rules configurations here
rules: {
"import/no-default-export": "off",
},
overrides: [
{
files: ["*.config.js"],
env: {
node: true,
},
},
],
};

View File

@@ -1,5 +1,5 @@
{
"name": "@formbricks/prettier-config",
"name": "@formbricks/config-prettier",
"version": "1.0.0",
"private": true,
"license": "MIT",

View File

@@ -1,5 +1,5 @@
{
"name": "@formbricks/tailwind-config",
"name": "@formbricks/config-tailwind",
"version": "0.0.0",
"private": true,
"main": "index.js",

View File

@@ -1,5 +1,5 @@
{
"name": "@formbricks/tsconfig",
"name": "@formbricks/config-typescript",
"version": "1.0.0",
"private": true,
"sideEffects": false,

View File

@@ -1,4 +1,3 @@
module.exports = {
root: true,
extends: ["formbricks"],
extends: ["@formbricks/eslint-config/legacy-next.js"],
};

View File

@@ -41,10 +41,10 @@
"dotenv-cli": "^7.4.2"
},
"devDependencies": {
"@formbricks/tsconfig": "workspace:*",
"@formbricks/config-typescript": "workspace:*",
"@formbricks/types": "workspace:*",
"@paralleldrive/cuid2": "^2.2.2",
"eslint-config-formbricks": "workspace:*",
"@formbricks/eslint-config": "workspace:*",
"prisma": "^5.14.0",
"prisma-dbml-generator": "^0.12.0",
"prisma-json-types-generator": "^3.0.4",

View File

@@ -1,5 +1,5 @@
{
"extends": "@formbricks/tsconfig/node16.json",
"extends": "@formbricks/config-typescript/node16.json",
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", "tsup.config.ts"],
"exclude": ["node_modules", "dist", "zod"]
}

3
packages/ee/.eslintrc.js Normal file
View File

@@ -0,0 +1,3 @@
module.exports = {
extends: ["@formbricks/eslint-config/legacy-next.js"],
};

View File

@@ -11,10 +11,10 @@
},
"devDependencies": {
"@formbricks/lib": "*",
"@formbricks/tsconfig": "*",
"@formbricks/config-typescript": "*",
"@formbricks/types": "*",
"@formbricks/ui": "*",
"eslint-config-formbricks": "workspace:*"
"@formbricks/eslint-config": "workspace:*"
},
"dependencies": {
"@formbricks/lib": "workspace:*",

View File

@@ -1,5 +1,5 @@
{
"extends": "@formbricks/tsconfig/react-library.json",
"extends": "@formbricks/config-typescript/react-library.json",
"compilerOptions": {
"baseUrl": ".",
"paths": {

View File

@@ -0,0 +1,3 @@
module.exports = {
extends: ["@formbricks/eslint-config/legacy-next.js"],
};

View File

@@ -1,22 +0,0 @@
{
"name": "eslint-config-formbricks",
"version": "1.0.0",
"private": true,
"main": "index.js",
"license": "MIT",
"scripts": {
"clean": "rimraf node_modules .turbo"
},
"devDependencies": {
"@typescript-eslint/eslint-plugin": "^7.10.0",
"@typescript-eslint/parser": "^7.10.0",
"eslint": "^8.57.0",
"eslint-config-next": "^14.2.3",
"eslint-config-prettier": "^9.1.0",
"eslint-config-turbo": "1.10.12",
"eslint-plugin-react": "7.34.1",
"eslint-plugin-react-hooks": "^4.6.2",
"eslint-plugin-react-refresh": "^0.4.7",
"eslint-plugin-storybook": "^0.8.0"
}
}

View File

@@ -1,3 +1,4 @@
module.exports = {
extends: ["turbo", "prettier"],
extends: ["@formbricks/eslint-config/legacy-library.js"],
parser: "@typescript-eslint/parser",
};

View File

@@ -49,16 +49,16 @@
"build": "pnpm build:app && pnpm build:website",
"build:dev": "tsc && vite build --mode dev",
"go": "vite build --watch --mode dev",
"lint": "eslint ./src --fix",
"lint": "eslint . --ext .ts,.js,.tsx,.jsx",
"clean": "rimraf .turbo node_modules dist coverage"
},
"author": "Formbricks <hola@formbricks.com>",
"devDependencies": {
"@formbricks/api": "workspace:*",
"@formbricks/lib": "workspace:*",
"@formbricks/tsconfig": "workspace:*",
"@formbricks/config-typescript": "workspace:*",
"@formbricks/types": "workspace:*",
"eslint-config-formbricks": "workspace:*",
"@formbricks/eslint-config": "workspace:*",
"terser": "^5.31.0",
"vite": "^5.2.11",
"vite-plugin-dts": "^3.9.1"

View File

@@ -1,5 +1,5 @@
{
"extends": "@formbricks/tsconfig/js-library.json",
"extends": "@formbricks/config-typescript/js-library.json",
"include": ["src", "package.json", "../types/surveys.d.ts"],
"compilerOptions": {
"strict": true,

File diff suppressed because one or more lines are too long

View File

@@ -1,3 +1,4 @@
module.exports = {
extends: ["turbo", "prettier"],
extends: ["@formbricks/eslint-config/legacy-library.js"],
parser: "@typescript-eslint/parser",
};

View File

@@ -46,14 +46,14 @@
"build": "tsc && vite build",
"build:dev": "tsc && vite build --mode dev",
"go": "vite build --watch --mode dev",
"lint": "eslint ./src --fix",
"lint": "eslint . --ext .ts,.js,.tsx,.jsx",
"clean": "rimraf .turbo node_modules dist coverage"
},
"author": "Formbricks <hola@formbricks.com>",
"devDependencies": {
"@formbricks/js-core": "workspace:*",
"@formbricks/tsconfig": "workspace:*",
"eslint-config-formbricks": "workspace:*",
"@formbricks/config-typescript": "workspace:*",
"@formbricks/eslint-config": "workspace:*",
"terser": "^5.31.0",
"vite": "^5.2.11",
"vite-plugin-dts": "^3.9.1"

View File

@@ -1,5 +1,5 @@
{
"extends": "@formbricks/tsconfig/js-library.json",
"extends": "@formbricks/config-typescript/js-library.json",
"include": ["src", "package.json"],
"compilerOptions": {
"strict": true,

View File

@@ -1,4 +1,3 @@
module.exports = {
root: true,
extends: ["formbricks"],
extends: ["@formbricks/eslint-config/legacy-next.js"],
};

View File

@@ -36,12 +36,12 @@
"tailwind-merge": "^2.3.0"
},
"devDependencies": {
"@formbricks/tsconfig": "*",
"@formbricks/config-typescript": "*",
"@types/jsonwebtoken": "^9.0.6",
"@types/mime-types": "^2.1.4",
"@types/ungap__structured-clone": "^1.2.0",
"dotenv": "^16.4.5",
"eslint-config-formbricks": "workspace:*",
"@formbricks/eslint-config": "workspace:*",
"ts-node": "^10.9.2",
"vitest": "^1.6.0",
"vitest-mock-extended": "^1.3.1"

View File

@@ -1,5 +1,5 @@
{
"extends": "@formbricks/tsconfig/nextjs.json",
"extends": "@formbricks/config-typescript/nextjs.json",
"include": ["."],
"exclude": ["dist", "build", "node_modules", "../../packages/types/surveys.d.ts"],
"compilerOptions": {

View File

@@ -1,3 +1,4 @@
module.exports = {
extends: [ "turbo", "prettier"],
};
extends: ["@formbricks/eslint-config/legacy-react.js"],
parser: "@typescript-eslint/parser",
};

View File

@@ -38,12 +38,12 @@
"devDependencies": {
"@calcom/embed-snippet": "1.3.0",
"@formbricks/lib": "workspace:*",
"@formbricks/tsconfig": "workspace:*",
"@formbricks/config-typescript": "workspace:*",
"@formbricks/types": "workspace:*",
"@preact/preset-vite": "^2.8.2",
"autoprefixer": "^10.4.19",
"concurrently": "8.2.2",
"eslint-config-formbricks": "workspace:*",
"@formbricks/eslint-config": "workspace:*",
"isomorphic-dompurify": "^2.11.0",
"postcss": "^8.4.38",
"preact": "^10.22.0",

View File

@@ -34,7 +34,6 @@ export const QuestionMedia = ({ imgUrl, videoUrl, altText = "Image" }: QuestionM
return (
<div className="group/image relative mb-4 block rounded-md">
{/* eslint-disable-next-line @next/next/no-img-element */}
{imgUrl && <img src={imgUrl} alt={altText} className="rounded-custom" />}
{videoUrlWithParams && (
<div className="relative">

View File

@@ -107,7 +107,6 @@ export const WelcomeCard = ({
<ScrollableContainer>
<div>
{fileUrl && (
/* eslint-disable-next-line @next/next/no-img-element */
<img src={fileUrl} className="mb-8 max-h-96 w-1/3 rounded-lg object-contain" alt="Company Logo" />
)}

View File

@@ -132,7 +132,6 @@ export const PictureSelectionQuestion = ({
: "",
"focus:border-brand group/image rounded-custom relative inline-block h-28 w-full cursor-pointer overflow-hidden border focus:border-4 focus:outline-none"
)}>
{/* eslint-disable-next-line @next/next/no-img-element */}
<img
src={choice.imageUrl}
id={choice.id}

View File

@@ -1,5 +1,5 @@
{
"extends": "@formbricks/tsconfig/js-library.json",
"extends": "@formbricks/config-typescript/js-library.json",
"include": ["src", "../types/surveys.d.ts"],
"compilerOptions": {
"allowImportingTsExtensions": true,

View File

@@ -8,7 +8,7 @@
"clean": "rimraf node_modules .turbo"
},
"devDependencies": {
"@formbricks/tsconfig": "workspace:*"
"@formbricks/config-typescript": "workspace:*"
},
"dependencies": {
"zod": "^3.23.8"

View File

@@ -1,5 +1,5 @@
{
"extends": "@formbricks/tsconfig/base.json",
"extends": "@formbricks/config-typescript/base.json",
"include": ["."],
"exclude": ["dist", "build", "node_modules"],
"compilerOptions": {

3
packages/ui/.eslintrc.js Normal file
View File

@@ -0,0 +1,3 @@
module.exports = {
extends: ["@formbricks/eslint-config/legacy-next.js"],
};

View File

@@ -5,13 +5,14 @@
"version": "1.0.0",
"main": "./index.tsx",
"scripts": {
"clean": "rimraf .turbo node_modules dist"
"clean": "rimraf .turbo node_modules dist",
"lint": "eslint . --ext .ts,.js,.tsx,.jsx"
},
"devDependencies": {
"@formbricks/tsconfig": "workspace:*",
"@formbricks/config-typescript": "workspace:*",
"@formbricks/types": "workspace:*",
"concurrently": "^8.2.2",
"eslint-config-formbricks": "workspace:*",
"@formbricks/eslint-config": "workspace:*",
"postcss": "^8.4.38",
"react": "18.3.1"
},

View File

@@ -1,5 +1,5 @@
{
"extends": "@formbricks/tsconfig/react-library.json",
"extends": "@formbricks/config-typescript/react-library.json",
"include": [".", "../types/*.d.ts", "../lib/templates.ts"],
"exclude": ["build", "node_modules"],
"compilerOptions": {

911
pnpm-lock.yaml generated

File diff suppressed because it is too large Load Diff

View File

@@ -1,4 +1,3 @@
packages:
- "apps/*"
- "packages/*"
- "!packages/n8n"

View File

@@ -1,6 +1,6 @@
{
"$schema": "https://turborepo.org/schema.json",
"pipeline": {
"tasks": {
"@formbricks/database#build": {
"cache": false,
"dependsOn": ["post-install"]
@@ -66,6 +66,7 @@
"CUSTOM_CACHE_DISABLED",
"CUSTOMER_IO_API_KEY",
"CUSTOMER_IO_SITE_ID",
"DATABASE_URL",
"DEBUG",
"E2E_TESTING",
"EMAIL_AUTH_DISABLED",
@@ -144,6 +145,7 @@
"UPLOADS_DIR",
"VERCEL",
"VERCEL_URL",
"VERSION",
"WEBAPP_URL",
"UNSPLASH_ACCESS_KEY"
]