--- title: "内置代码样式升级" categories: [ "前端技术" ] tags: [ ] draft: false slug: "code-highlight-plugin" date: "2020-11-18 18:04:00" --- 刚刚做了一些博客的调整,包括友链,各位可以申请友链了。 新增了[代码高亮插件][1],感谢作者。我也进行了一些CSS的调整,比如适配了各种移动设备,并且能够根据移动设备是否开启夜间模式进行自适应,各位可以切换一下手机的夜间模式,看一下主题的变化。 **随便引一段JS代码** ```js import Vue from 'vue' import App from './App.vue' import router from './router' import store from './store' import ViewUI from 'view-design' import 'view-design/dist/styles/iview.css'; Vue.use(ViewUI); Vue.config.productionTip = false router.beforeEach((to, from, next) => { if (to.meta.title) { document.title = to.meta.title } next() }) new Vue({ router, store, render: h => h(App) }).$mount('#app') ``` [1]: https://www.xcnte.com/archives/523/