Reputation: 1139
I have a Meteor application with an Angular frontend. I want to check for any unsaved data in forms before navigation. Found this Angular directive angular-unsavedChanges but it requires to be added with Bower. How can i use this in Meteor? (Went through previous questions, and seperately downloaded and placed the directive in lib, still not woking) New bee to both Javascript and Angular, appreciate if you could be a little descriptive.
Upvotes: 0
Views: 64
Reputation: 426
According to the basic usage instructions, you do not necessarily need to install this using Bower. You just need a hard copy of the files available in your project that can be referenced.
You should be able to set up this up with the following steps:
public
in the root directory of the project.public
directory and create a new directory named bower_components
.git clone [email protected]:facultymatt/angular-unsavedChanges.git
.angular-unsavedChanges
, and save the files to this directory.<head></head>
tags that will be rendered on the page you want to use the code on (in your component, index file, head file, etc), add <script src="/bower_components/angular-unsavedChanges/dist/unsavedChanges.js"></script>
.Upvotes: 1