Replies: 1 comment 1 reply
-
I actually have some mixins that are shared between pages and components. Right now that mixins folder is in
Then maybe Lucky just generates the |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I have thought a way and done a lot of hacks to share mixins for different types, like pages, actions and operations. Having one folder that is require pretty high would solve this issue.
I have one very simple mixin module that is just cleaning up periods that is used for pages but also components and operations:
Now I have added this mixins folder, so I only need to have it on one place but before i had to duplicate it and have it on multiple places.
A similar mixin:
hashid that make random id for an integer Is used in pages and actions. I made it ugly with this one to solve this issue by adding at a method in the model to get it and using this on other places.
Last example:
A check of a subscription that will be use in component, pages (to show box or not) and before pipe to redirect or not. I moved this to
src/mixins
- Otherwise I had to duplicate code to have it on 3 places.What do you guys think about this? I might I missed very good thing with the current.
Beta Was this translation helpful? Give feedback.
All reactions