diff --git a/package.json b/package.json index c565ba8..83db400 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "vue-routing-anchor-parser", - "version": "1.12.0", + "version": "1.13.0", "description": "A Vue directive that parses child elements for internally linking anchor tags and binds their click events to use Vue Router's push().", "main": "index.js", "scripts": { diff --git a/smart-link.js b/smart-link.js index 7db8180..df9c462 100644 --- a/smart-link.js +++ b/smart-link.js @@ -30,6 +30,7 @@ exports.default = { render: function render(create, _ref) { var to = _ref.props.to, data = _ref.data, + listeners = _ref.listeners, children = _ref.children; if (!to) { @@ -39,6 +40,7 @@ exports.default = { if ((0, _index.isInternal)(to)) { // Render a nuxt-link return create('nuxt-link', _extends({}, data, { + nativeOn: listeners, // nuxt-link doesn't forward events on it's own props: { to: (0, _index.makeRouterPath)(to) }