troxler / vue-headful

Set document title and meta tags with Vue.js
MIT License
229 stars 17 forks source link

Document Browser Compatibility and Polyfills #1

Closed KSVQ closed 6 years ago

KSVQ commented 6 years ago

Hey there, first let me just say that your plugin is really useful and it is easy to use.

I discovered a little nuisance today. IE11 is still a widely supported browser, especially in academia (I work for a company supporting academia :/ ). Use of vue-headful breaks the site with

Object doesn't support property or method 'assign'

You may want to look into using an ECMAScript 2015 (ES2015/ES6) Object.assign() polyfill and ponyfill for ECMAScript 5 environments to resolve this.

troxler commented 6 years ago

Hey there. Thank you and thanks for using it :)

I'm aware of browser incompatibilities, for example that is the reason why I don't use Object.entries (Edge) but Object.keys (IE9+). But I did intentionally not add any polyfills as that should be done in the user project rather than in a small library. Otherwise you would end up having several duplicate polyfill implementation for the same thing although your project maybe does not even need that. If you did not add a polyfill by yourself yet, you can find one at MDN or core-js.

But thanks either way for the "nudge", that is definitely something that I have to add to the documentation. I will use this issue to track that.

If you find something else, please let me know :)

KSVQ commented 6 years ago

I implemented my own, yes. But definitely might be a good idea to update documentation :)

Raiondesu commented 6 years ago

@KSVQ, @troxler, vue-simple-headful solves this. Maybe close this issue? Or you still need this for tracking purposes?

troxler commented 6 years ago

This is a different project and the documentation still has to be improved. So I'm keeping this issue open for now.

troxler commented 6 years ago

Updated README: https://github.com/troxler/vue-headful#compatibility