oj/oj-vue/src/App.vue

70 lines
1.0 KiB
Vue

<template>
<div id="app">
<router-view></router-view>
</div>
</template>
<script>
export default {
name: 'App',
components: {},
}
const debounce = (fn, delay) => {
let timer = null;
return function () {
let context = this;
let args = arguments;
clearTimeout(timer);
timer = setTimeout(function () {
fn.apply(context, args);
}, delay);
};
};
const _ResizeObserver = window.ResizeObserver;
window.ResizeObserver = class ResizeObserver extends _ResizeObserver {
constructor(callback) {
callback = debounce(callback, 16);
super(callback);
}
};
</script>
<style>
#app {
font-family: Avenir, Helvetica, Arial, sans-serif;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
text-align: center;
color: #2c3e50;
background-color: #EFF3F5;
margin: 0px;
padding: 0px;
width: 100%;
height: 100%;
}
body, html {
margin: 0;
padding: 0;
height: 100%;
}
a {
text-decoration: none;
}
.content {
margin-top: 60px;
}
</style>