hapipal / tandy Goto Github PK
View Code? Open in Web Editor NEWAuto-generated, RESTful, CRUDdy route handlers for Objection models in hapi
License: MIT License
Auto-generated, RESTful, CRUDdy route handlers for Objection models in hapi
License: MIT License
A call to /users/comments
should get you all users
with their comments
.
Objection's insertGraph
should make this pretty straightforward, though identifying relations could be tricky?
This npm package needs a TypeScript types declaration file so that developers who enjoy writing with TS can use it with this package and have a better development experience. Would you like me to write one?
Currently sort is dialect-specific (as it's being passed into the query as a raw string, therefore subject to dialects quoting rules) and being limited to one key
One idea that would work is to convert sort to accepting an array [[key, 'ASC/DESC']] and then iterate over that like this
const schema = Joi.array().items(Joi.array().ordered(Joi.string().valid('id', 'etc').required(), Joi.string().valid('asc', 'desc').default('asc')).required())
const { error, validated } = schema.validate(sortParam)
if (error) throw error
for (const sort of validated) {
query = query.orderBy(sort[0], sort[1])
}
For backwards compatibility the new behaviour could be a flag or switched with sortParam.startsWith('[') (where the old schema is converted to the new one internally)
Bedwetter had a form of this, and now that I've decided not to port that functionality I've found a use-case for it.
Core hapi modules now live under the @Hapi namespace - update deps to reflect this.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.