-2

I have created a HTML and corresponding .js files seperately.

Now, what I require is to load them in my existing angular project, so that for example, I can open the new HTML and .js as:

localhost:portnumber/HTML file name - or something similar

I have learned over internet to mention the js file in angular.json, but what about the html file ? How do I load it? Can someone please help?

4
  • Are you asking how to serve an HTML document with some JS that have nothing Angular related in them at all from the Angular dev server? Commented Feb 4, 2020 at 11:19
  • @Quentin yes absolutely Commented Feb 4, 2020 at 11:23
  • Sounds like something better handled by deploying everything to a non-development server. Commented Feb 4, 2020 at 11:24
  • @Quentin Not sure what you last comment means, however, I have come accross this link: stackoverflow.com/questions/53416871/… And have done these changes: "src/all.html", { "glob": "all.html", "input": "src/", "output": "/home/" } in angular.json. But not sure how to fire up the final url. Commented Feb 4, 2020 at 11:28

1 Answer 1

0

I have solved it by adding glob in angular.json - just in case anyone needs for future reference.

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

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.