Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(packages/ui turbo gen config.ts): Preventing the format of pack… #8033

Merged
merged 2 commits into from
Jun 15, 2024

Conversation

moeyashi
Copy link
Contributor

@moeyashi moeyashi commented Apr 24, 2024

…age.json from being corrupted

Description

Prevent the format of package.json from getting corrupted when creating a component with turbo gen.

Here's what the exports section looks like before and after the fix:

before

  "exports": {
"./foo": "./src/foo.tsx",
    "./button": "./src/button.tsx",
    "./card": "./src/card.tsx",
    "./code": "./src/code.tsx"
  },

after

  "exports": {
    "./foo": "./src/foo.tsx",
    "./button": "./src/button.tsx",
    "./card": "./src/card.tsx",
    "./code": "./src/code.tsx"
  },

Testing Instructions

  1. Create a component with turbo gen.
  2. Check package.json.

@moeyashi moeyashi requested review from anthonyshew and a team as code owners April 24, 2024 08:00
@moeyashi moeyashi requested a review from gsoltis April 24, 2024 08:00
@turbo-orchestrator turbo-orchestrator bot added area: examples Improvements or additions to examples owned-by: turborepo labels Apr 24, 2024
Copy link

vercel bot commented Apr 24, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
examples-basic-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 15, 2024 11:10pm
examples-designsystem-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 15, 2024 11:10pm
examples-gatsby-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 15, 2024 11:10pm
examples-kitchensink-blog ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 15, 2024 11:10pm
examples-native-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 15, 2024 11:10pm
examples-nonmonorepo ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 15, 2024 11:10pm
examples-svelte-web ❌ Failed (Inspect) Jun 15, 2024 11:10pm
examples-tailwind-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 15, 2024 11:10pm
examples-vite-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 15, 2024 11:10pm
rust-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 15, 2024 11:10pm

Copy link

vercel bot commented Apr 24, 2024

@moeyashi is attempting to deploy a commit to the Vercel Team on Vercel.

A member of the Team first needs to authorize it.

@anthonyshew
Copy link
Contributor

Hi, thanks for the contribution!

Can you explain a little more about the nature of the "corruption" this PR is meant to solve?

@moeyashi
Copy link
Contributor Author

Thank you for your review.

I edited this issue to explain what this PR is trying to solve.

"corrupted" may not be a good expression. "broken", "incorrect" and "wrong" are candidates.

@anthonyshew
Copy link
Contributor

Just so I'm clear on what I'm seeing here: There's a missing tab character when the generator is run?

@moeyashi
Copy link
Contributor Author

moeyashi commented May 7, 2024

Yes, there's a missing tab character.

But my fix is ​​to indent with 4 spaces instead of a tab character.

Copy link
Contributor

@anthonyshew anthonyshew left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good! Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: examples Improvements or additions to examples needs: triage New issues get this label. Remove it after triage owned-by: turborepo
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants