These are chat archives for opal/opal

23rd
Mar 2016
Brady Wied
@wied03
Mar 23 2016 00:26
That sounds like it could have significant impact on opal-rspec then. Does it really need to be mandatory ?
Elia Schito
@elia
Mar 23 2016 00:52
What's mandatory?
Jamie Gaskins
@jgaskins
Mar 23 2016 02:33
@elia: Tried the latest master branches of opal and opal-rails in a Rails app and Rails won't start up. Looks like opal-rails still relies on Opal::Processor. Is this a known issue?
Happened when I bundle updated a demo app that used the master branches.
Also, just catching up with the chat. I didn't realize Opal::Builder didn't rely on Sprockets. I've been telling everyone the wrong thing, apparently. :-)
Elia Schito
@elia
Mar 23 2016 09:05
@jgaskins yeah, opal-rails needs some love, I'll try to update it as soon as possible, in the meanwhile, the 0-8-stable should be more stable
Brady Wied
@wied03
Mar 23 2016 14:03
@fkchang - I still think it's unnecessarily complex to try and merge NPM and GEMs in the form of package.json and Gemfiles. If the aim is to use NPMs from Sprockets, then use Torba or improve rails-assets.org. If the aim is to use GEMs from Webpack land, then build a simple webpack plugin that basically does a Bundler.require and then extracts the Opal load paths and tells webpack about them. Obviously that would also require a well tested webpack load that compiles Opal
Forrest Chang
@fkchang
Mar 23 2016 22:19
@wied03 I'll need to think it over a bit. I didn't now about Torba, but I think I can think of some webpack leveraging scenarios that I ought to invalidate torba/rails-assets (for rails-assets that I think moving away from bower is the right choice if starting now), gems from webpack is probably in the cards, though ultimately, I do think that to be a "1st class Javascript citizen" we should do the Javascript-y things via the Javascript methods -- in principle that's where Torba doesn't quite meet it where Torba specifically assumes simple dependencies, and I want npm to handle all the potentially hairy dependencies
CJ Lazell
@cj
Mar 23 2016 22:20
with webpack you can include your assets inline... it's pretty nice :)
completely self contained component
css and js :)
Forrest Chang
@fkchang
Mar 23 2016 22:21
yeah, that and multiple points of entry are things I want to explore in using webpack w/opal
CJ Lazell
@cj
Mar 23 2016 22:23
@fkchang https://www.npmjs.com/package/opalrb-loader-cj I updated it to the latest version of opal
Brady Wied
@wied03
Mar 23 2016 22:27
@fkchang @cj - Are you guys going to add tests to your webpack loader anytime soon? That's one thing that's keeping me from trying it
CJ Lazell
@cj
Mar 23 2016 22:29
@wied03 Opal::Connect?
Forrest Chang
@fkchang
Mar 23 2016 22:30
@cj are you working on solving the require issue that @zetachang noted in his version?
CJ Lazell
@cj
Mar 23 2016 22:31
the requrie_relative issue? I want to, but haven't yet
Brady Wied
@wied03
Mar 23 2016 22:31
@fkchang - Sorry, that's @zetachang , not you
@cj - Not talking about opal:connect, talking about in general the idea of having a TDD developed webpack loader for opal
CJ Lazell
@cj
Mar 23 2016 22:32
I just worked around that issue by including my web dir so I can just use require
require 'app/components/layout' etc...
Forrest Chang
@fkchang
Mar 23 2016 22:33
@cj yeah, that's the one
CJ Lazell
@cj
Mar 23 2016 22:34
on the ruby side I unshift and opal I just add the dir. works just fine
Martin Becker
@Thermatix
Mar 23 2016 23:34
so what does opal::connect do?