AngularJS is an open-source JavaScript framework. Its goal is to augment browser-based applications with Model–View–Whatever(MV*) capability and reduce the amount of JavaScript needed to make web applications functional. These types of apps are also frequently known as Single-Page Applications.

learn more… | top users | synonyms (2)

0
votes
0answers
4 views

Rename angularjs javascript “angular” function in AngularJS?

Is it possible to rename the AngularJS javascript "angular" call such that instead of doing: angular.module(..... I can use some kind of alias like "ang" instead of "angular" in any occurence where ...
0
votes
1answer
5 views

Angular ng-class with a filter on class value

I have a table tr with an ng-repeat where I colored the background of the row based on time. The colorClassFilter returns a class value based on the time passed in: <tr ng-repeat="object in ...
0
votes
0answers
10 views

Angular $resource - reset with data that has already been fetched

Say I have two resources setup: var Item = $resource('/items'); var Thing = $resource('/items/:id/things', ...); and when i call Item.query() it returns something like this: [ { "id": 123, ...
-2
votes
4answers
16 views

Ng-Repeat - Angular JS

Here is my ng-repeat <div ng-if="feed.link" articlesource source='{{article.link}}' class="post" ng- repeat="article in data.value.items | limitTo:5"> <img ...
0
votes
0answers
5 views

Rails Nested Resource Not Displaying Correct Index

So I have two models in Rails. However, when I visit the path /lectures/:id/users.json I do not get the users associated withe the particular lecture. I get ALL the users. I'm not sure what I'm doing ...
0
votes
0answers
6 views

angularjs IE9 scope variable becomes undefined

I'm encountering a weird issue on IE9. What I'm trying to do is opening a popup window from my page and attaching the scope of the page to the window object like: angularApp.controller('ParentCtrl', ...
0
votes
1answer
5 views

$window.print() executing before lines above it

My problem with the code below is that $window.print() is executing before $scope.loading_status=false which doesn't allow me the hide certain DOM elements before printing the page out. How can i ...
0
votes
1answer
10 views

Angularjs route resolve not populating model before loading controller

I am trying to populate my model from backend(with label and messages) before my contoller get loads. My method is working fine it connects with backend and gets the data but when I am viewing that ...
0
votes
0answers
6 views

ui-router preload app (entire or partial)

The application I'm developing uses "angular.js" + "ui-router" + "bootstrap". Many states and nested views. There are also some images related to templates and, finally, animated transitions placed ...
0
votes
2answers
24 views

Generate tag id from angularjs

I need to create a html structure as follows: <ul> <li id="r1_1">Root node 1 <ul> <li id="child_node_1">Child node 1</li> <li ...
0
votes
0answers
4 views

ng-grid with manually handle page index changed

I have an example of ng-grid server side pagination from here : http://ddeloy.com/angular-ng-grid-example/server-side-page/index.html However as the original purpose of pagination.. i do NOT want to ...
0
votes
0answers
2 views

DotJem AngularJS routing: Error: Could not locate 'pagename' under '$root'

Whenever I start the site it works fine, but all the links are broken. They work, I can click on them and it directs me to the right URL but no content relative to that specific page shows up. But if ...
0
votes
2answers
15 views

AngularJS [$injector:unpr] Unknown provider

I am trying to inject a service into controller, and i am getting following error: Error: [$injector:unpr] Unknown provider: employeeServiceProvider <- employeeService ...
1
vote
2answers
20 views

Bootstrap table with nested ng-repeat striped-rows

I have a table for which should display striped rows, but since I have nested ng-repeats, my output has groups of rows colored the same instead of striped. Any way to get the output I'm looking for? ...
0
votes
3answers
22 views

Sending data from angular to c# api controller binds to wrong action

Question: Why does my action Add gets hit instead of my delete action? Error message: "ExceptionMessage": "Multiple actions were found that match the request: Add on type ...
0
votes
0answers
7 views

angular factory works with angular-translate controller, but not with angular-dropdowns controller

I have an Angular factory, named changeLanguage, that translates all the elements on my HTML page via angular-translate. That part works. I also have a dropdown array tucked away in the controller for ...
0
votes
1answer
17 views

AngularJS modal window scope

I have problem with scopes of controllers. I'm using controller as directive and I have code similar to this example: <div ng-controller="ItemsController as itemCtrl"> <table> .. some ...
0
votes
0answers
12 views

angular-ui-router isn't fulfilling state resolve promises when page refreshes or deep linked

Using AngularJS 1.2.16, ui-router, and Restangular (for API services), I have an abstract state with a child state that uses multiple views. The child view accepts a URL parameter (via $stateParams) ...
0
votes
0answers
8 views

400 bad request error in rest post call

I am currently working on sending rest webservice call (post, get) from angularjs. I am sending an post request from angular controller.js file and it works absolutely fine in my local workspace ...
0
votes
1answer
50 views

How to properly set the server login code?

I'm trying to set up a login page using passport-local this way, but it wouldn't work: node server side: // mongoose var User = mongoose.model('User', userSchema); User.find({}).exec(function(err, ...
1
vote
1answer
27 views

how to delete row using popover in angular.js?

I am using angular ja in my demo .I am creating a list of student name .When I press add button I add the student name , I give two button (edit , delete) .user can change the name and delete the ...
-1
votes
1answer
18 views

Cursor goes to end of input when changing data

Looks like this is happening in only Chrome. It works in firefox and safari. For some reason when I type into the input field to edit the value the cursor goes right to the end of the value. I've seen ...
0
votes
0answers
18 views

Variable passed to directive not resolving

I have an element that is passing a scope variable to a directive but instead of getting the value that I am expecting inside of the directive, I am getting a string of the variable name. ...
1
vote
0answers
18 views

AngularJS Cannot read property 'length' of undefined in aside

I'm using ng-strap's modal, alert, and aside. They are all working fine by themselves, but when I try to put an alert or modal inside an aside, it give me the error: Uncaught TypeError: Cannot read ...
0
votes
0answers
9 views

jqLite - .triggerHanlder() having a strange behavior

I have a piece of code using triggerHandler that is calling the correct event, but the event isn't working. Here is the code and a jsFiddle : HTML: <body ng-app="app"> <button ...
0
votes
0answers
8 views

MacGyver Angular mac-autocomplete directive not auto-completing

I am including the .css and .js files for macgyver in my HTML. I am also including 'Mac' as a dependency in my angular app. I put this code in my HTML: <mac-autocomplete ng-model="selected" ...
-1
votes
2answers
26 views

How do I compare with a string in ng-class?

This line doesn't seem to work for me. Sort By: <a href="" ng-click="setOrder('title')" ng-class="{active: orderProp == 'title'}">Alphabetical</a> Do I have to escape 'title' in ...
0
votes
0answers
21 views

angularjs validation update error status of another input field

Aloha. I have two fields for time input, start + end. I've created custom validations to check if field is blank, valid time, and start is before end time. Works except for the following: edit both ...
0
votes
1answer
6 views

adding a custom icon to a tinyMCE button

I'm trying to add a Font-Awsome icon to a button I added to tinyMCE thus: ed.addButton('youtube', { title: 'Add Video' , icon: 'icon-youtube', onclick: function () { //do stuff ...
1
vote
0answers
8 views

Angular UI Router: nested states for home to differentiate logged in and logged out

I'm starting a new project using boilerplate MEAN provided by MEAN.JS (not .IO). I'm new to ui-router and I'm having trouble figuring out how to accomplish this scenario: if user is logged in, go ...
0
votes
1answer
8 views

hg-click won't work with div in ionic

Well, as stated by the title, I'm having this problem, say, i have a form with multiple steps that i created using the ng-show property along with a function to set a $scope variable to an identifier ...
0
votes
1answer
17 views

Angular, how to select an item from a list which is retrieved using ajax

So this is somewhat weird to me. Angular supports selects by reference however there is no support of selecting by value. Here's my case and why I'm kind of puzzled: I've got a form for editing a ...
1
vote
1answer
37 views

JavaScript OOP - Getter that returns member on base

I am having some problems implementing getters and setters on my model objects for use in Angular. I am getting this error: TypeError: Cannot read property 'firstName' of undefined at User.firstName ...
0
votes
0answers
8 views

Angularjs ngCsp example of forbidddened practices

In angularJS doc for ngCsp (https://docs.angularjs.org/api/ng/directive/ngCsp), there are two lines desc what not to do... But I have no idea what they exactly are! don't use Function constructor to ...
1
vote
0answers
12 views

Audio5js player not working for Chrome on Mac

Audio5js is a html5 with flash compaitibility for older browsers. Here is the link for the source code and the developer website Github: https://github.com/zohararad/audio5js I have used angular ...
0
votes
1answer
23 views

Angularjs ui bootstrap modal doesn't work without resolve option

I have created a reusable component but I keep getting issue if I don't pass resolve, what is wrong here.. thanks $scope.open = function () { var modalInstance = $modal.open({ ...
0
votes
1answer
9 views

accessing $scope from unit test file when using the vm “ControllerAs” syntax from AngularJS HotTowel

See here for example: http://www.johnpapa.net/angularjss-controller-as-and-the-vm-variable/ As the title suggests, I'm following along on this tutorial ...
0
votes
1answer
23 views

calling an angularjs attribute directive from inside an ng-repeat

I have a collection of table column objects that I am iterating over using ng-repeat. I am building the table dynamically based on the columns the user wants to see. Each TH tag calls a "sortable" ...
0
votes
2answers
17 views

How to inject html into an Angular UI bootstrap popover

How can I inject html into a Angular UI boostrap popover? I'd prefer to simply show and hide a div with all the popover html content. Right now I have: <a popover-placement="bottom" ...
0
votes
1answer
12 views

Change in one-way bound directive attribute during test not updating directive scope

I'm currently attempting to test an angular directive using jasmine. Here is a simplified example of what the directive under test looks like: angular.module('app', []).directive('testDirective', [ ...
0
votes
0answers
23 views

AngularJS ng-model value not initially displayed in input field

I am trying to use ng-repeat to iterate through an array of keys and display the scenario value associated with each key. The view code worked when the key value was hardcoded. Now that ng-repeat ...
-2
votes
0answers
32 views

Alternative to KnockoutJS [on hold]

I am looking for a small library like Knockout but that is used like Angular. I prefer databinding, templating and controllers of Angular compared to Knockout and its MVVM approach. Basically, I ...
1
vote
1answer
20 views

Angularjs: is this way of writing wrong?

<input ng-model="search" type="text"> <table ng-if="search.length > 2 || search.length == 0" ng-init="somerows = getdata()"> <tr ng-repeat="row in somerows | ...
0
votes
1answer
16 views

angularJS - Data is not displayed in unordered list

I'm learning angularJS and have some simple example with 2 Views and Controller. My main page defines controller and route and displays views. View page should display text field, unordered list, adds ...
0
votes
0answers
10 views

Load rails model data to front end on background job event

my web application is using AngularJS and Ruby on Rails. Currently, there are some background tasks that the end user triggers that get processed by delayed_job. The background task produces ...
1
vote
0answers
22 views

typeahead directive doesn't bubble up the event to the parent controller upon selection

I am very new to AngularJS Directives and trying to figure out how can i customize the angularjs directive typeahead into a directive that can be customized and extended with more functionality. Use ...
1
vote
0answers
12 views

Save paperclip attachment to DB via AngularJS in Rails 4

I'm trying to save a photo into DB via AngularJS in Rails4. I used paperclip gem for the attachment setup class User < ActiveRecord::Base devise :database_authenticatable, :registerable, ...
0
votes
0answers
11 views

Jasmine + AngularJS: Shared examples not loading

Jasmine keeps complaining that I have no tests in one of my shared specs, even though there are specs: Spec 'mysite ProductsIndexCtrl behaves like an index controller' has no expectations. my spec ...
0
votes
2answers
18 views

Angular.js, how to check authentication service in controllers

In angular.js, on all controllers that require authentication I am doing the following: function controller($state, $rootScope, $scope, oAuthService) { //oAuthService is a custom service ...
0
votes
0answers
9 views

How to access controllerAs namespace in unit test with compiled element?

In this fiddle http://jsfiddle.net/FlavorScape/fp1kktt9/ i try to set properties on the controller, not the $scope directly. In the template (in production) we just do myAliasCtrl.somePropertyList and ...