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
I'm having a similar issue, but it's with factory.FactoryGirl is not a constructor:
const FactoryBot = require('factory-bot')
const factory = FactoryBot.factory
const pgFactory = new factory.FactoryGirl() // Reports factory.FactoryGirl is not a constructor
Identical code worked previously with factory-girl, just trying to replace factory-girl w/ factory-bot, but am stuck with the above.
I tried to use factory-bot like this:
But got an error:
TypeError: factory.define is not a function
Please help me :( How do I import and use this as ES6 modules?
The text was updated successfully, but these errors were encountered: