Coder Social home page Coder Social logo

Comments (11)

AlbanCrepel avatar AlbanCrepel commented on June 21, 2024 6

Hi @nla1989 @andreasantonsson @SixBytesUnder @nataliawww @NikitaLoshchenin !
I am glad to announce that the bug is fixed in the last release of this component (v1.2.0) ! 🎉
It is now working in Nuxt projects in production mode. The problem came from the minification of build files from webpack...

from vue-displacement-slideshow.

AlbanCrepel avatar AlbanCrepel commented on June 21, 2024 4

Hi @nataliawww and @NikitaLoshchenin , I am sorry I didn't have the opportunity to try nuxt.js yet... But when I do I'll have a look at your issue 👍

from vue-displacement-slideshow.

andreasantonsson avatar andreasantonsson commented on June 21, 2024 2

I'm running a universal nuxt.js (2.7.1) app. The <no-ssr> did the trick in development, but I'm still getting the i.setValue is not a function in production.

Anyone else having the same issue still?

from vue-displacement-slideshow.

AlbanCrepel avatar AlbanCrepel commented on June 21, 2024 1

@nla1989 I know about the problem, and have already tried to have a look at it and fix it, without success. When a copy paste the component and use it in a nuxt project, it works. But when I use the library with the built files, it doesn't work because of the error you mentioned. I will try my best to fix this 🙏
And for your information, I also worked on a version implementing the displacement effect on videos ! But this will take time to deploy...

from vue-displacement-slideshow.

NikitaLoshchenin avatar NikitaLoshchenin commented on June 21, 2024

Would be great to add SSR support so it works with nuxt.js too
Do you have any problems with production mode?
i.setValue is not a function in browser dev tols with default nuxt configuration.config.js

from vue-displacement-slideshow.

nataliawww avatar nataliawww commented on June 21, 2024

Would be great to add SSR support so it works with nuxt.js too
Do you have any problems with production mode?
i.setValue is not a function in browser dev tols with default nuxt configuration.config.js

Yes, I have the same problem

from vue-displacement-slideshow.

SixBytesUnder avatar SixBytesUnder commented on June 21, 2024

I tried using it as a client side plugin in nuxt.js

plugins: [
	{ src: '~/plugins/vue-displacement-slideshow', mode: 'client' }
	// { src: '~/plugins/vue-displacement-slideshow', ssr: false } // pre nuxt 2.4.0
],

but it fails with error message:
[Vue warn]: Error in beforeCreate hook: "ReferenceError: document is not defined"

@AlbanCrepel please look into integrating with nuxt :)

from vue-displacement-slideshow.

AlbanCrepel avatar AlbanCrepel commented on June 21, 2024

Hi @SixBytesUnder ! I just started using Nuxt so I'll dig into this issue as soon as I can !

from vue-displacement-slideshow.

SixBytesUnder avatar SixBytesUnder commented on June 21, 2024

Fantastic, thank you :)
If you're interested, I want to use your plugin to nicely change background images on my project here https://github.com/SixBytesUnder/infoboard

from vue-displacement-slideshow.

AlbanCrepel avatar AlbanCrepel commented on June 21, 2024

Hi everyone !
@SixBytesUnder This syntax can't work :

plugins: [
{ src: '/plugins/vue-displacement-slideshow', mode: 'client' }
// { src: '
/plugins/vue-displacement-slideshow', ssr: false } // pre nuxt 2.4.0
],

Because vue-displacement-slideshow is not a plugin, it's just a component.
So if you want to use it with nuxt, you can wrap it between <no-ssr></no-ssr> tags, as explained in the documentation here. It could look like this :

<no-ssr>
    <vue-displacement-slideshow />
</no-ssr>

I tried it and it works, both in development and in production. I hope this solution is suitable for you all @nataliawww @NikitaLoshchenin @SixBytesUnder !

from vue-displacement-slideshow.

lna1989 avatar lna1989 commented on June 21, 2024

All setValue methods in the map are undefined in production mode with universal mode in Nuxt.js.
image
@AlbanCrepel Do you have any idea how to fix this error? I will be very grateful for any tip, as long as I have no idea what could be the problem. )

from vue-displacement-slideshow.

Related Issues (17)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.