Skip to content
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

Turn Transform methods not handling state into a module #5

Open
pjotrp opened this issue Jul 6, 2013 · 1 comment
Open

Turn Transform methods not handling state into a module #5

pjotrp opened this issue Jul 6, 2013 · 1 comment

Comments

@pjotrp
Copy link

pjotrp commented Jul 6, 2013

The transform methods do not need to keep track of state. I would make this a module, so as to force a more functional style. All you are using is the type, which can be passed in with every method, or fetched from the surrounding class(name). If you need state, add a separate state class and include the module.

Split out methods that can be 'pure' from methods that really need 'state'.

@pjotrp
Copy link
Author

pjotrp commented Jul 6, 2013

OK, you are also tracking properties. Let me rephrase what I wrote: put all methods that are not handling state into a separate module.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant