-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Possible to allow "transient" values? #85
Comments
Hi Mike, This is not currently a feature in factory.ts, but I don't think it'd be super hard to implement. I don't have the time right now, but I will add it to the list for the next time I sit down to bang out some updates. That said, if I receive a PR I will make reviewing it a top priority. :) Alternatively, depending on your use case, you could expose functions that call |
FactoryBot for ruby has the notion of transient attributes that are used by the factory but not added to the model. How would one achieve that with factory.ts?
I have some factories that have a complex-ish string that is based on a simple ID but that ID is not part of the model. I don't want factory clients to have to know how to construct the string. I'd like them to be able to call the factory, passing in the id and any other attributes they want to use, and have the factory be able to construct the string out of the ID.
Is this possible in factory.js?
The text was updated successfully, but these errors were encountered: