refactor: use raw-loader to import template, update directive usage in demo
This commit is contained in:
11
common/play/templates/.prettierrc.raw
Normal file
11
common/play/templates/.prettierrc.raw
Normal file
@@ -0,0 +1,11 @@
|
||||
{
|
||||
"printWidth": 80,
|
||||
"tabWidth": 2,
|
||||
"useTabs": false,
|
||||
"semi": false,
|
||||
"singleQuote": true,
|
||||
"trailingComma": "none",
|
||||
"bracketSpacing": true,
|
||||
"jsxBracketSameLine": false,
|
||||
"fluid": false
|
||||
}
|
||||
21
common/play/templates/App.raw.vue
Normal file
21
common/play/templates/App.raw.vue
Normal file
@@ -0,0 +1,21 @@
|
||||
<template>
|
||||
<main>
|
||||
<demo/>
|
||||
</main>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import Demo from './Demo'
|
||||
|
||||
export default {
|
||||
components: {
|
||||
Demo
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
main {
|
||||
padding: 24px;
|
||||
}
|
||||
</style>
|
||||
12
common/play/templates/index.raw.html
Normal file
12
common/play/templates/index.raw.html
Normal file
@@ -0,0 +1,12 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="zh-Hans">
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
||||
<meta name="viewport" content="width=device-width,initial-scale=1.0" />
|
||||
<title>VEUI Playground</title>
|
||||
</head>
|
||||
<body>
|
||||
<div id="app"></div>
|
||||
</body>
|
||||
</html>
|
||||
33
common/play/templates/landing.raw.html
Normal file
33
common/play/templates/landing.raw.html
Normal file
@@ -0,0 +1,33 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="zh-Hans">
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
||||
<meta name="viewport" content="width=device-width,initial-scale=1.0" />
|
||||
<title>VEUI Playground</title>
|
||||
<style>
|
||||
* {
|
||||
box-sizing: border-box;
|
||||
}
|
||||
body {
|
||||
position: relative;
|
||||
width: 100vw;
|
||||
height: 100vh;
|
||||
margin: 0;
|
||||
background-color: #040404;
|
||||
}
|
||||
.loading {
|
||||
position: absolute;
|
||||
top: 38.4%;
|
||||
left: 50%;
|
||||
transform: translate(-50%, -38.4%);
|
||||
height: 48px;
|
||||
font-weight: 400;
|
||||
color: #fff;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
{{loading}}
|
||||
</body>
|
||||
</html>
|
||||
11
common/play/templates/main.raw.js
Normal file
11
common/play/templates/main.raw.js
Normal file
@@ -0,0 +1,11 @@
|
||||
import Vue from 'vue'
|
||||
import App from './App.vue'
|
||||
import 'veui-theme-dls/dist/dls.esm'
|
||||
import 'veui-theme-dls-icons/dist/icons.esm'
|
||||
import 'veui/dist/locale.{{locale}}.esm'
|
||||
|
||||
Vue.config.productionTip = false
|
||||
|
||||
new Vue({
|
||||
render: (h) => h(App)
|
||||
}).$mount('#app')
|
||||
7
common/play/templates/package.raw
Normal file
7
common/play/templates/package.raw
Normal file
@@ -0,0 +1,7 @@
|
||||
{
|
||||
"dependencies": {
|
||||
"veui": "2.1.2",
|
||||
"veui-theme-dls": "2.1.2",
|
||||
"vue": "2.6.14"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user