Questions tagged [zone]

For questions about zone.js. *Not* for questions about time zones (use the timezone tag), DNS zones or other meanings of zone.

What's a Zone?

A Zone is an execution context that persists across async tasks. You can think of it as thread-local storage for JavaScript VMs.

See this video from ng-conf 2014 for a detailed explanation:

More info in documentation oficial.

247 questions
3
votes
2 answers

How to change time zone settings using windows api

I need to change DST and time zone via API in my application. I modified & copied example of "SetTimeZoneInformation" usage by the end of the following link and have run…
Vadim
  • 31
  • 1
  • 4
3
votes
1 answer

Multiple use of a custom component containing a zone

I'm facing a problem when using tapestry 5.2.0 : using multiple times a component containing a zone. At this point, the component is used 3 times on the same page but only one instance is working well. The tml associated to the component looks this…
user771584
3
votes
1 answer

how to set zone in dojo?

if the time in mysql is set to '2011-08-07 08:00:00', the value of dijit.form.TimeTextBox will be showed like this '2011-08-07 16:00:00'. The diffence of time between mysql and web is 8 hours,so i think the default value of zone in dojo is set to…
虫子樱桃
  • 102
  • 6
3
votes
2 answers

How to use zone.js in Angular?

I would like to use zone.js in my Angular project ( not just the runOutsideAngularZone function ). I tried to include it like this: import { zone } from 'zone.js'; Unfortunately I get this error: error TS2306: File…
Iter Ator
  • 8,226
  • 20
  • 73
  • 164
3
votes
1 answer

remote options loading in select using ng2-semantic-ui not working

public optionsLookup(query:string, initial:any): Promise { return new Promise ( (resolve, reject) => /*[{ id: 1, name: 'ololo1'}, { id: 2, name: 'ololo2'}]*/ this.apiService.get('private/countries', query) …
3
votes
1 answer

Access angular NgZone instance from window.object

Is it possible to access angular(2+) ZoneJS instance (NgZone) without injecting it inside constructor like this: ... const zone = window[''] ... For now when I developing my angular library I need to do…
Dariusz Filipiak
  • 2,858
  • 5
  • 28
  • 39
3
votes
0 answers

How come that NgZone solves this issue?

I'm creating an application where the user can identify himself via his Google account. Behind the scenes, I'm using gapi to handle the login. On the other hand, there is an angular service called "user" that has an Observable that is broadcasting…
ssougnez
  • 5,315
  • 11
  • 46
  • 79
3
votes
0 answers

runOutsideAngular with drag an drop, service and component

I am trying to properly implement NgZone runOutsideAngular with drag and drop. In my architecture, users can drag an element in a list and drop it at some other position. While dragging, I am showing a marker where the element would be dropped. The…
Lukas
  • 9,752
  • 15
  • 76
  • 120
3
votes
4 answers

EXCEPTION: Error: Uncaught (in promise): Expected 'styles' to be an array of strings

I'm working on angular2 "2.0.0-rc.1" But zoneJS is giving following error Error: Uncaught (in promise): Expected 'styles' to be an array of strings. at resolvePromise (zone.js:538) at zone.js:515 at ZoneDelegate.invoke (zone.js:323) …
Akhilesh Kumar
  • 9,085
  • 13
  • 57
  • 95
3
votes
5 answers

Angular 2 after update I get this error: Cannot read property 'zone' of undefined

I just updated angular 2 from beta 9 to beta 11 (or beta 10) and now I get this error in console: Uncaught TypeError: Cannot read property 'zone' of undefined in angular2-polyfills.js:142 without changing anything to code. The line in…
Daniel Dudas
  • 2,972
  • 3
  • 27
  • 39
3
votes
1 answer

Failure writing parameter 'value' null value on a parameter field (ajax)

I encounter this issue when I am trying to update a zone of a component in a handled event (onValueChanged of a select box). [ERROR] TapestryModule.RequestExceptionHandler Processing of request failed with uncaught exception: Failure writing…
Gadou
  • 49
  • 1
  • 7
3
votes
2 answers

Rails/Postgres query rows grouped by day with time zone

I'm trying to display a count of impressions per day for the last 30 days in the specific users time zone. The trouble is that depending on the time zone, the counts are not always the same, and I'm having trouble reflecting that in a query. For…
ifightcrime
  • 1,216
  • 15
  • 18
2
votes
0 answers

Angular universal debugging and stack trace

I'm currently struggling to implement angular universal in an existing project. I removed all third party packages to make it compile and running. But when loading the website there is still a runtime error I cannot make any sense of: TypeError:…
Snaketec
  • 471
  • 2
  • 14
2
votes
1 answer

Zone js Unhandled Promise rejection

I am receiving this error in Chrome dev tools console when calling a function in an external library on page load in my Angular application: "Unhandled Promise rejection: Cannot read properties of undefined (reading 'page') ' Zone: ; Task:…
kingbiz
  • 31
  • 1
  • 3
2
votes
1 answer

Running analytics scripts outside of Angular zone

On my Angular website I'm injecting various third party scripts to collect analytics. These scripts are lazily loaded and will add event listeners (for f.e. click events) to certain elements on the page. Normally I'd wrap this kind of functionality…
KrekkieD
  • 967
  • 9
  • 23
1 2
3
16 17