Giter Club home page Giter Club logo

Comments (7)

ohabash avatar ohabash commented on May 1, 2024 1

Please dont give up on this topic. Look at my repo. the error is caused by simply having the imort in a component. so in the repo how would you apply that advice of afterNextRender & if(isPlatformBrowser())...

As this forum might not be the correct place to find help. where do you recommend i find help?

@JeanMeche

from angular.

JeanMeche avatar JeanMeche commented on May 1, 2024 1

You're using a default export here, you need to access that constructor.

const module = await import('quill');
this.editor = new module.Quill(...)

from angular.

ohabash avatar ohabash commented on May 1, 2024 1

That seems to work. I updated the repo https://github.com/ohabash/ng-ssr-quill

from angular.

JeanMeche avatar JeanMeche commented on May 1, 2024

Hi,
The common recommandation is to wrap client only library invocation inside afterNextRender() or with if(isPlatformBrowser()) which will run the code only on the client and not on the server.

from angular.

JeanMeche avatar JeanMeche commented on May 1, 2024

This means you'll likely need to import your library dynamicaly. (via a dynamic import).

Stackoverflow or the Angular Community discord are good places for getting help from the community.

from angular.

ohabash avatar ohabash commented on May 1, 2024

Is something like this what you had in mind?

Screenshot 2024-04-09 at 10 12 26 AM
Screenshot 2024-04-09 at 10 14 12 AM

please. I need to know how to do this and other sources are not helping.

from angular.

bxbdev avatar bxbdev commented on May 1, 2024

That seems to work. I updated the repo https://github.com/ohabash/ng-ssr-quill

Thanks, it's worked!!!

from angular.

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.