Code Monkey home page Code Monkey logo

Comments (7)

brodybits avatar brodybits commented on July 17, 2024 1

Thanks @jyoung295 for the response. The issue with printWidth definitely makes sense to me. I hope we will converge on a more consistent solution, someday in the future.

Closing now. Please don't hesitate to ask if you encounter any more issues or have any more questions in the future.

from prettierx.

brodybits avatar brodybits commented on July 17, 2024

EDITED: If I would try your first input on Prettier 1.16.4 playground, it works properly. Here is the playground link.

from prettierx.

brodybits avatar brodybits commented on July 17, 2024

My apologies, reopening

from prettierx.

jyoung295 avatar jyoung295 commented on July 17, 2024

I tried the first input in the playground link and it works fine. The prettier-standard package I'm using is using prettierx v0.3.0. Would that be the issue?

from prettierx.

brodybits avatar brodybits commented on July 17, 2024

The prettier-standard package I'm using is using prettierx v0.3.0.

Please try it on the most recent version (0.4.0). "Try on the latest version" is a step that someone has to take before determining whether or not it is still an issue.

from prettierx.

brodybits avatar brodybits commented on July 17, 2024

I just tried on my local prettierx project and it seems to format the first input correctly:

docRef.update({
  [`schedule.${this.state.currDbLoc}.submission`]: selectedSubmission
});

I also did not really understand what you meant by the last part of the description:

Apart from this issue I do also have issues happening just with the brackets on same line rule not being followed, I just thought this one would showcase more.

It would be great if you could try your code with the latest version of prettierx and report if you continue to see any other such issues or not.

from prettierx.

jyoung295 avatar jyoung295 commented on July 17, 2024

I tried with the latest prettierx and it didn't fix it. However, when I manually fixed it then ran the formatter, it didn't break it either. This led me to think that it could be a printWidth issue, so I set a large printWidth in a .prettierrc file and went back to using the prettier-standard package (which uses prettierx 0.3.0) and it worked totally fine.

In that last part I just meant I was seeing other places in my code where brackets were being separated to multiple lines, but those are all fixed aswell now.

Thanks for your help! I'm only a little embarrassed that it was such a simple issue 😅

from prettierx.

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.