Seif El-Din Sweilam
Seif El-Din Sweilam

Reputation: 274

How to convert an Angular project to a non-Angular project?

I have a current Angular project which I want to be a simple (HTML, CSS, JS) website without the whole script that Angular adds to the project. I want my routes to be converted into several HTML files where each file contains the actual content, not some script tags that refer to some javascript files. I mean I want it to be as if I designed the website without Angular. I know Angular is effective but I need this for some reason. How can I acheive this?

Upvotes: 0

Views: 779

Answers (1)

GBra 4.669
GBra 4.669

Reputation: 1679

Fancy way: turn your Angular Components into Web Components by using Angular Elements. Angular Elements is a feature of Angular framework (not a third party package) that allows you to "convert" your Angular components into native Web Components. Web Components are custom HTML elements (JS API, not Angular related). So you can use them in apps built with other frameworks (such as Vue.js) or even in vanilla JS apps. Web components are now supported natively by any active browser. This is a pretty good guide (in the guide example, we serve an Angular component in a vanilla JS app).

Amanuensis way: manually copy and paste what you need.

Upvotes: 1

Related Questions