Comments (4)
@connerbw Fair point. I've created an issue over in the doc repo to do this.
from opulence.
It would be nice to extend the "Basic Usage" documentation though.
I had similar issues starting out. I figured it out but for a first time developer it would be beneficial to show a Post::class
code with a corresponding DB table INSERT example to start them off in the right direction.
Then you could add your reasoning why you chose this way (schema is limiting, extending is hard, etc), flesh out the docs a bit more?
from opulence.
The Post
class is just a plain-old PHP class. You do not have to implement or extend any interface/base class. The issue with trying to have the ORM auto-write queries for you is that it assumes a certain DB schema, which I find to be very limiting to the developer. If your tables/entities are very simple and you'd like that auto-wiring support, I'd recommend an active record ORM.
from opulence.
@evolic I'm going to mark this closed because I've created an issue in the documentation repo to better explain the design choices behind the data mapper.
from opulence.
Related Issues (20)
- Interface is used, but argument isn't type declared HOT 3
- Update components, tag version HOT 3
- unambiguous migration ordering during running migrations:down HOT 7
- Fixing phan issues HOT 4
- PSR-7 support HOT 4
- T_CLASS case in FileMigrationFinder.php appears to be broken HOT 1
- Deprecated annotations HOT 4
- Add support for using expressions in query builders HOT 1
- Package jeremeamia/superclosure is abandoned, you should avoid using it. Use opis/closure instead. HOT 1
- Remove deprecated method(s) for forward compatibiltiy HOT 3
- Improve `make:entity` and `make:datamapper` by inferring the database schema (tables/columns/relationships) automatically. HOT 4
- Migration HOT 3
- Not proper use of prepare statements in the sql repository example on documtentation page HOT 4
- Database relation support HOT 5
- Fix bug that prevent non-HTTP_ and CONTENT_ headers from being sent in response
- Running `php apex app:runlocally` in Ubuntu does not work
- phpDocumentor problem HOT 12
- Spaces in Path cause passthru to fail for runlocally (possibly others) HOT 1
- Nice FW but too many dependency HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from opulence.