@palmergs wrote:
I've been reading through this topic ( http://discuss.emberjs.com/t/sharing-models-via-ember-cli-addons/6311 ) and I'd like some validation that what I'm thinking of doing makes sense.
I have a Rails app in it's own repo and a customer facing Ember app in it's own repo (e.g. ui-frontside).
I'd like to build a management Ember app (ui-management) that will share a large portion of the models, mixins, services and components. Basically, it will reuse almost everything from the way that error messages are displayed to how the ember-simple-auth is configured. The biggest difference will be in routes and the management interface will have components for editing models that would be read-only to the customer app.
Is the correct thing to do–to avoid copy-and-pasting code–to create a fourth repo as an ember-cli addon and copy everything from the customer app that could conceivably be shared? Then, refactor the custom app to use that base app?
Posts: 6
Participants: 4