All Projects → metachris → Vue Highlightjs

metachris / Vue Highlightjs

Syntax highlighting with highlight.js for Vue.js 2.x

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Vue Highlightjs

vue2-calendar
A lightweight calendar component for Vue2
Stars: ✭ 54 (-81.69%)
Mutual labels:  vuejs2
Vuejs Component Style Guide
Vue.js Component Style Guide
Stars: ✭ 2,796 (+847.8%)
Mutual labels:  vuejs2
Mui Vue2
mui+mint+vue2.x+vue-router+vuex+webpack最终打包成原生apk的app项目,样式使用vue移动端mint ui框架,原生手机能力偏重于mui框架,欢迎star!
Stars: ✭ 278 (-5.76%)
Mutual labels:  vuejs2
vue-popover
Reusable popover component for Vue
Stars: ✭ 22 (-92.54%)
Mutual labels:  vuejs2
Vue Form Generator
📋 A schema-based form generator component for Vue.js
Stars: ✭ 2,853 (+867.12%)
Mutual labels:  vuejs2
Formvuelar
Vue form components with server-side validation in mind
Stars: ✭ 263 (-10.85%)
Mutual labels:  vuejs2
munhasir
Sample RESTful single page web app with Go, MongoDB and VueJS. A platform for keeping diaries for those who are cautious(or paranoid).
Stars: ✭ 24 (-91.86%)
Mutual labels:  vuejs2
Draggable Vue Directive
Vue2 directive that handles drag & drop
Stars: ✭ 286 (-3.05%)
Mutual labels:  vuejs2
Tui
This is a high quanlity components library for VUE
Stars: ✭ 258 (-12.54%)
Mutual labels:  vuejs2
Vuejs Firebase Shopping Cart
Shopping cart demo using Vuejs and Firebase
Stars: ✭ 274 (-7.12%)
Mutual labels:  vuejs2
Iview2 Management System
a basic management system example written by iview2.0 & Vue2.
Stars: ✭ 255 (-13.56%)
Mutual labels:  vuejs2
Coreui Free Vue Admin Template
Open source admin template based on Bootstrap 5 and Vue 3
Stars: ✭ 2,951 (+900.34%)
Mutual labels:  vuejs2
Vim Cool
A very simple plugin that makes hlsearch more useful.
Stars: ✭ 268 (-9.15%)
Mutual labels:  highlighting
vuejs-uib-pagination
Best and complete pagination plugin for Vue.js. Inspired in Angular Bootstrap Pagination.
Stars: ✭ 58 (-80.34%)
Mutual labels:  vuejs2
Vuejs Serverside Template Xss
Demo of a Vue.js app that mixes both clientside templates and serverside templates leading to an XSS vulnerability
Stars: ✭ 278 (-5.76%)
Mutual labels:  vuejs2
vue-sauce
"View source" directive for Vue
Stars: ✭ 90 (-69.49%)
Mutual labels:  vuejs2
Cadence Web
Web UI for visualizing workflows on Cadence
Stars: ✭ 261 (-11.53%)
Mutual labels:  vuejs2
Paascloud Mall Web
模拟商城,完整的购物流程、后端运营平台,使用 spring cloud + vue 全家桶实现快速搭建企业级微服务项目
Stars: ✭ 287 (-2.71%)
Mutual labels:  vuejs2
Vue Typed Js
Typed.js integration for vue.js. Create a typing animation.
Stars: ✭ 285 (-3.39%)
Mutual labels:  vuejs2
Office Ui Fabric Vue
Office UI Fabric implementation for Vue.js
Stars: ✭ 273 (-7.46%)
Mutual labels:  vuejs2

vue-highlightjs

Vue.js syntax highlighting made easy, using highlight.js.

Build Status

Quickstart

Installation

Simply install the npm package vue-highlightjs:

npm install --save vue-highlightjs

Using vue-highlightjs

In your main JavaScript file (eg. main.js):

// Import Vue and vue-highlgihtjs
import Vue from 'vue'
import VueHighlightJS from 'vue-highlightjs'

// Tell Vue.js to use vue-highlightjs
Vue.use(VueHighlightJS)

In your template, in order to highlight javascript code:

<!-- If your source-code lives in a variable called 'sourcecode' -->
<pre v-highlightjs="sourcecode"><code class="javascript"></code></pre>

<!-- If you want to highlight hardcoded source-code -->
<pre v-highlightjs><code class="javascript">const s = new Date().toString()</code></pre>

Contributing

Any sort of contributions and feedback is much appreciated. Just leave an issue or pull-request!

This project uses the AirBnB code style.

Please run npm run lint and npm run test before you submit a pull request! <3

About

Author: Chris Hager [email protected] (https://www.metachris.com)

License: MIT

Contributors:

Changelog

v1.3.3

  • Documentation

v1.3.1

  • Changed const to var for compatibility with PhantomJS and UglifyJS
  • Bugfix to allow empty content

v1.2.2

  • Fixed displaying and highlighting HTML tags passed as value to the directive (thanks @nguyenvanduocit)
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].