These are chat archives for systemjs/systemjs

27th
Jan 2016
Bret Little
@blittle
Jan 27 2016 02:47
Is it possible to have relative paths in the map config? For example:
System.config({
  map: {
    "./src/root.component.js": "./lib/root.component-5f1fd6.js"
  }
})
// and usage
import Root from "./src/root.component.js";
Been playing around with no results
Bret Little
@blittle
Jan 27 2016 02:53
I guess my real question is, how does ./src/root.component.js need to be mapped inside the map config. Do I need to add on the base url? base/url/src/root.component.js?
everything I try doesn't seem to work
Davis Kim
@davis
Jan 27 2016 04:27
@ProLoser that's the approach superagent takes
Manuel Schweigert
@Manuel-S
Jan 27 2016 12:14
hey
Guy Bedford
@guybedford
Jan 27 2016 12:14
@blittle top-level relative paths are page-relative (document.baseURI)
Manuel Schweigert
@Manuel-S
Jan 27 2016 12:15
integrating systemjs into our corporate project (without jspm atm)
maybe I'm just stupid, but I am trying to load a .js and .html file using the text plugin, both in the same folder
the .js file loads fine, but the text plugin goes 404 because it doesn't use the basepath
Guy Bedford
@guybedford
Jan 27 2016 12:30
@Manuel-S do you mean baseURL?
Manuel Schweigert
@Manuel-S
Jan 27 2016 12:36
yep, and it seems I was just stupid
if I start the module import with a slash, apparently systemjs ignores the baseURL
Guy Bedford
@guybedford
Jan 27 2016 12:53
right, yeah / and ./ are URL-resolved
Peter Uithoven
@peteruithoven
Jan 27 2016 13:17
What's the current css (using systemjs) workflow you guys are using. I see jspm-loader-css has stagnated and the plugin-css doesn't have support for postcss yet. I'd love to work with the CSS modules approach, is someone using that with SystemJS?
Guy Bedford
@guybedford
Jan 27 2016 14:08
@peteruithoven the css workflows are in need of contributions yes
in fact plugins in general need contributors
I'm trying to work out what I can do to encourage more work here
thinking a plugin guide may be necessary
  • plugin authoring guide
Peter Uithoven
@peteruithoven
Jan 27 2016 14:20
That I did notice, I see there is a plugin create guide already: https://github.com/systemjs/systemjs/blob/master/docs/creating-plugins.md
Guy Bedford
@guybedford
Jan 27 2016 15:06
@peteruithoven yes but I'm wondering if perhaps something more comprehensive is needed. Any ideas what we can do to encourage more plugin development is very welcome.
Peter Uithoven
@peteruithoven
Jan 27 2016 15:10
reading the existing guide it all looks very simple, but still there are no plugins for the usual suspects like postcss, less, sass. I'm curious where the people that tried to do those ran into.
I also noticed that @MeoMix is working on the jspm-loader-css.
Bret Little
@blittle
Jan 27 2016 15:52
@guybedford does that mean that I cannot resolve paths that begin with ./ with map?
Sean Anderson
@MeoMix
Jan 27 2016 16:18
I am indeed still working on it
There are many gotchas with the current implementation
waiting on Glen to get back to me with some questions I have on it still
Bret Little
@blittle
Jan 27 2016 16:39
I hope things are going ok with Glen, been waiting a while for some feedback on geelen/jspm-loader-css-modules#5
Sean Anderson
@MeoMix
Jan 27 2016 17:33
He doesn't work on JSPM stuff atm
He's working in webpack
Bret Little
@blittle
Jan 27 2016 17:41
Makes sense. It is hard to juggle open source stuff with a day job
Paul Irish
@paulirish
Jan 27 2016 21:27
given the right Loader plugin, could system just load HTML imports?
Guy Bedford
@guybedford
Jan 27 2016 21:42
@paulirish there was some work on this in https://github.com/Hypercubed/systemjs-plugin-html, may be worth hearing what the results were there from @Hypercubed
Paul Irish
@paulirish
Jan 27 2016 21:44
:) I had forgotten about it but after 25 mins of poking around i found it again.
i just gave a PR to link to it from readme so i wont loose it again, but mentioned @Hypercubed to make sure it makes sense to him
Charles Wagner
@njappboy
Jan 27 2016 22:16
@MeoMix thank you for the hand with my node-uuid import statement. I reviewed the ES6 import documentation and your guidance was dead on accurate
Sean Anderson
@MeoMix
Jan 27 2016 22:26
You're welcome. :)
Takes a while to get used to the ES6 shtuff.
Dean Sofer
@ProLoser
Jan 27 2016 22:31
@MeoMix i'm curious what sorta confusion did you find with es6 imports?
Sean Anderson
@MeoMix
Jan 27 2016 22:33
@ProLoser njappboy was confused as to why import {Foo} from 'foo' wasn't working for him. He needed to change the statement to import Foo from 'foo'
Dean Sofer
@ProLoser
Jan 27 2016 22:34
because the first one is destructuring, right?
Sean Anderson
@MeoMix
Jan 27 2016 22:34
Yes
Charles Wagner
@njappboy
Jan 27 2016 22:44
@ProLoser newbie mistake ard cjs and destructuring
Dean Sofer
@ProLoser
Jan 27 2016 22:45
@njappboy understandable consdering most examples demonstrate 2 unrelated features in the new language together (usually)
Charles Wagner
@njappboy
Jan 27 2016 22:47
@ProLoser I think I was too busy creating custom jspm handlers when I was learning ES6/aurelia. I blame @AshleyGrant :-)
Ashley Grant
@AshleyGrant
Jan 27 2016 22:54
I blame the voices in my head
Charles Wagner
@njappboy
Jan 27 2016 22:57
@AshleyGrant I hear your head voices as well. They are loud brother! And their Canadian accent is just plan weird. Now where is joel's aurelia-interface bc aurelia-ui-framework's fixed layout requirements pissed me off today?
Dean Sofer
@ProLoser
Jan 27 2016 23:03
@njappboy how do you like aurelia?
Charles Wagner
@njappboy
Jan 27 2016 23:27
@ProLoser so far I'm digging it. I think it is a better alternative to ng2, for most enterprises. It has some interesting possibilities with its component and plugin model. Systemjs/jspm really make that possible from an operations perspective.
Dean Sofer
@ProLoser
Jan 27 2016 23:33
yeah i'm surprised i'm saying this but i think i've lost all faith in ng2
i don't really see myself switching to aurelia but the complexity of ng2 is just unbelievable
Charles Wagner
@njappboy
Jan 27 2016 23:43
Ng2 doesn't excite me. ng1 is still a player but I have a hard time using it for greenfield apps knowing it is old tech with no commercial support and no clear upgrade path. Besides, I don't care for google and their determination to violate privacy rights with violent state actors like China and the US. Just my 2 cents
Dean Sofer
@ProLoser
Jan 27 2016 23:59
yeah... i'm not going to start making politics my reasons for choosing software
but yeah i still prefer ng1 and ng2 is just kind of a nightmare