0

How can I use the content of a file in JavaScript as does VueJS with .vue files? As far as I am aware Vue doesn't use any Ajax to achieve this. So if I have a .whatever file how can I import / parse this external content?

4
  • just add that external file reference in .html and use access the functions, objects from your .js file Commented Jun 24, 2020 at 17:28
  • stackoverflow.com/questions/48211891/… Commented Jun 24, 2020 at 17:30
  • Could you code a tiny example? Commented Jun 24, 2020 at 17:33
  • Does this work without a server running? Commented Jun 24, 2020 at 19:18

0

Your Answer

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