Skip to content

Commit

Permalink
Merge pull request #25 from himohitmehta/dashboard-and-ui
Browse files Browse the repository at this point in the history
FIXED deployment issues in dashboard and UI library
  • Loading branch information
himohitmehta committed Jun 3, 2024
2 parents 8601dd8 + 9ee3687 commit 4fb4461
Show file tree
Hide file tree
Showing 10 changed files with 24 additions and 24 deletions.
3 changes: 2 additions & 1 deletion packages/tsconfig/react-library.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
"jsx": "react-jsx",
"lib": ["ES2015", "DOM"],
"module": "ESNext",
"target": "es6"
"target": "es6",
"noEmit": true,
}
}
4 changes: 2 additions & 2 deletions packages/ui/components.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"prefix": ""
},
"aliases": {
"components": "@ui/components",
"utils": "@ui/lib/utils"
"components": "@/ui/components",
"utils": "@/ui/lib/utils"
}
}
3 changes: 1 addition & 2 deletions packages/ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,7 @@
"postcss": "^8.4.38",
"tailwind-merge": "^2.3.0",
"tailwindcss": "^3.4.3",
"tsup": "^8.0.2",
"@saroh/utils": "workspace:*"
"tsup": "^8.0.2"
},
"author": "Mohit Kumar <himohitmehta>",
"homepage": "https://saroh.io",
Expand Down
5 changes: 1 addition & 4 deletions packages/ui/src/components/ui/button.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
/* eslint-disable @typescript-eslint/no-unsafe-call -- no*/
/* eslint-disable @typescript-eslint/no-unsafe-assignment -- some */
/* eslint-disable import/no-extraneous-dependencies -- trying to remove error */
/* eslint-disable import/no-named-as-default-member -- showing unnecessary errors*/
import { Slot } from "@radix-ui/react-slot";
import { cn } from "@saroh/utils";
import { cva, type VariantProps } from "class-variance-authority";
import React from "react";
import { cn } from "../../lib/utils";

const buttonVariants = cva(
"inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",
Expand Down
7 changes: 7 additions & 0 deletions packages/ui/src/lib/utils.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
/* eslint-disable @typescript-eslint/explicit-function-return-type -- no */
import { clsx, type ClassValue } from "clsx";
import { twMerge } from "tailwind-merge";

export function cn(...inputs: ClassValue[]) {
return twMerge(clsx(inputs));
}
14 changes: 7 additions & 7 deletions packages/ui/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"extends": "tsconfig/react-library.json",
"include": ["."],
"exclude": ["dist", "build", "node_modules"],
"compilerOptions": {
"baseUrl": ".",
"paths": {
"@ui/*": ["./src/*"]
}
}
"exclude": ["dist", "build", "node_modules"]
// "compilerOptions": {
// "baseUrl": ".",
// "paths": {
// "@/ui/*": ["./src/*"]
// }
// }
}
4 changes: 3 additions & 1 deletion packages/ui/tsup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,15 @@ import { defineConfig, Options } from "tsup";

export default defineConfig((options: Options) => ({
entry: ["src/**/*.tsx"],
format: ["esm"],
format: ["esm", "cjs"],
esbuildOptions(options) {
options.banner = {
js: '"use client"',
};
},
dts: true,
target: "es2019",
clean: true,
minify: true,
external: ["react"],
...options,
Expand Down
2 changes: 1 addition & 1 deletion packages/utils/tsup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { defineConfig, Options } from "tsup";

export default defineConfig((options: Options) => ({
entry: ["src/**/*.ts"],
format: ["esm"],
format: ["esm", "cjs"],
dts: true,
minify: true,
external: ["react"],
Expand Down
3 changes: 0 additions & 3 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 0 additions & 3 deletions tsconfig.json

This file was deleted.

0 comments on commit 4fb4461

Please sign in to comment.