You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jul 29, 2026. It is now read-only.
Repository navigation
This repository was archived by the owner on Jul 29, 2026. It is now read-only.
I understand that GitHub issues are not for tech support, but for questions specific to this generator, bug reports, and feature requests.
Item
Version
generator-angular-fullstack
4.1.2
Node
4.5.0
npm
3.10.2
Operating System
Windows 10
etc
etc
Item
Answer
Transpiler
Babel / TypeScript
Markup
HTML / Pug
CSS
CSS / LESS / SCSS / Stylus
Router
ngRoute / ui-router
Client Tests
Jasmine / Mocha
DB
MongoDB / SQL
Auth
Y / N
etc
etc
Please be aware: the following event on thing.events.js does not work: Thing.schema.post(e, emitEvent(event));, since Thing.schema.post event is not triggered with mongoose@4.8.0
+1 I had same problem with Thing.schema.post(e, emitEvent(event)) not emitting events in mongoose 4.8.1, downgraded to mongoose 4.7.7 and everything ok. Also, I would suggest adding ghostMode: false to the browsersync config in server/config/express.js as the default.
I did not. I wasn’t sure it was mongoose at fault or not. I’m kind of new to fullstack and not confident I could pull together a stand-alone example of the event emitting not working.
mutating the underlying schema after the Thing model has been created by mongoose.model() isn't a supported behavior. Make sure you define all your hooks before calling mongoose.model()
@ernisto has a solution in #2491 that does just that.
Activity
[-]Mongoose@4.8.0 causes issues with [/-][+]Mongoose@4.8.0 causes issues[/+]Awk34 commentedon Jan 30, 2017
Are you sure there is a Mongoose issue here? I don't see anything breaking in the 4.8.0 changelog
gordonaspin commentedon Feb 3, 2017
+1 I had same problem with Thing.schema.post(e, emitEvent(event)) not emitting events in mongoose 4.8.1, downgraded to mongoose 4.7.7 and everything ok. Also, I would suggest adding ghostMode: false to the browsersync config in server/config/express.js as the default.
Awk34 commentedon Feb 3, 2017
Have either of you submitted a bug report to Mongoose yet?
gordonaspin commentedon Feb 3, 2017
Awk34 commentedon Feb 3, 2017
From reading this bug report, it seems like there might have been an unintended breaking API change in mongoose 4.8.0
EliKrumholz commentedon Feb 5, 2017
I think I was able to replicate the bug, I opened an issue with mongoose: Automattic/mongoose#4955
EliKrumholz commentedon Feb 7, 2017
From the Mongoose folks:
@ernisto has a solution in #2491 that does just that.
alkiko commentedon Feb 7, 2017
Downgrading to 4.7.9 solved it for me too, but @ernisto's suggestion looks more correct.
Awk34 commentedon Feb 7, 2017
@ernisto do you thing you might submit a Pull Request for your fix?
Climax777 commentedon Feb 8, 2017
+1 for the @ernisto fix
ernistkg commentedon Feb 9, 2017
@Awk34 Yes it would be Great! But I need some time to create Pull Request according to rules and best practices.
fix(events): mongoose event registration
fix(events): mongoose event registration
fix(events): mongoose event registration