Coder Social home page Coder Social logo

Comments (9)

jsonpreet avatar jsonpreet commented on June 17, 2024 1

Hey @reecejohnson

Thank you for help me on this.

from lens-sdk.

cesarenaldi avatar cesarenaldi commented on June 17, 2024

I understand this fix solves this error: https://github.com/lens-protocol/lens-sdk/blob/lens-v2/examples/nextjs/next.config.js#L6

At some point in the coming weeks update the examples/nextjs too (still uses 1.3).

from lens-sdk.

jsonpreet avatar jsonpreet commented on June 17, 2024

No, not working still getting same error

image

from lens-sdk.

cesarenaldi avatar cesarenaldi commented on June 17, 2024

oh, sorry got confused reading. It was about the error you reported for the non turboRepo attempt.

from lens-sdk.

jsonpreet avatar jsonpreet commented on June 17, 2024

Ok wait I think it's working but not if use NextJs App Directory, standalone NextJs App without turborepo

from lens-sdk.

reecejohnson avatar reecejohnson commented on June 17, 2024

@jsonpreet thanks for reporting this, glad to see you got it sorted. I'm investigating why this might have happened. Will keep this thread up to date with my findings

from lens-sdk.

reecejohnson avatar reecejohnson commented on June 17, 2024

Hey @jsonpreet,

I have put together a very basic example of how to use the react SDK with nextjs 13 app directory, see the open PR here: https://github.com/lens-protocol/lens-sdk/pull/669/files#diff-9088a6cd89d9eb78bb295f0313b8bfd86e95e0b7ff50f7f89211db6ae5734933R1

Of particular interest is the src/components/providers.tsx component, that uses the use client directive. Here we group together the different providers, in this case Wagmi and the Lens providers, within a client side component that can be referenced in your root layout.tsx.

Each component that uses a lens react hook must also apply the use client directive.

If you need Lens data in an SSR scenario, you can explore the @lens-protocol/client package to facilitate server side calls to the Lens API.

from lens-sdk.

cesarenaldi avatar cesarenaldi commented on June 17, 2024

@jsonpreet all good with this issue then? can I close it?

from lens-sdk.

jsonpreet avatar jsonpreet commented on June 17, 2024

Yes it's working. Thanks

from lens-sdk.

Related Issues (20)

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.