
Security News
New CVE Forecasting Tool Predicts 47,000 Disclosures in 2025
CVEForecast.org uses machine learning to project a record-breaking surge in vulnerability disclosures in 2025.
vue-linkify
Advanced tools
A simple Vue directive to turn URL's and emails into clickable links. Based on SoapBox's Linkify.
This directive can be installed as a module:
$ npm install vue-linkify
or, if you're not in a module environment, just include it as a <script>
.
In a browser environment, you should now have a v-linkified
directive set up for free. If you're in a module environment, just import
and register it as you please:
import linkify from 'vue-linkify'
Vue.directive('linkified', linkify)
And then you use it away:
<template>
<div id="app">
<div v-html="raw" v-linkified />
</div>
</template>
<script>
export default {
data () {
return {
raw: 'Hello from vuejs.org'
}
}
}
</script>
The above snippet will yield:
Hello from <a href="http://vuejs.org" class="linkified" target="_blank">vuejs.org</a>
You can also pass an options
argument, which takes an Object
, into the directive to control its behavior. For example, modifying the above template into something like this:
<template>
<div id="app">
<div v-html="raw" v-linkified:options="{ className: 'foo' }" />
</div>
</template>
will yield a slightly different HTML:
Hello from <a href="http://vuejs.org" class="foo" target="_blank">vuejs.org</a>
A list of available options is available here.
MIT © Phan An
FAQs
A simple Vue directive to turn URL's and emails into clickable links
The npm package vue-linkify receives a total of 3,469 weekly downloads. As such, vue-linkify popularity was classified as popular.
We found that vue-linkify demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
CVEForecast.org uses machine learning to project a record-breaking surge in vulnerability disclosures in 2025.
Security News
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
Research
Security News
Eight new malicious Firefox extensions impersonate games, steal OAuth tokens, hijack sessions, and exploit browser permissions to spy on users.