0

I made an app in Rails and AngularJS. A startup approached me to port the technology over to their site, but they have very limited technology resources, so the idea is to make it very easy to integrate.

I want it to work a bit like Google Analytics - they include one external javascript file and add a snippet of code with a reference id/code in it. Then the rest is handled on my side.

I haven’t done this before, especially not in AngularJS. I want to use AngularJS in a section of their site without them needing to install it.

Should I just put all the directives and services into a minified file or should I have a smarter setup?

I would appreciate it if anyone could point me in the right direction. I'm also looking for any recommended gems/tools that can help me with this. I’m happy to explain further if needed.

Update

I ended up using Brunch, this article was very helpful.

1 Answer 1

1

You could create a grunt build task that will inline your html templates as strings into your js, and then concatenate and minifying your code.

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

1 Comment

Thats definitely a good idea, I'm looking into it right now, if its a fit and no else comes up with a better solution then I'll mark it correct :)

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.