Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jondot/hyperportal
A pleasant CLI for rapid development with Sequelize or Mongoose.
https://github.com/jondot/hyperportal
activerecord mongodb mongoose nodejs postresql sequelize
Last synced: about 1 month ago
JSON representation
A pleasant CLI for rapid development with Sequelize or Mongoose.
- Host: GitHub
- URL: https://github.com/jondot/hyperportal
- Owner: jondot
- Created: 2017-08-02T15:03:37.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2017-11-07T07:21:08.000Z (about 7 years ago)
- Last Synced: 2024-04-26T22:42:29.368Z (8 months ago)
- Topics: activerecord, mongodb, mongoose, nodejs, postresql, sequelize
- Language: JavaScript
- Homepage:
- Size: 352 KB
- Stars: 5
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Hyperportal
A pleasant CLI for rapid development with Sequelize or Mongoose.
![](media/mngs.gif)
## Quickstart
```
$ yarn add --dev hyperportal
```And add the following script to your `package.json` file. Let's call it 'console'.
```json
"scripts":{
"console":"HYP_MODELS=config/hyperportal.js hyp"
}
```And here's how `config/hyperportal.js` looks like, when you're using Mongoose:
```javascript
// connects mongoose. grab your own setup
require('./mongoose-setup.js')// exports a map, e.g. { User: , Post: }
const models = require(path.join(__dirname, '../models'))
module.exports = models
```And now, run:
```
$ yarn console
```# Usage
Use your models (they are already available in the console) to print `p`, log `l`, and display on a table `t`.
Additionally you can simulate a `toJSON` with `js` to see what part of your model is exposed.```
>> t(User.find())
>> p(User.find())
>> l(User.find())
>> js(User.find())
```# Contributing
Fork, implement, add tests, pull request, get my everlasting thanks and a respectable place here :).
### Thanks:
To all [Contributors](https://github.com/jondot/hyperportal/graphs/contributors) - you make this happen, thanks!
# Copyright
Copyright (c) 2017 [Dotan Nahum](http://gplus.to/dotan) [@jondot](http://twitter.com/jondot). See [LICENSE](LICENSE) for further details.