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

Update php response to use primitive literal syntax instead of JSON #80

Merged
merged 9 commits into from
Sep 17, 2024

Conversation

andrii-balitskyi
Copy link
Contributor

@andrii-balitskyi andrii-balitskyi commented Sep 5, 2024

Closes #60

  • Fix createPhpResponse to return primitive literal syntax
  • Update blueprint to handle number params and props
  • Add number, object and array fixture props to test code samples, update snapshots

@andrii-balitskyi andrii-balitskyi requested a review from a team as a code owner September 5, 2024 10:53
Copy link

vercel bot commented Sep 5, 2024

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

Name Status Preview Comments Updated (UTC)
blueprint ✅ Ready (Inspect) Visit Preview 💬 Add feedback Sep 16, 2024 11:16am

response_syntax: 'javascript',
title: 'JavaScript',
},
php: {
request: `<?php␊
$seam->foos->get(foo_id:"8d7e0b3a-b889-49a7-9164-4b71a0506a33")`,
request_syntax: 'php',
response: '{"foo_id":"8d7e0b3a-b889-49a7-9164-4b71a0506a33","name":"Best foo","nullable_property":null}',
response: '["foo_id" => "8d7e0b3a-b889-49a7-9164-4b71a0506a33","name" => "Best foo","nullable_prop" => null,"number_prop" => 10,"object_prop" => ["foo" => "bar"],"array_prop" => ["foo", "bar"]]',
response_syntax: 'json',
Copy link
Collaborator

Choose a reason for hiding this comment

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

Should be php

Copy link
Contributor Author

Choose a reason for hiding this comment

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

whoops, nice catch!
a07173b

@andrii-balitskyi andrii-balitskyi merged commit 8209710 into main Sep 17, 2024
19 checks passed
@andrii-balitskyi andrii-balitskyi deleted the fix-php-code-sample-response branch September 17, 2024 12:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

fix(Code Sample/PHP): update response type to be php
3 participants