반응형
Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | |||||
3 | 4 | 5 | 6 | 7 | 8 | 9 |
10 | 11 | 12 | 13 | 14 | 15 | 16 |
17 | 18 | 19 | 20 | 21 | 22 | 23 |
24 | 25 | 26 | 27 | 28 | 29 | 30 |
Tags
- webpack
- 네트워크
- IOS
- ReactNative
- xcode
- linux
- picker
- MAC
- react
- Android
- build
- MachineLearning
- PYTHON
- 맥
- Chrome
- jest
- TensorFlow
- 리눅스
- node
- qunit
- unittest
- localserver
- androidstudio
- vsCode
- VirtualBox
- 개발
- 센토스
- centos
- avds
Archives
- Today
- Total
로메오의 블로그
[Vue3 + typescript] Quasar 설치 [vite-plugin] 본문
반응형
VUE.JS 목록
Quasar 설치
$ npm install quasar @quasar/extras
$ npm install --save-dev @quasar/vite-plugin sass@1.32.12
main.ts
import { createApp } from "vue";
import { createPinia } from "pinia";
import App from "./App.vue";
import router from "./router";
import { Quasar } from "quasar";
import "@quasar/extras/material-icons/material-icons.css";
import "quasar/src/css/index.sass";
import "./assets/main.css";
const app = createApp(App);
app.use(Quasar, {
plugins: {},
});
app.use(createPinia());
app.use(router);
app.mount("#app");
vite.config.ts
import { fileURLToPath, URL } from "node:url";
import { defineConfig } from "vite";
import vue from "@vitejs/plugin-vue";
import { quasar, transformAssetUrls } from "@quasar/vite-plugin";
// https://vitejs.dev/config/
export default defineConfig({
plugins: [
vue({
template: { transformAssetUrls },
}),
quasar({
sassVariables: "src/quasar-variables.sass",
}),
],
resolve: {
alias: {
"@": fileURLToPath(new URL("./src", import.meta.url)),
},
},
});
src/quasar-variables.sass
$primary : #1976D2
$secondary : #26A69A
$accent : #9C27B0
$dark : #1D1D1D
$positive : #21BA45
$negative : #C10015
$info : #31CCEC
$warning : #F2C037
사용하기
<template>
<div>
<q-btn color="deep-orange" label="Hello" />
</div>
</template>
VUE.JS 목록
반응형
'Frontend > Vue' 카테고리의 다른 글
[Vue3 + typescript] provide, inject (0) | 2022.09.07 |
---|---|
[Vue3 + typescript] Quasar 설치 [quasar-cli] (0) | 2022.09.06 |
[Vue3 + typescript] reactive, ref, toRefs 반응성 주입 (0) | 2022.09.06 |
[Vue3 + typescript] Options, Composition, Setup 비교 (0) | 2022.09.06 |
[Vue3 + typescript] Volar 설치 (0) | 2022.09.05 |
Comments