by

Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • 08:30
    Alexander-Taran opened #183
  • 06:39
    bigopon labeled #187
  • 06:39
    bigopon labeled #187
  • 06:39
    bigopon labeled #265
  • 06:39
    bigopon labeled #265
  • 06:38
    bigopon labeled #280
  • 06:38
    bigopon labeled #280
  • 06:38
    bigopon labeled #284
  • 06:38
    bigopon labeled #284
  • 06:37
    bigopon commented #284
  • 06:36
    MaximBalaganskiy commented #284
  • 06:29
    MaximBalaganskiy opened #284
  • 04:33
    MaximBalaganskiy commented #282
  • 04:25
    bigopon commented #282
  • 03:43
    MaximBalaganskiy synchronize #282
  • 02:44

    bigopon on master

    fix(lookup): handle empty css v… Merge pull request #283 from Ma… (compare)

  • 02:44
    bigopon closed #283
  • 02:41
    MaximBalaganskiy opened #283
  • May 31 23:21
    bigopon commented on 088b8ca
  • May 31 21:13
    MaximBalaganskiy synchronize #282
Max
@MaximBalaganskiy
or use GlobModuleDependencies
or use AureliaPlugin with includeAll parameter
bigopon
@bigopon
@michaelprescott make sure you don't have cyclical dependencies structure
Andy
@weoreference
@MaximBalaganskiy Thank you very much. It's a pity that Webpack breaks some of the traditional elegance of Aurelia. I've been seeing this PLATFORM thing everywhere and I was wondering what exactly that was doing. Oh well, thank you
Max
@MaximBalaganskiy
I use GlobModuleDependencies
this minimises PLATFORM polution
includeAll as I recently found out has some undesirable side effect
Andy
@weoreference

@MaximBalaganskiy Oh I see, so Glob is preferred. Yes, I think I would agree. I suppose none of this is too bad then: This works, albeit with all the opposite drawbacks of option 1:

Non-precise dependencies, you might sometimes get more (unrelated) files than you need;
Everything is together with the consuming view, no split possible;
No check of module ids at build-time, no check what is used or not;
The location of modules is duplicated between glob config and view interpolation;
Related "code" is spread far apart.

aurelia/skeleton-navigation#810
Max
@MaximBalaganskiy
@weoreference JSPM was perfect until it wasn't :)
Andy
@weoreference
So those things in practice are not so much problems? They make Option 1 seem the better...
@MaximBalaganskiy JSPM was perfect until I was forced to use Webpack for the Aurelia-Materialize-Bridge
Max
@MaximBalaganskiy
personally, I don't like this PLATFORM thing everywhere, especially because I cannot use it from a "namespace"
Andy
@weoreference
:point_up: February 13, 2018 4:37 AM -- In short, an aesthetic decision. Some people dont realize how important aesthetics are to coders
This is why I could never bring myself to learn Angular
Max
@MaximBalaganskiy
angular verbosity vs aurelia PLATFORM magic :))
I wouldn't mind actually if routes were specified with strong types as in NG
Vildan Softic
@zewa666
@gregbacchus sry thats a regression recently introduced. Didnt think about those detection Plugins. Its already filed as Bug
Greg Bacchus
@gregbacchus
@zewa666 Thanks for letting me know. I'll watch out for the update release.
Michael Prescott
@michaelprescott
@bigopon thanks, I believe cyclical dependencies are the cause of some of the hard to find errors. Not 100% sure because I've had to strip out code, temporarily, to get past them. (Porting an old Aurelia+ES6 app to TypeScript)
I've gotten past some using a technique like let userService = aurelia.container.get(UserService);, still... I wish webpack errors made some kind of sense to me :)
cnceniza
@cnceniza

How can I update a page title when I'm active on other page?
Say, I'm in "Create Order" page, once I placed an order and saved it, "Jobs [0]" page will increment by 1 and display as "Jobs [1]". Something like that.

I already saw some answers at SO but it utilizes the activate method in which the user have to be in the page before it'll change the page title. Please advise

Here is my sidebar

cnceniza
@cnceniza
I tried to use pubsub, it works but I can't seem to target specific page I want to update
Vildan Softic
@zewa666
@gregbacchus Hey what would help is If you could create a small example using a detector so I can tweak around finding the best way to fix it
Andy
@weoreference
Hello guys. What are the best practices for separating my CSS for my custom element? Right now, in the custom element's VM I am doing import 'my-element.css which imports my styles, and it's well. But, an issue is that if I define style of <p> inside this CSS file, it affects all <p>s even outside my custom element. Is there a convention or best practice to encapsulate my css file only within the module where I have imported it (and its sub-components)? --- Or is this not a feature of the css?
Do I need to manually "namespace" all my styles with .my-custom-element p {}, .my-custom-element h1 {} etc?
Max
@MaximBalaganskiy
@weoreference yep, that's what we do
With custom elements you'll have the element name, no need for a class
Ben Chiciudean
@benydc
is true that aurelia searches the first element in a view having au-animate class? how can I use animation for show.bind after the first au-animate of section element?
Andrew Stoker
@AStoker
:point_up: February 13, 2018 1:54 AM
@weoreference, and until we get scoped CSS in the browsers, we’ll have to continue doing what @MaximBalaganskiy does.
We use in the html the <require from=‘./custom.css’> approach though, keeping markup concerns in markup files.
Lewis
@LewisNangleIT
Just wondering what is the cleanest way of inserting multiple classes from a string array into an element, right now im doing class="standardclass ${classArray.join(' ' )}"
Andrew Stoker
@AStoker
@LewisNangleIT , is classArray going to change? That seems simple enough. You could clean it up by leaving the logic portion (.join) in the viewmodel, but that’s just an MVVM pattern.
Lewis
@LewisNangleIT
@AStoker As the project is right now it won't change after being bound, if it did in the future that would cause a problem then?
Andrew Stoker
@AStoker
No problems. Just thinking of ways to improve speed. You don’t want to have to be dirty checking properties and constantly performing a .join operation on an array. If you know when classArray changes, then you can just set a static property on your view model that represents the joined classes, or use a getter with a @computedFrom decorator to trigger only when your trigger value causes classArray to change.
Make sense?
Lewis
@LewisNangleIT
@AStoker Yep, cheers man#
Andrew Stoker
@AStoker
:+1:
tbnovaes
@tbnovaes
I have a dummy question. I’m using aurelia-http-client and I have a bunch of requests done to an API, is there a way for me to ignore/cancel the previous requests/promises that are not yet resolved, when user changes the page, or for example change the option on a select dropdown? Right now, the only solution I found was to save the requests into an array and abort them.
Andrew Stoker
@AStoker
I’m not sure that can be done with Fetch yet. But if you’re using XHR, you should be able to. Don’t know the details right now though, somebody else might.
tbnovaes
@tbnovaes
@AStoker Well I know that XHR allows me to abort the request, that is what I’m doing. But i have multiple requests running at same time, so the code to achieve the the work is not that pretty. I know that with RxJs we can just unsubscribe the observable and done. I was looking for something similar but native.
Vildan Softic
@zewa666
@veikkoeeva thanks for the PRs i hope I can review them this week.
Veikko Eeva
@veikkoeeva
@zewa666 I noticed from other conversation that the Plugin-thingy is more about WebPack. The text in the PR might reflect more of that fact. Anyhow, this is all new to me, so you might have to be a bit patient while I learn the ropes. :)
By the way, has anyone done a chat like application Aurelia?
Vildan Softic
@zewa666
There is an example using Firebase by @Vheissu
Veikko Eeva
@veikkoeeva
@MaximBalaganskiy Combine with https://blogs.windows.com/msedgedev/2018/02/06/welcoming-progressive-web-apps-edge-windows-10/ and other events such as that MS pushing really hard for mixed reality (AFrame, Babylon.js) and WebRTC (especially being able to extend from PWA to UWP capabilities) and one might see where it's going to. WASM has seen semi-public demos 1-2 yeards already on .NET.
Which makes using http://fable.io/ an interesting proposition. I.e. use it to transpile to JS now and WASM later (and optionally use the same core on desktop otherwise).
https://blog.mozvr.com/ They have a Slack channel too, I just joined (quite silent still, but likely grows).
Veikko Eeva
@veikkoeeva
The GH repo has .vscode, I see, so might be something easy enough for me to try at some point. :D
Veikko Eeva
@veikkoeeva
Looking at @bigopon labouring, I came across aurelia/templating-binding#118.