初学
更新时间: 2024-05-22 13:50:22
# Create an app
npx nuxi@latest init <project-name>
cd <project-name>
npm run dev -- -o
1
2
3
4
5
2
3
4
5
Now that you've created your Nuxt3 project.
# alias
import {resolve} from "path"
// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
alias: {
'@': resolve(__dirname,"/")
}
})
1
2
3
4
5
6
7
2
3
4
5
6
7
# 安装sass, tailwincss
根据文档配置好tailwindcss https://tailwindcss.com/docs/guides/nuxtjs#standard (opens new window)
npm i sass
npm install -D tailwindcss postcss autoprefixer
npx tailwindcss init
1
2
3
4
2
3
4