Giter VIP home page Giter VIP logo

express-mongoose-generator's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

express-mongoose-generator's Issues

dos/unix line endings

Awesome tool, but currently the tool generates DOS line endings on Mac OS X, not unix line endings. Not sure if it works correctly on Linux.

Ability to specify the type of array

Currently Array attribute do not specify the type of objects in array. We should be able to configure it.

For instance,

emailAddresses: [String],
Messages: [{type: Schema.Types.ObjectId, ref:'Message'}]

mongoose.connect() ???

Hi, thank you very much for this nice stuff.
Can u plz tell me where can i put this (beginner :-) ) ? Can you integrate this in the generator?

feature based structure

great job !!! I love it and plan to recommend it during my next meet-up in Bali.
could we have the option to generate only one folder named after the model then get all generated files in this folder?

Use the ObjectID type field

Hi @DamienP33 , thank you very much for this generator, it's been very helpfull.

I miss the ObjectID type, and hacked a bit into your code to provide this functions

I got it working for some time now, but today I share with you

Hope you like and it can be usefull or at least consider using this

I have no tests written thou, sorry

Here's the PR
#1

ALLOWER_FIELDS_TYPES or ALLOWED_FIELDS_TYPES?

I suppose you have a typing error. You used "ALLOWER_FIELDS_TYPES" to replace "allowedFieldsTypes" in bin/mongoose-gen.

I think you should have used "ALLOWED_FIELDS_TYPES" instead of "ALLOWER_FIELDS_TYPES".

Let me know if I'm wrong.

Good job. Thank you very much,Hug from Colombia

Output mixes tabs and spaces.

It's something small really. I'm raising as an issue for myself to come back PR as soon as I have a moment.

๐Ÿ‘พ

Nested Document

possibility to add nested sub document within the model?
thanks in advance

Template overriding

thx for the excellent generator
is there any way to override the templates?

The content of model file was generated wrong

mongoose-gen

Model Name : car
Available types : string, number, date, boolean, array, objectId
Field Name (press <return> to stop adding fields) : door
Field Type [string] : number
Field Name (press <return> to stop adding fields) : color
Field Type [string] :
Field Name (press <return> to stop adding fields) : owner
Field Type [string] : objectid
Invalid Argument : Field type is not allowed
Field Type [string] : objectId
Reference (model name referred by the objectId field) : User
Field Name (press <return> to stop adding fields) :
Generate Rest (yes/no) ? [yes] : yes
Files tree generation grouped by Type or by Module (t/m) ? [t] : m
	create: ./car
	create: ./car/carRoutes.js
	create: ./car/carModel.js
	create: ./car/carController.js
ken@Ken:~/working/nodejs/tut2$ cat car/carModel.js
var mongoose = require('mongoose');
var Schema   = mongoose.Schema;

}); carS}owner' ref: 'User'a.Types.ObjectId,

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.