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

Add reusable embeds schemas with defparams #30

Merged
merged 1 commit into from
Oct 5, 2019
Merged

Conversation

nirev
Copy link
Contributor

@nirev nirev commented Sep 26, 2019

Implements reusable embeds using defparams, as asked in #15

Examples:

defparams puppy %{
    breed!:  :string,
    near_location!: {:embeds_one, LocationParams}
  }

  defparams dragon %{
    breed!:  :string,
    near_locations!: {:embeds_many, LocationParams}
  }

Let me know if you needs anything else, @vic :)

Gracias

@vic
Copy link
Owner

vic commented Sep 26, 2019

Looks nice, @nirev! Do you think it's worth it adding some example of embeds in README ?

If not, we could just merge this PR as it's now.
Thanks !

@nirev
Copy link
Contributor Author

nirev commented Sep 27, 2019

I'll add a couple :)

@vic
Copy link
Owner

vic commented Oct 5, 2019

@nirev I'll merge this. but feel free to send another PR with docs.

Thank you :)

@vic vic merged commit 49fcb9a into vic:master Oct 5, 2019
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.

2 participants