Giter Site home page Giter Site logo

Comments (10)

jasikpark avatar jasikpark commented on May 19, 2024 1

I'm glad to see that synckit seems to dramatically improve things! v0.1.0-next.4 runs about the same speed as 0.0.11 for me 😁

from prettier-plugin-astro.

antonyfaris avatar antonyfaris commented on May 19, 2024

Hi, thanks for opening this issue. We are aware of this problem. This happens due to the package make-synchronous that we use while we wait for Prettier to support esm. next is a pre-release meant for testing. I suggest you keep using latest for production.

from prettier-plugin-astro.

hayley avatar hayley commented on May 19, 2024

Thanks for the quick reply!

I had run into a transient error earlier in the upgrade using latest on the project so I thought maybe that next was the way to go for 0.25, but since that seems resolved (may have been a temporary syntax error I introduced when upgrading), I'll keep using latest for now.

Thanks again!

from prettier-plugin-astro.

jasikpark avatar jasikpark commented on May 19, 2024

Hi, thanks for opening this issue. We are aware of this problem. This happens due to the package make-synchronous that we use while we wait for Prettier to support esm. next is a pre-release meant for testing. I suggest you keep using latest for production.

Is that b/c @astrojs/compiler doesn't support cjs?

from prettier-plugin-astro.

jasikpark avatar jasikpark commented on May 19, 2024

Thankfully it looks like prettier is working on transitioning to support esm: prettier/prettier#10157 (comment)

from prettier-plugin-astro.

jasikpark avatar jasikpark commented on May 19, 2024

https://github.com/prettier/prettier/pull/12343/files might be a good case study in how to write it 🤔

from prettier-plugin-astro.

jasikpark avatar jasikpark commented on May 19, 2024

Also tracked by prettier/prettier#4459 which would make the parser async?

from prettier-plugin-astro.

jasikpark avatar jasikpark commented on May 19, 2024

https://github.com/rx-ts/synckit suggested in prettier#4459 might be a faster solution in the meantime than make-synchronous: prettier/prettier#4459 (comment)

from prettier-plugin-astro.

antonyfaris avatar antonyfaris commented on May 19, 2024

Is that b/c @astrojs/compiler doesn't support cjs?

Yes, that's correct.

Thankfully it looks like prettier is working on transitioning to support esm: prettier/prettier#10157 (comment)

Also tracked by prettier/prettier#4459 which would make the parser async?

Yeah, we are keeping an eye on those issues.

https://github.com/prettier/prettier/pull/12343/files might be a good case study in how to write it 🤔

https://github.com/rx-ts/synckit suggested in prettier#4459 might be a faster solution in the meantime than make-synchronous: prettier/prettier#4459 (comment)

Thank you for the suggestions!

from prettier-plugin-astro.

Princesseuh avatar Princesseuh commented on May 19, 2024

Closing at this has been fixed in v0.1.0-next.4. Performance is still not perfect, however it's much much better than before

from prettier-plugin-astro.

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.