You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I didn't find the solution.
As it was a test to learn about the technology, I ended up choosing another
technology.
Em seg., 20 de jan. de 2025 às 18:40, Lucas Hoz ***@***.***>
escreveu:
node version: 20.11.1
Plataform: Windows
Problem
Im problem import component Card with @material-tailwind/react
Follow the steps below to reproduce
I followed the installation guide and it didn't work
https://www.material-tailwind.com/docs/react/guide/astro
1 Step
npm create astro@latest
npx astro add tailwind
npx astro add react
npm i @material-tailwind/react
2 Step
`const withMT = require("@material-tailwind/react/utils/withMT");
module.exports = withMT({
content: [
"./src//*.{astro,html,js,jsx,md,mdx,svelte,ts,tsx,vue}",
"path-to-your-node_modules/@material-tailwind/react/components//.{js,ts,jsx,tsx}",
"path-to-your-node_modules/@material-tailwind/react/theme/components/**/.{js,ts,jsx,tsx}",
],
theme: {
extend: {},
},
plugins: [],
});`
3 Step
`import {
Card,
CardHeader,
CardBody,
CardFooter,
Typography,
Button,
} from "@material-tailwind/react";
export function CardDefault() {
return (
UI/UX Review Check
The place is close to Barceloneta Beach and bus stop just 2 min by
walk and near to "Naviglio" where you can enjoy the main
night life in Barcelona.
Read More
);
}`
4 Step
call component index.astro
<CardDefault />
##package.json
{ "name": "better-bar", "type": "module", "version": "0.0.1", "scripts": { "dev": "astro dev", "start": "astro dev", "build": "astro check && astro build", "preview": "astro preview", "astro": "astro" }, "dependencies": { "@astrojs/check": "^0.9.3", "@astrojs/react": "^3.6.2", "@astrojs/tailwind": "^5.1.0", "@material-tailwind/react": "^2.1.9", "@types/react": "^18.3.5", "@types/react-dom": "^18.3.0", "astro": "^4.15.2", "react": "^18.3.1", "react-dom": "^18.3.1", "tailwindcss": "^3.4.10", "typescript": "^5.5.4" } }
The text was updated successfully, but these errors were encountered: