Questions tagged [angularjs-1.5]

Represents questions specific to AngularJS versions 1.5. The primary theme for this release was to improve the upgrade path to Angular 2. In this release, features added that will enable developers to write Angular 1 applications that are closer to the way that applications are structured in Angular 2.

Represents questions specific to AngularJS 1.5.

See https://blog.angularjs.org/2016/02/angular-150-ennoblement-facilitation.html.

For questions about AngularJS 1.6 use , and for the second version.

127 questions
78
votes
7 answers

AngularJS 1.5+ Components do not support Watchers, what is the work around?

I've been upgrading my custom directives to the new component architecture. I've read that components do not support watchers. Is this correct? If so how do you detect changes on an object? For a basic example I have custom component myBox which has…
75
votes
9 answers

Why are my component bindings undefined in its controller?

I'm writing a simple angular component. I'm passing a parameter as a binding and display its value on the screen. All works fine: I can see the parameter being displayed on the screen. Component: var app = angular.module("test",…
fikkatra
  • 5,605
  • 4
  • 40
  • 66
15
votes
2 answers

Angular 1.5 components with ui-router resolve : Unknown provider

I'm facing an issue with converting controllers to components preparing my application for Angular 2, but the problem the migration is not going well, I have the ui-router to route between states and using resolve in a few controllers, the version…
15
votes
2 answers

Installing angular 1.5 typings

Update 3/26/2017 I now use npm install @types/angular with TypeScript 2.0 and the experience so far has been much smoother than typings was. Original I have an Angular 1.5 project using ES6 modules and Webpack, which is very similar to this starter…
Aaron Beall
  • 49,769
  • 26
  • 85
  • 103
11
votes
1 answer

Unable to require directive in AngularJS 1.5 component

I've created a directive which works perfectly fine. Now after bumping angular to 1.5.0, I figured this directive is a typical example of what could be written using the new .component() notation. For some reason, the require property no longer…
Remco Haszing
  • 7,178
  • 4
  • 40
  • 83
7
votes
1 answer

How to listen to scope events in Angular 1.5 component?

I'm in the middle of migrating code from Angular 1.3 to Angular 1.5 components and ES6 controllers. I tried to find something here on SO, but not helpful enough. Suggestions required on how to watch events on scope other than the way mentioned…
5
votes
1 answer

Two way data bindings does not trigger $onChanges in Components

Two way data bindings not updating between components I am setting up inter component communication using two way data binding. I have one parent controller which fetches data from AJAX call and sends that data to 2 components. I have tried to…
5
votes
1 answer

Load angular 1.5 component template via promise

In Angular 1.5, I want to load the template via custom promise. The example code that I would like to run is var module = angular.module("myApp", []); module.component("component", { template: ["$q", function ($q) { var defer = $q.defer(); …
Jigar
  • 544
  • 1
  • 8
  • 28
5
votes
4 answers

AngularJS 1.5.x $onChanges Not Working with One-Way Binding Changes

I don't understand why $onChanges isn't kicked off when I change a bound primitive in an input. Can someone see what I've done wrong, and explain this in an uncomplicated way? I made a plunkr of a quick test application after I couldn't get it to…
mtpultz
  • 17,267
  • 22
  • 122
  • 201
4
votes
1 answer

Downloading a PDF using JavaScript that is Cross Browser Compatible

I can download a PDF using AngularJS in Chrome, but this doesn't appear to work in the latest FireFox, Internet Explorer 11 or Edge (assuming it doesn't work for IE10 either), and I know a shim is needed for IE9. Don't know if this the best shim…
mtpultz
  • 17,267
  • 22
  • 122
  • 201
4
votes
2 answers

Date range pickers in angularjs

Can anyone suggest some good date range picker with angularjs which can work without range also? So, flexible to use in different use cases and customizable?
4
votes
1 answer

Third party async callback in AngularJS 1.5 Component

Before AngularJS 1.5, in directives or views, the way to make sure a change would be picked up by angular (using $digest cycle) when the change was issued from a third party async callback was to run your code in a $scope.$apply() call. With…
4
votes
2 answers

Angular JS 1.5 - I want to communicate between angular js components

I am trying to expose deletePhoto and editPhoto methods of businessPhotos components into verticalGrid component. But some how it is not accessible. Any help would be appreciated, thanks photo.js angular.module('business') …
4
votes
1 answer

How to use angular 1.5 components with ui-router states

Right now, angular ui-router project didn't have anything explicit about angular 1.5 components. My project requirement is to use nested states and I want to use angular 1.5 components to easily migrate to angular 2. I'm looking for a best…
4
votes
1 answer

How do you unit test a binding with a different name in an Angular 1.5 component?

I have the following component: angular.module('foo') .component('searchInput', { bindings: { text: "
Daniel Smith
  • 553
  • 1
  • 6
  • 12
1
2 3
8 9