Skip to content

Commit

Permalink
chore: clean ts errors in ui
Browse files Browse the repository at this point in the history
  • Loading branch information
SaadBazaz committed Aug 11, 2024
1 parent 1471ebc commit 53df8c5
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 9 deletions.
6 changes: 3 additions & 3 deletions packages/ui/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,12 @@ We're looking for maintainers and contributors!
- [ ] Make sure all native Web Components are properly working
- [x] Demo all components
- [x] Add all missing events
- [ ] Add theming (design tokens) through Tailwind (i.e. remove all ts-ignores)
- [ ] [Need help] Add theming (design tokens) through Tailwind (i.e. remove all ts-ignores) (https://github.com/grayhatdevelopers/material-web-components-react/pull/2)
- [x] Resolve SSR/SSG issues, make compatible with NextJS (i.e. remove all dynamic imports)
- [x] Separate the demo from the actual UI code
- [x] Make installable as a package.
- [ ] Make installable as code-in-project, like shadcn/ui, so developers have more control
- [ ] Add better TypeScript support
- [ ] [Need help] Make installable as code-in-project, like shadcn/ui, so developers have more control (https://github.com/grayhatdevelopers/material-web-components-react/pull/11)
- [ ] [Need help] Add better TypeScript support (https://github.com/grayhatdevelopers/material-web-components-react/issues/12)
- [ ] Sync with upstream (i.e. https://github.com/material-components/material-web/blob/main/docs/intro.md) through webhooks and automations
- [ ] Use [Copybara](https://github.com/google/copybara) (or good ol' GitHub webhooks) to automate syncing with upstream
- [ ] Use [lit-analyzer](https://www.npmjs.com/package/lit-analyzer) to see which Web Components changed. Perhaps mix with an LLM to compare existing and newly autogenerated code.
Expand Down
2 changes: 1 addition & 1 deletion packages/ui/src/app-bar/index.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React, { useEffect, useRef, useState } from "react";
import { twMerge } from "tailwind-merge";
import { findSlotProp, removeSlotProps } from "../utils";
import { findSlotProp, removeSlotProps } from "../utils/index.js";

const AppBar = ({
className,
Expand Down
2 changes: 1 addition & 1 deletion packages/ui/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@
"compilerOptions": {
"outDir": "dist"
},
"include": ["**/*"],
"include": ["**/*", "*.cjs"],
"exclude": ["node_modules", "dist"]
}
2 changes: 1 addition & 1 deletion packages/ui/tsconfig.lint.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@
"compilerOptions": {
"outDir": "dist"
},
"include": ["src", "turbo", "./*.ts"],
"include": ["src", "turbo", "**/*.ts*", "*.cjs"],
"exclude": ["node_modules", "dist"]
}
5 changes: 2 additions & 3 deletions packages/ui/tsup.config.ts
Original file line number Diff line number Diff line change
@@ -1,17 +1,16 @@
import glob from "tiny-glob";
import { defineConfig } from "tsup";
import tailwind from "tailwindcss";
import autoprefixer from "autoprefixer";

export default defineConfig(async (options) => ({
clean: true,
entry: await glob("./src/**/!(*.d|*.spec).tsx"),
splitting: true,
target: "es5",
format: "esm",
// dts: true,
treeshake: true,
bundle: true,
// sourcemap: true,
outDir: "./dist",
minify: !options.watch,
plugins: [tailwind(), autoprefixer()],
}));

0 comments on commit 53df8c5

Please sign in to comment.