0

My project is a hub of tags that called in different name in different languages.

I call views of this components.

Currently users are using angular 1.4 to make views.

I want to give flexibility to user that can make angular 1.4, angular 2.0 components and reactjs components.

I do not want to upgrade users 1.4 directive to angularjs 2.0 components.

So is there any way i can use angular 1.4,2.0 and react js in one project without any problem

2 Answers 2

1

Very short answer: no, you can't run two versions of angular within the same website. The problem is only one version can control the DOM, and there are issues with the global var 'angular' as well (when using two different versions of angular 1.x).

Currently, using iframes are your best option (I know, iew...). In the future, new web components like shadow dom might solve this issue, but browser support is still quite low.

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

2 Comments

That's not true, you can run both versions of angular together: angularjs.blogspot.co.uk/2015/08/…
correct, angular 1 and 2 can be run together, but not two versions of angular 1.x (as I stated in my answer). I realize the OP asked for angular 1 and 2, but it is important information nonetheless
0

I warmly suggest you not to mix the different technologies (1.4 - 2.0)

Better pick just one and follow it.

If you would like to develop new components with 2.0 but you don't want to migrate all, I suggest you to port your code to 1.5 (less effort) and then use the components.

I hope it helps.

Comments

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.