3

I have a core angular library written in house. p.e. There is a component A which uses internally an date picker component with the selector my-date-picker. Many other components in the library use that date picker,too. The library is delivered to different customers. Now one of the customers doesnt want the datepicker. He builds an own datepicker component. Is there a simple way to replace the old datepicker with the new one? Something like overriding the selector...

EDIT: The additional/replacement components are not necessary provided by us. It is possible that our customer will develop it on his own.

Thank you an regards Stephan

1 Answer 1

1

You could potentially create a boolean variable called isCustomerX, and check it.

If the component is ran by customer X, you can simply disable the control overall, and let them use whatever they want.

Or you could create a custom environment. There is an excellent explanation here

That way you'd be able to distribute the environment relevant only to that particular customer.

Sign up to request clarification or add additional context in comments.

1 Comment

Thank you for your answer. The problem is that the customer himself will develop own components. Its not part of our delivery.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.