tailcallhq / tailcall

High Performance GraphQL Runtime
https://tailcall.run
Apache License 2.0
1.19k stars 214 forks source link

transformer to flatten out types with single field #2343

Open tusharmath opened 4 days ago

tusharmath commented 4 days ago

Write a config/transformer that unwraps types with one field.

FROM

type Query {
  foo: Foo
}

# Type with only one field
type Foo { 
  bar: Bar
}

# Type with only one field
type Bar {
  a: Int
}

TO

type Query {
  foo: Int
}

This can be achieved by using the addField and omit operators.

Technical Requirements

IMPORTANT

tusharmath commented 4 days ago

/bounty 100$

algora-pbc[bot] commented 4 days ago

💎 $100 bounty • Tailcall Inc.

Steps to solve:

  1. Start working: Comment /attempt #2343 with your implementation plan
  2. Submit work: Create a pull request including /claim #2343 in the PR body to claim the bounty
  3. Receive payment: 100% of the bounty is received 2-5 days post-reward. Make sure you are eligible for payouts

🙏 Thank you for contributing to tailcallhq/tailcall! 🧐 Checkout our guidelines before you get started. 💵 More about our bounty program.

Attempt Started (GMT+0) Solution
🔴 @varshith257 Jul 3, 2024, 2:27:09 PM WIP
🔴 @LeoLeSommer Jul 3, 2024, 6:01:28 PM WIP
🟡 @Shylock-Hg Jul 4, 2024, 1:45:36 AM #2356
🔴 @ssddOnTop Jul 5, 2024, 4:58:26 AM WIP
varshith257 commented 4 days ago

/attempt #2343

Algora profile Completed bounties Tech Active attempts Options
@varshith257 3 bounties from 2 projects
TypeScript, Go
Cancel attempt
Shylock-Hg commented 4 days ago

/attempt #2343

Algora profile Completed bounties Tech Active attempts Options
@Shylock-Hg    8 tailcallhq bounties
+ 3 bounties from 3 projects
C++, C,
Shell & more
Cancel attempt
LeoLeSommer commented 4 days ago

/attempt #2343

I have never contributed to any open source project before, so I will just try to see if I can manage to do something. This is just a test for me, so please feel free to ignore my attempt if you want to try to solve the issue yourself.

algora-pbc[bot] commented 4 days ago

[!NOTE] The user @varshith257 is already attempting to complete issue #2343 and claim the bounty. We recommend checking in on @varshith257's progress, and potentially collaborating, before starting a new solution.

varshith257 commented 4 days ago

@LeoLeSommer I am in support of you. Have a chance to you to solve this issue and I'll take up if you give up on it

LeoLeSommer commented 4 days ago

Thanks, i tell you if I'm stuck

algora-pbc[bot] commented 3 days ago

@varshith257: Reminder that in 1 days the bounty will become up for grabs, so please submit a pull request before then 🙏

algora-pbc[bot] commented 3 days ago

@LeoLeSommer: Reminder that in 1 days the bounty will become up for grabs, so please submit a pull request before then 🙏

LeoLeSommer commented 3 days ago

@varshith257 You can try to solve the issue if you want

algora-pbc[bot] commented 3 days ago

@Shylock-Hg: Reminder that in 1 days the bounty will become up for grabs, so please submit a pull request before then 🙏

Shylock-Hg commented 3 days ago

@varshith257 Are you working on it?

varshith257 commented 3 days ago

Not yet

Shylock-Hg commented 3 days ago

Not yet

Ok, I want to try it if you agree.

varshith257 commented 3 days ago

Sure @Shylock-Hg I have occupied with other works. Maybe I didn't get time to solve it till this weekend

ssddOnTop commented 3 days ago

/attempt #2343

Algora profile Completed bounties Tech Active attempts Options
@ssddOnTop 50 tailcallhq bounties
Rust, Java,
C & more
Cancel attempt
algora-pbc[bot] commented 3 days ago

💡 @Shylock-Hg submitted a pull request that claims the bounty. You can visit your bounty board to reward.

algora-pbc[bot] commented 2 days ago

@ssddOnTop: Reminder that in 1 days the bounty will become up for grabs, so please submit a pull request before then 🙏