Open Smoren opened 4 months ago
It doesn't seem to be widely used yet.
Thank you @alexkart for your comment. I agree that the repository is not widely popular at the moment, but I hope that its usefulness will be a more important factor in deciding whether to add it to the list.
Looks to me like this is a bit more powerful version of https://github.com/jolicode/automapper In general, I am a big fan of the idea of having a schema to map from incoming data (e.g. API call) to nested (DTO) objects.
I was working on sth even more powerful that auto-defines itself based on the data structure of the example array, creating the schema on its own (with only few customizations necessary), generating the necessary PHP classes and having it all up and ready < 1min: https://github.com/dereuromark/cakephp-dto Still framework specific, but it could be made more generic, if people are interested in the idea and helping out.
That said, I think having at least one useful datamapper on its own listed here sounds like a good idea. Do we have already some listed?
哈喽
Schematic data mapper ·
![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)
Schemator is a tool for converting nested data structures (any composition of associative arrays, non-associative arrays and objects) according to the given conversion schema.
Examples
Simple usage
Using base filters
Using custom filters