These are chat archives for Automattic/mongoose

28th
Apr 2018
RajaSekhar K
@krajasekhar
Apr 28 2018 12:52
Someone help me with this.. Getting error 'mongoose.model is not a function' with a simple mongoose function
https://codesandbox.io/s/9zpv1v0oyo
Kev
@lineus
Apr 28 2018 13:32
@krajasekhar try mongoose.model instead of mongoose.Model
RajaSekhar K
@krajasekhar
Apr 28 2018 13:33
@lineus hey pls check now.. that I experimented in between.Actually using mongoose.model only.. please access the link now https://codesandbox.io/s/9zpv1v0oyo
Kev
@lineus
Apr 28 2018 13:46
it looks like codesandbox.io is failing to transpile mongoose correctly. the syntax seems fine.
Kev
@lineus
Apr 28 2018 13:55
@krajasekhar There doesn't appear to be a way to view/change the transpiler options, my guess is that mongoose doesn't work with the default codesandbox transpiler settings. You might open an issue with codesandbox.io and ask for some insight.