giscus / giscus-component

Component library for giscus, a comment system powered by GitHub Discussions.
https://giscus-component.vercel.app
MIT License
304 stars 25 forks source link

Support Vue 2 #14

Closed davestewart closed 2 years ago

davestewart commented 2 years ago

Is your feature request related to a problem? Please describe.

The lib only supports Vue 3

Describe the solution you'd like

Support Vue 2

Describe alternatives you've considered

Writing it myself

davestewart commented 2 years ago

I've taken a look at the component which is pretty straightforward to migrate, but the build setup looks more complicated.

Not 100% sure how to get the conflicting versions of vue to work in the same project, with vite.

Happy to push what I have if you want to tackle that bit?

laymonage commented 2 years ago

Not 100% sure how to get the conflicting versions of vue to work in the same project, with vite. Happy to push what I have if you want to tackle that bit?

Unfortunately I don't know how to do that bit either...

I'm thinking about reimplementing this library as a Web Component instead, because this is getting painful to maintain :slightly_frowning_face:

davestewart commented 2 years ago

Probably a good idea!

Though I don't know much about them either.

FWIW I forked locally and got it working.

laymonage commented 2 years ago

I've released the web component. Those who want to use this library on Vue 2 can use the web component instead (npm install giscus). Take a look at this code on how it's used on Vue 3 and adapt accordingly.