Vincent
Member since Oct 2, 2013
- Profile: /members/11293-vincent.htm
- URL: https://VincentTunru.com
- Comments: 26
Recent Blog Comments By Vincent
-
Using Hot RxJS Observables In Your Service Layer In Angular 2.1.1
Posted on Dec 11, 2016 at 11:00 AM
@Ben, I tend to agree (although I'm not that familiar with Angular 2 yet). Although I understand why they are used for HTTP requests in Angular applications, it doesn't feel that natural to me. I think it might be justifiable to convert them to a promise for your service, although I wouldn't then r... read more »
-
Performing The Stream Equivalent Of Promise.all() Using RxJS
Posted on Dec 3, 2016 at 5:11 AM
You could also argue that an "equivalent" would also produce all intermediate values: Rx.Observable.merge(one$, two$, three$).finally(allHandler) :)... read more »
-
Using Hot RxJS Observables In Your Service Layer In Angular 2.1.1
Posted on Dec 1, 2016 at 2:04 PM
@Ben, I agree. But I see two things in your comment: using Observables _in_ the service, and using them _as the API_ of that service. If only the former, then I think you shouldn't leak any of the Observable implementation outside the service - in other words, you'd call `subscribe()` within the s... read more »
-
Using Hot RxJS Observables In Your Service Layer In Angular 2.1.1
Posted on Nov 22, 2016 at 3:31 PM
@Ben, Oh, and maybe I shouldn't ignore your other comment :P I'm not sure if there's general consensus on this, but in my view, you'd mainly consume Observables using pure functions - in other words, without side effects, such as "performing actions". So if you only care about performing ... read more »
-
Using Hot RxJS Observables In Your Service Layer In Angular 2.1.1
Posted on Nov 22, 2016 at 3:20 PM
@Ben, Good point, I'll have to clarify that in my post as well. In any case, the stream here is the source for counter states - a new one is provided every time an increment or decrement takes place, at which point the view is immediately updated. Other than in the view, though, the state is not sa... read more »
-
Using Hot RxJS Observables In Your Service Layer In Angular 2.1.1
Posted on Nov 20, 2016 at 3:59 PM
It's up! https://vincenttunru.com/why-Observables... read more »
-
Using Hot RxJS Observables In Your Service Layer In Angular 2.1.1
Posted on Nov 20, 2016 at 9:07 AM
@Ben, I didn't read all your follow-up posts (it's quite a lot; I can imagine that being a hurdle for Ben Lesh as well). However, I do feel that the way you're thinking about Observables leads to the confusion. If I understood correctly, you have a service that should post an HTTP call; you don't ... read more »
-
A Promise Chain's API Is Determined By Its Initiating Promise Library
Posted on Aug 4, 2016 at 1:47 PM
@Ben, Yeah it is, isn't it? If you're not going all-in on streams, it's probably best to consider where it helps and where it doesn't. Going all-in, though, like e.g. Cycle.js does, is a really interesting approach as well that I'd recommend putting on your undoubtedly long list of things-to-look-i... read more »
-
A Promise Chain's API Is Determined By Its Initiating Promise Library
Posted on Aug 3, 2016 at 5:01 AM
Oh boy, you're going to have fun when you try RxJS :)... read more »
-
The User Experience (UX) Of CSS Text-Transform On Form Input Fields
Posted on Apr 5, 2016 at 9:10 AM
@Ben, Yeah, I'd hate for my silly little joke to give someone a seizure :P... read more »
-
The User Experience (UX) Of CSS Text-Transform On Form Input Fields
Posted on Mar 30, 2016 at 6:14 AM
Actually, my Easter weekend project is, I think, a valid use case. It's this beauty: https://makeapoint.vincenttunru.com/ (work in progress, appears to be broken here atm) The only thing that will happen with the input, is that it will be displayed in SCREAMING ALL CAPS LETTERS. It's rather tongu... read more »
-
Synchronizing Magnetic Poetry With Firebase, AngularJS, And Redux
Posted on Jan 11, 2016 at 2:41 PM
@Ben, <blockquote>So, when people say that something does or doesn't make sense with AngularJS, unless they can give me good specifics, I just dismiss it as "noise."</blockquote> I wish you'd been at a talk I gave recently at my company that I think would have clarified this.... read more »
-
Using Dynamic Element Names With The JSX Transpiler In ReactJS
Posted on Sep 22, 2015 at 2:32 AM
Huh, somehow I missed this and went with the cumbersome React.createElement syntax: https://gitlab.com/vanity/vanity/blob/master/src/scripts/components/VanityApp.jsx#L55 Thanks for the tip :)... read more »
-
What If AngularJS Had A setState() Method Like ReactJS
Posted on Jul 8, 2015 at 4:28 AM
In fact, the way Angular 2 does change detection is a lot like the way React does it: http://victorsavkin.com/post/110170125256/change-detection-in-angular-2... read more »
-
Creating Objects With A Null Prototype In Node.js
Posted on Mar 11, 2015 at 4:08 AM
@Ben, It basically just says: enable some "experimental" ES6 features. I put "experimental" in quotes, because they might have been experimental when the latest version of Node was released, but might (like Maps) have been supported in V8 for a while by now -- which is why io.js... read more »
-
Creating Objects With A Null Prototype In Node.js
Posted on Mar 10, 2015 at 11:25 AM
If you're using io.js or Node with the `--harmony` flag, you can also just use a Map, which is iterable.... read more »
-
Creating A Pre-Bootstrap Loading Screen In AngularJS
Posted on Jan 13, 2015 at 3:05 AM
@Ben, I fell you -- I'm now wondering whether Angular might even detect that there are no variables in an expression and only parse it once when it just says `false`.... read more »
-
Creating A Pre-Bootstrap Loading Screen In AngularJS
Posted on Jan 12, 2015 at 10:22 AM
You don't have the benefits of using ngAnimate, but: wouldn't it be far easier to use the new (Angular 1.3) one-time binding feature? In other words: <div ng-if="::false"> <!-- ... --> </div> (I hope this comment works markup-wise ;) )... read more »
-
Counting The Number Of Watchers In AngularJS - Updated For Isolate Scopes
Posted on Dec 5, 2014 at 2:41 PM
Thanks Ben!... read more »
-
Counting The Number Of Watchers In AngularJS - Updated For Isolate Scopes
Posted on Dec 5, 2014 at 10:14 AM
Any more info on that "debug mode"? I can't seem to be able to find anything about that...... read more »